/** * Override method to perform a property "Get" * This will get the value of $strName * * @param string $strName Name of the property to get * @return mixed */ public function __get($strName) { switch ($strName) { /////////////////// // Member Variables /////////////////// case 'Id': // Gets the value for intId (Read-Only PK) // @return integer return $this->intId; case 'PackageCategoryId': // Gets the value for intPackageCategoryId (Not Null) // @return integer return $this->intPackageCategoryId; case 'Token': // Gets the value for strToken (Unique) // @return string return $this->strToken; case 'Name': // Gets the value for strName // @return string return $this->strName; case 'Description': // Gets the value for strDescription // @return string return $this->strDescription; case 'LastPostDate': // Gets the value for dttLastPostDate // @return QDateTime return $this->dttLastPostDate; case 'LastPostedByPersonId': // Gets the value for intLastPostedByPersonId // @return integer return $this->intLastPostedByPersonId; /////////////////// // Member Objects /////////////////// /////////////////// // Member Objects /////////////////// case 'PackageCategory': // Gets the value for the PackageCategory object referenced by intPackageCategoryId (Not Null) // @return PackageCategory try { if (!$this->objPackageCategory && !is_null($this->intPackageCategoryId)) { $this->objPackageCategory = PackageCategory::Load($this->intPackageCategoryId); } return $this->objPackageCategory; } catch (QCallerException $objExc) { $objExc->IncrementOffset(); throw $objExc; } case 'LastPostedByPerson': // Gets the value for the Person object referenced by intLastPostedByPersonId // @return Person try { if (!$this->objLastPostedByPerson && !is_null($this->intLastPostedByPersonId)) { $this->objLastPostedByPerson = Person::Load($this->intLastPostedByPersonId); } return $this->objLastPostedByPerson; } catch (QCallerException $objExc) { $objExc->IncrementOffset(); throw $objExc; } case 'TopicLink': // Gets the value for the TopicLink object that uniquely references this Package // by objTopicLink (Unique) // @return TopicLink try { if ($this->objTopicLink === false) { // We've attempted early binding -- and the reverse reference object does not exist return null; } if (!$this->objTopicLink) { $this->objTopicLink = TopicLink::LoadByPackageId($this->intId); } return $this->objTopicLink; } catch (QCallerException $objExc) { $objExc->IncrementOffset(); throw $objExc; } //////////////////////////// // Virtual Object References (Many to Many and Reverse References) // (If restored via a "Many-to" expansion) //////////////////////////// //////////////////////////// // Virtual Object References (Many to Many and Reverse References) // (If restored via a "Many-to" expansion) //////////////////////////// case '_PackageContribution': // Gets the value for the private _objPackageContribution (Read-Only) // if set due to an expansion on the package_contribution.package_id reverse relationship // @return PackageContribution return $this->_objPackageContribution; case '_PackageContributionArray': // Gets the value for the private _objPackageContributionArray (Read-Only) // if set due to an ExpandAsArray on the package_contribution.package_id reverse relationship // @return PackageContribution[] return (array) $this->_objPackageContributionArray; case '__Restored': return $this->__blnRestored; default: try { return parent::__get($strName); } catch (QCallerException $objExc) { $objExc->IncrementOffset(); throw $objExc; } } }