Data/interfaces: add Filterable, extend Connection
New interface ConnectionInterface attempts to aggregate things. Extended Filterable interface, added Filter-related functions. Please note that apply will probably get dropped later on, I'll keep it for compatibility reasons right now. refs #6418
This commit is contained in:
parent
f438cb30e1
commit
85605597cc
|
@ -0,0 +1,5 @@
|
|||
<?php
|
||||
|
||||
namespace Icinga\Data;
|
||||
|
||||
interface ConnectionInterface extends Selectable, Queryable {};
|
|
@ -2,7 +2,20 @@
|
|||
|
||||
namespace Icinga\Data;
|
||||
|
||||
use Icinga\Data\Filter\Filter;
|
||||
|
||||
/**
|
||||
* Interface for filtering a result set
|
||||
*/
|
||||
interface Filterable {}
|
||||
interface Filterable
|
||||
{
|
||||
public function applyFilter(Filter $filter);
|
||||
|
||||
public function setFilter(Filter $filter);
|
||||
|
||||
public function getFilter(Filter $filter);
|
||||
|
||||
public function addFilter(Filter $filter);
|
||||
|
||||
public function where($condition, $value = null);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue