resultList() public méthode

Gets the list result envelope for the response
public resultList ( mixed $data, string | null $foundRows = null ) : Scalr\Api\DataType\ListResultEnvelope
$data mixed The list of the objects which should be responded with
$foundRows string | null optional The number of the found rows to inject Pagination into envelope
Résultat Scalr\Api\DataType\ListResultEnvelope Returns list result
Exemple #1
0
 /**
  * Gets describe result
  *
  * @param   array    $criteria      Default search criteria
  * @param   callable $findCallback  optional Find method. Default value: find
  * @return  ListResultEnvelope      Returns describe result
  */
 public function getDescribeResult($criteria = null, $findCallback = null)
 {
     $data = [];
     foreach ($this->find($criteria, $findCallback) as $item) {
         $data[] = $item;
     }
     return $this->controller->resultList($data, $this->getInnerIterator()->totalNumber);
 }