AbstractCompositeFilter.php 621 Bytes
Newer Older
1
2
<?php
/*
Guillaume Perréal's avatar
CS.    
Guillaume Perréal committed
3
4
 * Copyright (C) 2016-2017 IRSTEA
 * All rights reserved.
5
6
7
8
9
10
11
 */

namespace Irstea\PlantUmlBundle\Model\Filter\Composite;

use Irstea\PlantUmlBundle\Model\ClassFilterInterface;

/**
Guillaume Perréal's avatar
CS.    
Guillaume Perréal committed
12
 * Description of CompositeFilter.
13
14
15
16
17
18
19
20
21
22
23
24
 */
abstract class AbstractCompositeFilter implements ClassFilterInterface
{
    /**
     * @var ClassFilterInterface
     */
    protected $filters;

    public function __construct(array $filters)
    {
        $this->filters = $filters;
    }
25
26
27

    public function toConfig(array &$conf)
    {
Guillaume Perréal's avatar
CS.    
Guillaume Perréal committed
28
        foreach ($this->filters as $filter) {
29
30
31
            $filter->toConfig($conf);
        }
    }
32
}