Exemplo n.º 1
0
 public function getOwnerObject()
 {
     $c = new Criteria();
     $c->add(CarduserPeer::ID, $this->getOwner(), Criteria::EQUAL);
     return CarduserPeer::doSelectOne($c);
 }
Exemplo n.º 2
0
 /**
  * Get the associated Carduser object
  *
  * @param      PropelPDO Optional Connection object.
  * @return     Carduser The associated Carduser object.
  * @throws     PropelException
  */
 public function getCarduser(PropelPDO $con = null)
 {
     if ($this->aCarduser === null && $this->owner !== null) {
         $c = new Criteria(CarduserPeer::DATABASE_NAME);
         $c->add(CarduserPeer::ID, $this->owner);
         $this->aCarduser = CarduserPeer::doSelectOne($c, $con);
         /* The following can be used additionally to
         		   guarantee the related object contains a reference
         		   to this object.  This level of coupling may, however, be
         		   undesirable since it could result in an only partially populated collection
         		   in the referenced object.
         		   $this->aCarduser->addCards($this);
         		 */
     }
     return $this->aCarduser;
 }