PHP Class GDS\Mapper

Author: Tom Walder ([email protected])
Afficher le fichier Open project: tomwalder/php-gds

Protected Properties

Свойство Type Description
$obj_schema Schema Current Schema

Méthodes publiques

Méthode Description
mapFromResults ( array $arr_results ) : Entity[] | null Map 1-many results out of the Raw response data array
mapOneFromResult ( object $obj_result ) : Entity Map a single result out of the Raw response data array FROM Google TO a GDS Entity
setSchema ( Schema $obj_schema ) Set the schema

Méthodes protégées

Méthode Description
determineDynamicType ( $mix_value ) : array Dynamically determine type for a value
extractAutoDetectValue ( object $obj_property ) : mixed Auto detect & extract a value
extractDatetimeValue ( $obj_property ) : mixed Extract a datetime value
extractGeopointValue ( $obj_property ) : Geopoint Extract a Geopoint value
extractPropertyValue ( $int_type, object $obj_property ) : mixed Extract a single property value from a Property object
extractStringListValue ( $obj_property ) : mixed Extract a String List value

Method Details

determineDynamicType() protected méthode

Dynamically determine type for a value
protected determineDynamicType ( $mix_value ) : array
$mix_value
Résultat array

extractAutoDetectValue() abstract protected méthode

Auto detect & extract a value
abstract protected extractAutoDetectValue ( object $obj_property ) : mixed
$obj_property object
Résultat mixed

extractDatetimeValue() abstract protected méthode

Extract a datetime value
abstract protected extractDatetimeValue ( $obj_property ) : mixed
$obj_property
Résultat mixed

extractGeopointValue() abstract protected méthode

Extract a Geopoint value
abstract protected extractGeopointValue ( $obj_property ) : Geopoint
$obj_property
Résultat GDS\Property\Geopoint

extractPropertyValue() abstract protected méthode

Defer any varying data type extractions to child classes
abstract protected extractPropertyValue ( $int_type, object $obj_property ) : mixed
$int_type
$obj_property object
Résultat mixed

extractStringListValue() abstract protected méthode

Extract a String List value
abstract protected extractStringListValue ( $obj_property ) : mixed
$obj_property
Résultat mixed

mapFromResults() public méthode

Map 1-many results out of the Raw response data array
public mapFromResults ( array $arr_results ) : Entity[] | null
$arr_results array
Résultat Entity[] | null

mapOneFromResult() abstract public méthode

Map a single result out of the Raw response data array FROM Google TO a GDS Entity
abstract public mapOneFromResult ( object $obj_result ) : Entity
$obj_result object
Résultat Entity

setSchema() public méthode

Set the schema
public setSchema ( Schema $obj_schema )
$obj_schema Schema

Property Details

$obj_schema protected_oe property

Current Schema
protected Schema,gds $obj_schema
Résultat Schema