| 1 | <?php |
||
| 27 | class SearchCriteria extends Criteria implements ConditionDecoratorTypeAwareInterface |
||
| 28 | { |
||
| 29 | |||
| 30 | use UniqueModelsAwareTrait; |
||
| 31 | |||
| 32 | private $query = ''; |
||
| 33 | |||
| 34 | 64 | public function __construct($criteria = null, AnnotatedInterface $model = null) |
|
| 35 | { |
||
| 36 | 64 | parent::__construct($criteria, $model); |
|
| 37 | 64 | if (!empty($model)) |
|
| 38 | { |
||
| 39 | 37 | $this->add($model); |
|
| 40 | } |
||
| 41 | 64 | } |
|
| 42 | |||
| 43 | 64 | public function getDecoratorType() |
|
| 47 | |||
| 48 | 41 | public function setModel(AnnotatedInterface $model) |
|
| 53 | |||
| 54 | 41 | public function add($model) |
|
| 59 | |||
| 60 | 39 | public function search($query) |
|
| 64 | |||
| 65 | 64 | public function getSearch() |
|
| 69 | |||
| 70 | } |
||
| 71 |