示例#1
0
 /**
  * Returns list of identities belonging to account.
  * 
  * @param int $IdAccount Identifier of account that contains identities to get.
  * 
  * @return array|bool
  */
 public function getAccountIdentities($IdAccount)
 {
     $aIdentities = false;
     if ($this->oConnection->Execute($this->oCommandCreator->getAccountIdentitiesQuery($IdAccount))) {
         $aIdentities = array();
         $oRow = null;
         while (false !== ($oRow = $this->oConnection->GetNextRecord())) {
             $oIdentity = new CIdentity();
             $oIdentity->InitByDbRow($oRow);
             $aIdentities[] = $oIdentity;
         }
     }
     $this->throwDbExceptionIfExist();
     return $aIdentities;
 }