Skip to content

Commit

Permalink
DDC-1094 - ORM gets findBy() with limit, offset and order by, object …
Browse files Browse the repository at this point in the history
…repository needs to support this. Implementations get a way out by not requiring the implementation of this feature.
  • Loading branch information
beberlei committed Apr 30, 2011
1 parent e583d1a commit 5a28553
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 0 additions & 2 deletions lib/Doctrine/Common/Persistence/Mapping/ClassMetadata.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Expand Down
2 changes: 0 additions & 2 deletions lib/Doctrine/Common/Persistence/ObjectManager.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Expand Down
12 changes: 9 additions & 3 deletions lib/Doctrine/Common/Persistence/ObjectRepository.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<?php
/*
* $Id$
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
Expand Down Expand Up @@ -50,10 +48,18 @@ public function findAll();
/**
* Finds objects by a set of criteria.
*
* Optionally sorting and limiting details can be passed. An implementation may throw
* an UnexpectedValueException if certain values of the sorting or limiting details are
* not supported.
*
* @throws UnexpectedValueException
* @param array $criteria
* @param array|null $orderBy
* @param int|null $limit
* @param int|null $offset
* @return mixed The objects.
*/
public function findBy(array $criteria);
public function findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null);

/**
* Finds a single object by a set of criteria.
Expand Down

0 comments on commit 5a28553

Please sign in to comment.