PHP 클래스 DMS\Bundle\FilterBundle\Service\Filter

Provides filtering result based on annotation in the class.
파일 보기 프로젝트 열기: rdohms/dms-filter-bundle 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( DMS\Filter\FilterInterface $filter ) Instantiates the Filter Service
filterEntity ( object $object ) Filter an object based on its annotations
filterProperty ( object $object, string $property ) Filters only a selected property of an entity
filterValue ( mixed $value, Rule[] | Rule $filter ) : mixed Runs a given value through one or more filter rules returning the filtered value
getFilterExecutor ( ) : Filter Retrieve the actual filter executor instance

메소드 상세

__construct() 공개 메소드

Instantiates the Filter Service
public __construct ( DMS\Filter\FilterInterface $filter )
$filter DMS\Filter\FilterInterface

filterEntity() 공개 메소드

Filter an object based on its annotations
public filterEntity ( object $object )
$object object

filterProperty() 공개 메소드

Filters only a selected property of an entity
public filterProperty ( object $object, string $property )
$object object
$property string

filterValue() 공개 메소드

Runs a given value through one or more filter rules returning the filtered value
public filterValue ( mixed $value, Rule[] | Rule $filter ) : mixed
$value mixed
$filter DMS\Filter\Rules\Rule[] | DMS\Filter\Rules\Rule
리턴 mixed

getFilterExecutor() 공개 메소드

Retrieve the actual filter executor instance
public getFilterExecutor ( ) : Filter
리턴 DMS\Filter\Filter