* @link https://github.com/pjmazenot/phpsolr-phpdoc */ /** * (PECL solr >= 0.9.2)
* Class SolrDocument
* This class represents a Solr document retrieved from a query response. * @link https://php.net/manual/en/class.solrinputdocument.php */ final class SolrDocument implements ArrayAccess, Iterator, Serializable { /** @var int Sorts the fields in ascending order. */ public const SORT_DEFAULT = 1; /** @var int Sorts the fields in ascending order. */ public const SORT_ASC = 1; /** @var int Sorts the fields in descending order. */ public const SORT_DESC = 2; /** @var int Sorts the fields by name */ public const SORT_FIELD_NAME = 1; /** @var int Sorts the fields by number of values. */ public const SORT_FIELD_VALUE_COUNT = 2; /** @var int Sorts the fields by boost value. */ public const SORT_FIELD_BOOST_VALUE = 4; /** * (PECL solr >= 0.9.2)
* Adds a field to the document * @link https://php.net/manual/en/solrdocument.addfield.php * @param string $fieldName

* The name of the field *

* @param string $fieldValue

* The value for the field. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function addField($fieldName, $fieldValue) {} /** * (PECL solr >= 0.9.2)
* Drops all the fields in the document * @link https://php.net/manual/en/solrdocument.clear.php * @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function clear() {} /** * (PECL solr >= 0.9.2)
* Creates a copy of a SolrDocument object * @link https://php.net/manual/en/solrdocument.clone.php */ public function __clone() {} /** * (PECL solr >= 0.9.2)
* SolrDocument constructor. * @link https://php.net/manual/en/solrdocument.construct.php */ public function __construct() {} /** * (PECL solr >= 0.9.2)
* Retrieves the current field * @link https://php.net/manual/en/solrdocument.current.php * @return SolrDocumentField

* Returns the field *

*/ public function current() {} /** * (PECL solr >= 0.9.2)
* Removes a field from the document * @link https://php.net/manual/en/solrdocument.deletefield.php * @param string $fieldName

* The name of the field. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function deleteField($fieldName) {} /** * (PECL solr >= 0.9.2)
* Destructor * @link https://php.net/manual/en/solrdocument.destruct.php */ public function __destruct() {} /** * (PECL solr >= 0.9.2)
* Checks if a field exists in the document * @link https://php.net/manual/en/solrdocument.fieldexists.php * @param string $fieldName

* Name of the field. *

* @return bool

* Returns TRUE if the field is present and FALSE if it does not. *

*/ public function fieldExists($fieldName) {} /** * (PECL solr >= 0.9.2)
* Access the field as a property * @link https://php.net/manual/en/solrdocument.get.php * @param string $fieldName

* The name of the field. *

* @return SolrDocumentField

* Returns a SolrDocumentField instance. *

*/ public function __get($fieldName) {} /** * (PECL solr >= 2.3.0)
* Returns an array of child documents (SolrInputDocument) * @link https://php.net/manual/en/solrdocument.getchilddocuments.php * @return SolrInputDocument[] */ public function getChildDocuments() {} /** * (PECL solr >= 2.3.0)
* Returns the number of child documents * @link https://php.net/manual/en/solrdocument.getchilddocumentscount.php * @return int */ public function getChildDocumentsCount() {} /** * (PECL solr >= 0.9.2)
* Retrieves a field by name * @link https://php.net/manual/en/solrdocument.getfield.php * @param string $fieldName

* The name of the field. *

* @return SolrDocumentField|false Returns a SolrDocumentField object on success and FALSE on failure */ public function getField($fieldName) {} /** * (PECL solr >= 0.9.2)
* Returns the number of fields in this document * @link https://php.net/manual/en/solrdocument.getfieldcount.php * @return int|false

* Returns an integer on success and FALSE on failure. *

*/ public function getFieldCount() {} /** * (PECL solr >= 0.9.2)
* Returns an array containing all the fields in the document * @link https://php.net/manual/en/solrdocument.getfieldnames.php * @return array|false

* Returns an array on success and FALSE on failure. *

*/ public function getFieldNames() {} /** * (PECL solr >= 0.9.2)
* Returns a SolrInputDocument equivalent of the object * @link https://php.net/manual/en/solrdocument.getinputdocument.php * @return SolrInputDocument

* Returns a SolrInputDocument on success and NULL on failure. *

*/ public function getInputDocument() {} /** * (PECL solr >= 2.3.0)
* Checks whether the document has any child documents * @link https://php.net/manual/en/solrdocument.haschilddocuments.php * @return bool

* Returns TRUE if the document has any child documents *

*/ public function hasChildDocuments() {} /** * (PECL solr >= 0.9.2)
* Checks if a field exists * @link https://php.net/manual/en/solrdocument.isset.php * @param string $fieldName

* Name of the field. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function __isset($fieldName) {} /** * (PECL solr >= 0.9.2)
* Retrieves the current key * @link https://php.net/manual/en/solrdocument.key.php * @return string

* Returns the current key. *

*/ public function key() {} /** * (PECL solr >= 0.9.2)
* Merges one input document into another * @link https://php.net/manual/en/solrdocument.merge.php * @param SolrInputDocument $sourceDoc

* The source document. *

* @param bool $overwrite [optional]

* If this is TRUE then fields with the same name in the destination document will be overwritten. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function merge(SolrInputDocument $sourceDoc, $overwrite = true) {} /** * (PECL solr >= 0.9.2)
* Moves the internal pointer to the next field * @link https://php.net/manual/en/solrdocument.next.php */ public function next() {} /** * (PECL solr >= 0.9.2)
* Checks if a particular field exists * @link https://php.net/manual/en/solrdocument.offsetexists.php * @param string $fieldName

* The name of the field. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function offsetExists($fieldName) {} /** * (PECL solr >= 0.9.2)
* Retrieves a field * @link https://php.net/manual/en/solrdocument.offsetget.php * @param string $fieldName

* The name of the field. *

* @return SolrDocumentField

* Returns a SolrDocumentField object. *

*/ public function offsetGet($fieldName) {} /** * (PECL solr >= 0.9.2)
* Adds a field to the document * @link https://php.net/manual/en/solrdocument.offsetset.php * @param string $fieldName

* The name of the field. *

* @param string $fieldValue

* The value for this field. *

* @return bool */ public function offsetSet($fieldName, $fieldValue) {} /** * (PECL solr >= 0.9.2)
* Removes a field * @link https://php.net/manual/en/solrdocument.offsetunset.php * @param string $fieldName

* The name of the field. *

*/ public function offsetUnset($fieldName) {} /** * (PECL solr >= 0.9.2)
* This is an alias of SolrDocument::clear * @link https://php.net/manual/en/solrdocument.reset.php * @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function reset() {} /** * (PECL solr >= 0.9.2)
* Resets the internal pointer to the beginning * @link https://php.net/manual/en/solrdocument.rewind.php */ public function rewind() {} /** * (PECL solr >= 0.9.2)
* Used for custom serialization * @link https://php.net/manual/en/solrdocument.serialize.php * @return string

* Returns a string representing the serialized Solr document. *

*/ public function serialize() {} /** * (PECL solr >= 0.9.2)
* Adds another field to the document * @link https://php.net/manual/en/solrdocument.set.php * @param string $fieldName

* Name of the field. *

* @param string $fieldValue

* Field value. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function __set($fieldName, $fieldValue) {} /** * (PECL solr >= 0.9.2)
* Sorts the fields within the document * @link https://php.net/manual/en/solrdocument.sort.php * @param int $sortOrderBy

* The sort criteria, must be one of : *

*

* @param int $sortDirection [optional]

* The sort direction, can be one of : *

*

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function sort($sortOrderBy, $sortDirection = SolrInputDocument::SORT_ASC) {} /** * (PECL solr >= 0.9.2)
* Returns an array representation of the document * @link https://secure.php.net/manual/en/solrdocument.toarray.php * @return array

* Returns an array representation of the document. *

*/ public function toArray() {} /** * (PECL solr >= 0.9.2)
* Custom serialization of SolrDocument objects * @link https://php.net/manual/en/solrdocument.unserialize.php * @param string $serialized

* An XML representation of the document. *

*/ public function unserialize($serialized) {} /** * (PECL solr >= 0.9.2)
* Removes a field from the document * @link https://php.net/manual/en/solrdocument.unset.php * @param string $fieldName

* The name of the field. *

* @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function __unset($fieldName) {} /** * (PECL solr >= 0.9.2)
* Checks if the current position internally is still valid * @link https://php.net/manual/en/solrdocument.valid.php * @return bool

* Returns TRUE on success or FALSE on failure. *

*/ public function valid() {} }