Source for file Model.php
Documentation is available at Model.php
* Base class for all models
* The base class provides __set() and __get()
* as well as some other helper methods.
* @author Stephan Schmidt <schst@php.net>
* @todo different caches for different detail levels
* @todo add the possibility to disable the cache for single models
* properties of the model
* properties that are stored in eBay's database
* These are stored to check, which fields have been modified
* optional session, used to send API calls
* @var object Services_Ebay_Session
* property that stores the unique identifier (=pk) of the model
* store the static cache for all models of this type
* @var object Services_Ebay_Cache
protected static $cache = null;
* indicates, whether the model has been cached
* @param array properties
public function __construct($props, $session = null , $DetailLevel = 0 )
// try loading the data from the cache
if (is_array ($cacheProps)) {
* check, whether the model has been cached
* @param object Services_Ebay_Session
public function setSession(Services_Ebay_Session $session)
* @param object Services_Ebay_Cache
static public function setCache(Services_Ebay_Cache $cache)
* @param string property name
* @return mixed property value
public function __get($prop)
* @param string property name
* @param mixed property value
public function __set($prop, $value)
* return all properties of the user
* get the properties that have been modified,
* since the item has been fetched the last
* This does not involve an API-call
$modified[$key] = $value;
$modified[$key] = $value;
* check, whether a property exists
* This is needed to implement the ArrayAccess interface
* This is needed to implement the ArrayAccess interface
* This is needed to implement the ArrayAccess interface
* This is needed to implement the ArrayAccess interface
* get the primary key of the model
Documentation generated on Mon, 11 Mar 2019 15:49:49 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|