src/wcmf/application/controller/ListController.php
protected function getObjects($type, $queryCondition, $sortArray, $pagingInfo) {
    $persistenceFacade = $this->getPersistenceFacade();
    if (!$persistenceFacade->isKnownType($type)) {
      return [];
    }

    $request = $this->getRequest();
    $response = $this->getResponse();
    $query = new StringQuery($type);
    $query->setRQLConditionString($queryCondition);
    try {
      $objects = $query->execute(BuildDepth::SINGLE, $sortArray, $pagingInfo);
    }
    catch (UnknownFieldException $ex) {
      if ($ex->getField() == $request->getValue('sortFieldName')) {
        $response->addError(ApplicationError::get('SORT_FIELD_UNKNOWN'));
      }
    }
    if ($this->getLogger()->isDebugEnabled()) {
      $this->getLogger()->debug("Load objects with query: ".$query->getLastQueryString());
    }
    return $objects;
  }
protected function getObjects($type, $queryCondition, $sortArray, $pagingInfo) {
    $persistenceFacade = $this->getPersistenceFacade();
    if (!$persistenceFacade->isKnownType($type)) {
      return [];
    }

    $request = $this->getRequest();
    $response = $this->getResponse();
    $query = new StringQuery($type);
    $query->setRQLConditionString($queryCondition);
    try {
      $objects = $query->execute(BuildDepth::SINGLE, $sortArray, $pagingInfo);
    }
    catch (UnknownFieldException $ex) {
      if ($ex->getField() == $request->getValue('sortFieldName')) {
        $response->addError(ApplicationError::get('SORT_FIELD_UNKNOWN'));
      }
    }
    if ($this->getLogger()->isDebugEnabled()) {
      $this->getLogger()->debug("Load objects with query: ".$query->getLastQueryString());
    }
    return $objects;
  }
protected function getObjects ( $ type , $ queryCondition , $ sortArray , $ pagingInfo ) { $ persistenceFacade = $ this -> getPersistenceFacade ( ) ; if ( ! $ persistenceFacade -> isKnownType ( $ type ) ) { return [ ] ; } $ request = $ this -> getRequest ( ) ; $ response = $ this -> getResponse ( ) ; $ query = new StringQuery ( $ type ) ; $ query -> setRQLConditionString ( $ queryCondition ) ; try { $ objects = $ query -> execute ( BuildDepth :: SINGLE , $ sortArray , $ pagingInfo ) ; } catch ( UnknownFieldException $ ex ) { if ( $ ex -> getField ( ) == $ request -> getValue ( 'sortFieldName' ) ) { $ response -> addError ( ApplicationError :: get ( 'SORT_FIELD_UNKNOWN' ) ) ; } } if ( $ this -> getLogger ( ) -> isDebugEnabled ( ) ) { $ this -> getLogger ( ) -> debug ( "Load objects with query: " . $ query -> getLastQueryString ( ) ) ; } return $ objects ; }
Get the object to display. The default implementation uses a StringQuery instance for the
object retrieval. Subclasses may override this. If filter is an empty string, all nodes of the given
type will be selected.
@param $type The object type
@param $queryCondition The query condition passed from the view (to be used with StringQuery).
@param $sortArray An array of attributes to order by (with an optional ASC|DESC appended)
@param $pagingInfo The current PagingInfo instance
@return Array of Node instances
Get the object to display . The default implementation uses a StringQuery instance for the object retrieval . Subclasses may override this . If filter is an empty string all nodes of the given type will be selected .