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