eZPublishCommunityProject  2013.9
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native Class Reference

The Content Search Gateway provides the implementation for one database to retrieve the desired content objects. More...

+ Inheritance diagram for eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native:
+ Collaboration diagram for eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native:

Public Member Functions

 __construct (HttpClient $client, CriterionVisitor $criterionVisitor, SortClauseVisitor $sortClauseVisitor, FacetBuilderVisitor $facetBuilderVisitor, FieldValueMapper $fieldValueMapper, ContentHandler $contentHandler, FieldNameGenerator $nameGenerator)
 Construct from HTTP client. More...
 
 deleteContent ($contentId, $versionId=null)
 Deletes a content object from the index. More...
 
 deleteLocation ($locationId)
 Deletes a location from the index. More...
 
 findContent (Query $query, array $fieldFilters=array())
 Finds content objects for the given query. More...
 
 indexContent (array $document)
 Indexes a content object. More...
 
 purgeIndex ()
 Purges all contents from the index. More...
 
- Public Member Functions inherited from eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway
 deleteContent ($contentId, $versionId=null)
 Deletes a content object from the index. More...
 
 deleteLocation ($locationId)
 Deletes a location from the index. More...
 
 findContent (Query $query, array $fieldFilters=array())
 Finds content objects for the given query. More...
 
 indexContent (array $document)
 Indexes a content object. More...
 
 purgeIndex ()
 Purges all contents from the index. More...
 

Protected Member Functions

 createUpdate (array $document)
 Create document update XML. More...
 

Protected Attributes

 $client
 
 $contentHandler
 
 $criterionVisitor
 
 $facetBuilderVisitor
 
 $fieldValueMapper
 
 $nameGenerator
 
 $sortClauseVisitor
 

Detailed Description

The Content Search Gateway provides the implementation for one database to retrieve the desired content objects.

Constructor & Destructor Documentation

eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::__construct ( HttpClient  $client,
CriterionVisitor  $criterionVisitor,
SortClauseVisitor  $sortClauseVisitor,
FacetBuilderVisitor  $facetBuilderVisitor,
FieldValueMapper  $fieldValueMapper,
ContentHandler  $contentHandler,
FieldNameGenerator  $nameGenerator 
)

Construct from HTTP client.

Parameters
HttpClient$client
CriterionVisitor$criterionVisitor
SortClauseVisitor$sortClauseVisitor
FacetBuilderVisitor$facetBuilderVisitor
FieldValueMapper$fieldValueMapper
ContentHandler$contentHandler
Returns
void

Member Function Documentation

eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::createUpdate ( array  $document)
protected

Create document update XML.

Parameters
array$document
Returns
string

Referenced by eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native\indexContent().

eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::deleteContent (   $contentId,
  $versionId = null 
)

Deletes a content object from the index.

Parameters
intcontent id
int|nullversion id
Returns
void
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::deleteLocation (   $locationId)

Deletes a location from the index.

Parameters
mixed$locationId
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::findContent ( Query  $query,
array  $fieldFilters = array() 
)

Finds content objects for the given query.

Todo:
define structs for the field filters
Parameters
\eZ\Publish\API\Repository\Values\Content\Query$query
array$fieldFilters- a map of filters for the returned fields. Currently supported: array("languages" => array(<language1>,..)).
Returns
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::indexContent ( array  $document)

Indexes a content object.

Parameters
\eZ\Publish\SPI\Persistence\Content\Search\Field[]$document
Returns
void
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::purgeIndex ( )

Purges all contents from the index.

Returns
void

Member Data Documentation

eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$client
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$contentHandler
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$criterionVisitor
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$facetBuilderVisitor
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$fieldValueMapper
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$nameGenerator
protected
eZ\Publish\Core\Persistence\Solr\Content\Search\Gateway\Native::$sortClauseVisitor
protected

The documentation for this class was generated from the following file: