コード例 #1
0
ファイル: Query.php プロジェクト: ec-europa/joinup-dev
 /**
  * Set the graph types for the query.
  *
  * This allows the filtering of graphs on the query level. There are two ways
  * to filter the results:
  * - Set the graph types in this method.
  * - Set the request graphs in the storage level.
  * The query graph filter that is set below is filtering the graphs
  * that the query will run on, so this makes this filter a runtime filter.
  * After the results are retrieved, the storage will further filter the
  * results based on the request graphs set for the entities.
  *
  * @param array $graph_types
  *    An array of graphs ids to be passed into the query.
  *
  * @todo: When a condition is set on the bundle, this graphs should be
  * filtered accordingly.
  *
  * @see \Drupal\rdf_entity\RdfGraphHandler::setRequestGraphs()
  * @see \Drupal\rdf_entity\Entity\RdfEntitySparqlStorage::processGraphResults()
  */
 public function setGraphType($graph_types = ['default'])
 {
     $this->graphs = $this->entityStorage->getGraphHandler()->getEntityTypeGraphUrisList($this->entityType->getBundleEntityType(), $graph_types);
 }