Class Apache_Solr_Document

Description

Implements interfaces:

  • Iterator (internal interface)

Holds Key / Value pairs that represent a Solr Document. Field values can be accessed by direct dereferencing such as:

$document->title = 'Something'; echo $document->title; ... </code>

Additionally, the field values can be iterated with foreach

  1.  foreach ($document as $key => $value)
  2.  {
  3.  ...
  4.  }

Located in /Document.php (line 42)


	
			
Method Summary
void current ()
array getFieldNames ()
void key ()
void next ()
void rewind ()
void setMultiValue (string $key, string $value)
void valid ()
mixed __get (string $key)
boolean __isset (string $key)
void __set (string $key, mixed $value)
void __unset (string $key)
Methods
current (line 154)

Iterator implementation function, proxies to _fields. Allows usage:

  1.  foreach ($document as $key => $value)
  2.  {
  3.      ...
  4.  }

  • access: public
void current ()

Implementation of:
Iterator::current
getFieldNames (line 125)

Get the names of all fields in this document

  • access: public
array getFieldNames ()
key (line 168)

Iterator implementation function, proxies to _fields. Allows usage:

  1.  foreach ($document as $key => $value)
  2.  {
  3.      ...
  4.  }

  • access: public
void key ()

Implementation of:
Iterator::key
next (line 182)

Iterator implementation function, proxies to _fields. Allows usage:

  1.  foreach ($document as $key => $value)
  2.  {
  3.      ...
  4.  }

  • access: public
void next ()

Implementation of:
Iterator::next
rewind (line 140)

Iterator implementation function, proxies to _fields. Allows usage:

  1.  foreach ($document as $key => $value)
  2.  {
  3.      ...
  4.  }

  • access: public
void rewind ()

Implementation of:
Iterator::rewind
setMultiValue (line 105)

Handle the array manipulation for a multi-valued field

  • access: public
void setMultiValue (string $key, string $value)
  • string $key
  • string $value
valid (line 196)

Iterator implementation function, proxies to _fields. Allows usage:

  1.  foreach ($document as $key => $value)
  2.  {
  3.      ...
  4.  }

  • access: public
void valid ()

Implementation of:
Iterator::valid
__get (line 52)

Magic get for field values

  • access: public
mixed __get (string $key)
  • string $key
__isset (line 80)

Magic isset for fields values. Do no call directly. Allows usage:

  1.  isset($document->some_field);

  • access: public
boolean __isset (string $key)
  • string $key
__set (line 65)

Magic set for field values. Multi-valued fields should be set as arrays or instead use the setMultiValue(...) function which will automatically make sure the field is an array.

  • access: public
void __set (string $key, mixed $value)
  • string $key
  • mixed $value
__unset (line 94)

Magic unset for field values. Do no call directly. Allows usage:

  1.  unset($document->some_field);

  • access: public
void __unset (string $key)
  • string $key

Documentation generated on Tue, 02 Oct 2007 12:55:37 -0400 by phpDocumentor 1.4.0