ApiFilter::acceptMethod()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 2
eloc 2
nc 2
nop 1
1
<?php
2
3
namespace allejo\Sami;
4
5
use Sami\Parser\Filter\FilterInterface;
6
use Sami\Reflection\ClassReflection;
7
use Sami\Reflection\MethodReflection;
8
use Sami\Reflection\PropertyReflection;
9
10
class ApiFilter implements FilterInterface
11
{
12
    public function acceptClass (ClassReflection $class)
13
    {
14
        return true;
15
    }
16
    public function acceptMethod (MethodReflection $method)
17
    {
18
        return ($method->isPublic() && empty($method->getTags('internal')));
19
    }
20
    public function acceptProperty (PropertyReflection $property)
21
    {
22
        return ($property->isPublic() && empty($property->getTags('internal')));
23
    }
24
}
25