예제 #1
0
 /**
  * Reload this DlePost from the database.
  * @return void
  */
 public function Reload()
 {
     // Make sure we are actually Restored from the database
     if (!$this->__blnRestored) {
         throw new QCallerException('Cannot call Reload() on a new, unsaved DlePost object.');
     }
     $this->DeleteCache();
     // Reload the Object
     $objReloaded = DlePost::Load($this->intId);
     // Update $this's local variables to match
     $this->strAutor = $objReloaded->strAutor;
     $this->dttDate = $objReloaded->dttDate;
     $this->strShortStory = $objReloaded->strShortStory;
     $this->strFullStory = $objReloaded->strFullStory;
     $this->strXfields = $objReloaded->strXfields;
     $this->strTitle = $objReloaded->strTitle;
     $this->strDescr = $objReloaded->strDescr;
     $this->strKeywords = $objReloaded->strKeywords;
     $this->strCategory = $objReloaded->strCategory;
     $this->strAltName = $objReloaded->strAltName;
     $this->intCommNum = $objReloaded->intCommNum;
     $this->blnAllowComm = $objReloaded->blnAllowComm;
     $this->blnAllowMain = $objReloaded->blnAllowMain;
     $this->blnAllowRate = $objReloaded->blnAllowRate;
     $this->blnApprove = $objReloaded->blnApprove;
     $this->blnFixed = $objReloaded->blnFixed;
     $this->intRating = $objReloaded->intRating;
     $this->blnAllowBr = $objReloaded->blnAllowBr;
     $this->intVoteNum = $objReloaded->intVoteNum;
     $this->intNewsRead = $objReloaded->intNewsRead;
     $this->blnVotes = $objReloaded->blnVotes;
     $this->strAccess = $objReloaded->strAccess;
     $this->strSymbol = $objReloaded->strSymbol;
     $this->blnFlag = $objReloaded->blnFlag;
     $this->strEditdate = $objReloaded->strEditdate;
     $this->strEditor = $objReloaded->strEditor;
     $this->strReason = $objReloaded->strReason;
     $this->blnViewEdit = $objReloaded->blnViewEdit;
     $this->strTags = $objReloaded->strTags;
     $this->strMetatitle = $objReloaded->strMetatitle;
 }
예제 #2
0
 /**
  * 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 'NewsId':
             /**
              * Gets the value for intNewsId (Not Null)
              * @return integer
              */
             return $this->intNewsId;
         case 'Title':
             /**
              * Gets the value for strTitle (Not Null)
              * @return string
              */
             return $this->strTitle;
         case 'Frage':
             /**
              * Gets the value for strFrage (Not Null)
              * @return string
              */
             return $this->strFrage;
         case 'Body':
             /**
              * Gets the value for strBody (Not Null)
              * @return string
              */
             return $this->strBody;
         case 'Votes':
             /**
              * Gets the value for intVotes (Not Null)
              * @return integer
              */
             return $this->intVotes;
         case 'Multiple':
             /**
              * Gets the value for blnMultiple (Not Null)
              * @return boolean
              */
             return $this->blnMultiple;
         case 'Answer':
             /**
              * Gets the value for strAnswer (Not Null)
              * @return string
              */
             return $this->strAnswer;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'News':
             /**
              * Gets the value for the DlePost object referenced by intNewsId (Not Null)
              * @return DlePost
              */
             try {
                 if (!$this->objNews && !is_null($this->intNewsId)) {
                     $this->objNews = DlePost::Load($this->intNewsId);
                 }
                 return $this->objNews;
             } 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 '__Restored':
             return $this->__blnRestored;
         default:
             try {
                 return parent::__get($strName);
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
     }
 }
예제 #3
0
 /**
  * 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 'PostId':
             /**
              * Gets the value for intPostId (Not Null)
              * @return integer
              */
             return $this->intPostId;
         case 'UserId':
             /**
              * Gets the value for intUserId (Not Null)
              * @return integer
              */
             return $this->intUserId;
         case 'Date':
             /**
              * Gets the value for dttDate (Not Null)
              * @return QDateTime
              */
             return $this->dttDate;
         case 'Autor':
             /**
              * Gets the value for strAutor (Not Null)
              * @return string
              */
             return $this->strAutor;
         case 'Email':
             /**
              * Gets the value for strEmail (Not Null)
              * @return string
              */
             return $this->strEmail;
         case 'Text':
             /**
              * Gets the value for strText (Not Null)
              * @return string
              */
             return $this->strText;
         case 'Ip':
             /**
              * Gets the value for strIp (Not Null)
              * @return string
              */
             return $this->strIp;
         case 'IsRegister':
             /**
              * Gets the value for blnIsRegister (Not Null)
              * @return boolean
              */
             return $this->blnIsRegister;
         case 'Approve':
             /**
              * Gets the value for blnApprove (Not Null)
              * @return boolean
              */
             return $this->blnApprove;
             ///////////////////
             // Member Objects
             ///////////////////
         ///////////////////
         // Member Objects
         ///////////////////
         case 'Post':
             /**
              * Gets the value for the DlePost object referenced by intPostId (Not Null)
              * @return DlePost
              */
             try {
                 if (!$this->objPost && !is_null($this->intPostId)) {
                     $this->objPost = DlePost::Load($this->intPostId);
                 }
                 return $this->objPost;
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
         case 'User':
             /**
              * Gets the value for the DleUsers object referenced by intUserId (Not Null)
              * @return DleUsers
              */
             try {
                 if (!$this->objUser && !is_null($this->intUserId)) {
                     $this->objUser = DleUsers::Load($this->intUserId);
                 }
                 return $this->objUser;
             } 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 '__Restored':
             return $this->__blnRestored;
         default:
             try {
                 return parent::__get($strName);
             } catch (QCallerException $objExc) {
                 $objExc->IncrementOffset();
                 throw $objExc;
             }
     }
 }