Esempio n. 1
0
 /**
  * @return array
  */
 public function AjaxFoldersGetRelevantInformation()
 {
     $aFolders = $this->getParamValue('Folders', '');
     $sInboxUidnext = $this->getParamValue('InboxUidnext', '');
     if (!is_array($aFolders) || 0 === count($aFolders)) {
         throw new \ProjectSeven\Exceptions\ClientException(\ProjectSeven\Notifications::InvalidInputParameter);
     }
     $aResult = array();
     $oAccount = $this->getAccountFromParam();
     try {
         $aInboxNewData = array();
         $aResult = $this->oApiMail->FolderCountsFromArray($oAccount, $aFolders, $aInboxNewData, $sInboxUidnext);
     } catch (\MailSo\Net\Exceptions\ConnectionException $oException) {
         throw $oException;
     } catch (\MailSo\Imap\Exceptions\LoginException $oException) {
         throw $oException;
     } catch (\Exception $oException) {
         \CApi::Log((string) $oException);
     }
     return $this->DefaultResponse($oAccount, __FUNCTION__, array('Counts' => $aResult, 'New' => $aInboxNewData));
 }