Add interface "Queryable" (WIP)

Interface for classes which act as a data source and thus return or are a Fetchable.
The name of the interface is not yet final though.
This commit is contained in:
Eric Lippmann 2014-04-15 16:23:17 +02:00
parent 0f3d70c437
commit 659e6f774e
1 changed files with 19 additions and 0 deletions

View File

@ -0,0 +1,19 @@
<?php
namespace Icinga\Data;
/**
* Interface for specifying data sources
*/
interface Queryable
{
/**
* Set the target and fields to query
*
* @param string $target
* @param array $fields
*
* @return Fetchable
*/
public function from($target, array $fields = null);
}