Google_Model
class Google_Model implements ArrayAccess (View source)
This class defines attributes, valid values, and usage which is generated from a given json schema.
http://tools.ietf.org/html/draft-zyp-json-schema-03#section-5
Constants
NULL_VALUE |
If you need to specify a NULL JSON value, use Google_Model::NULL_VALUE
instead - it will be replaced when converting to JSON with a real null. |
Properties
protected | $internal_gapi_mappings | ||
protected | $modelData | ||
protected | $processed |
Methods
Polymorphic - accepts a variable number of arguments dependent on the type of the model subclass.
Getter that handles passthrough access to the data array, and lazy object creation.
Initialize this object's properties from an array.
Blank initialiser to be used in subclasses to do post-construction initialisation - this avoids the need for subclasses to have to implement the variadics handling in their constructors.
Create a simplified object suitable for straightforward conversion to JSON. This is relatively expensive due to the usage of reflection, but shouldn't be called a whole lot, and is the most straightforward way to filter.
Returns true only if the array is associative.
Verify if $obj is an array.
No description
No description
No description
No description
No description
No description
No description
No description
Details
final
__construct()
Polymorphic - accepts a variable number of arguments dependent on the type of the model subclass.
mixed
__get(string $key)
Getter that handles passthrough access to the data array, and lazy object creation.
protected void
mapTypes(array $array)
Initialize this object's properties from an array.
protected
gapiInit()
Blank initialiser to be used in subclasses to do post-construction initialisation - this avoids the need for subclasses to have to implement the variadics handling in their constructors.
toSimpleObject()
Create a simplified object suitable for straightforward conversion to JSON. This is relatively expensive due to the usage of reflection, but shouldn't be called a whole lot, and is the most straightforward way to filter.
protected bool
isAssociativeArray(array $array)
Returns true only if the array is associative.
assertIsArray(array $obj, string $method)
Verify if $obj is an array.
offsetExists($offset)
No description
offsetGet($offset)
No description
offsetSet($offset, $value)
No description
offsetUnset($offset)
No description
protected
keyType($key)
No description
protected
dataType($key)
No description
__isset($key)
No description
__unset($key)
No description