1 | <?php |
||
19 | abstract class NewsMapper extends Mapper { |
||
20 | |||
21 | 16 | public function __construct(IDBConnection $db, $table, $entity) { |
|
24 | |||
25 | /** |
||
26 | * @param int $id the id of the feed |
||
27 | * @param string $userId the id of the user |
||
28 | * @return \OCP\AppFramework\Db\Entity |
||
29 | */ |
||
30 | abstract public function find($id, $userId); |
||
31 | |||
32 | /** |
||
33 | * Performs a SELECT query with all arguments appened to the WHERE clause |
||
34 | * The SELECT will be performed on the current table and take the entity |
||
35 | * that is related for transforming the properties into column names |
||
36 | * |
||
37 | * Important: This method does not filter marked as deleted rows! |
||
38 | * |
||
39 | * @param array $search an assoc array from property to filter value |
||
40 | * @param int $limit |
||
41 | * @paran int $offset |
||
42 | * @return array |
||
43 | */ |
||
44 | 10 | public function where(array $search=[], $limit=null, $offset=null) { |
|
71 | |||
72 | } |
||
73 |