Cloud/DocumentService/Document.php
LICENSE
This source file is subject to the new BSD license that is bundled
with this package in the file LICENSE.txt.
It is also available through the world-wide-web at this URL:
http://framework.zend.com/license/new-bsd
If you did not receive a copy of the license and are unable to
obtain it through the world-wide-web, please send an email
to license@zend.com so we can send you a copy immediately.
- Category
- Zend
- Copyright
- Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
- Package
- Zend_Cloud
- Subpackage
- DocumentService
\Zend_Cloud_DocumentService_Document
Package: Zend\Cloud\DocumentServiceClass encapsulating documents.
Fields are stored in a name/value
array. Data are represented as strings.
TODO Can fields be large enough to warrant support for streams?
- Implements
- Category
- Zend
- Copyright
- Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)
- License
- New BSD License
Constants


KEY_FIELD
= '_id'key in document denoting identifier
Properties
Methods



__call(string $name, mixed $args) : mixedOverloading: retrieve and set fields by name
Parameters| Name | Type | Description |
|---|
| $name | string | |
|---|
| $args | mixed | |
|---|
Returns 


__construct(array $fields, mixed $id = null) : voidConstruct an instance of Zend_Cloud_DocumentService_Document.
If no identifier is provided, but a field matching KEY_FIELD is present,
then that field's value will be used as the document identifier.
Parameters| Name | Type | Description |
|---|
| $fields | array | |
|---|
| $id | mixed | Document identifier |
|---|



offsetExists(string $name) : boolArrayAccess: does field exist?
Parameters| Name | Type | Description |
|---|
| $name | string | |
|---|
Returns 


offsetGet(string $name) : mixedArrayAccess: get field by name
Parameters| Name | Type | Description |
|---|
| $name | string | |
|---|
Returns 


offsetSet(string $name, mixed $value) : voidArrayAccess: set field to value
Parameters| Name | Type | Description |
|---|
| $name | string | |
|---|
| $value | mixed | |
|---|



offsetUnset(string $name) : voidArrayAccess: remove field from document
Parameters| Name | Type | Description |
|---|
| $name | string | |
|---|