public function __construct($id = null, $apiKey = null, $parent = null, $name = null)
{
$this->_apiKey = $apiKey;
$this->_values = array();
$this->_unsavedValues = array();
$this->_immutableValues = array('_apiKey', 'id');
$this->_parent = $parent;
$this->_name = $name;
$this->_retrieveOptions = array();
if (is_array($id)) {
foreach ($id as $key => $value) {
if ($key != 'id') {
$this->_retrieveOptions[$key] = $value;
}
}
$id = $id['id'];
}
if ($id) {
$this->id = $id;
}
}