當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Zend_Mail_Storage_Abstract類代碼示例

本文整理匯總了PHP中Zend_Mail_Storage_Abstract的典型用法代碼示例。如果您正苦於以下問題:PHP Zend_Mail_Storage_Abstract類的具體用法?PHP Zend_Mail_Storage_Abstract怎麽用?PHP Zend_Mail_Storage_Abstract使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了Zend_Mail_Storage_Abstract類的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: __get

 /**
  * Special handling for hasTop and hasUniqueid. The headers of the first message is
  * retrieved if Top wasn't needed/tried yet.
  *
  * @see Zend_Mail_Storage_Abstract:__get()
  * @param  string $var
  * @return string
  * @throws Zend_Mail_Storage_Exception
  */
 public function __get($var)
 {
     $result = parent::__get($var);
     if ($result !== null) {
         return $result;
     }
     if (strtolower($var) == 'hastop') {
         if ($this->_protocol->hasTop === null) {
             // need to make a real call, because not all server are honest in their capas
             try {
                 $this->_protocol->top(1, 0, false);
             } catch (Zend_Mail_Exception $e) {
                 // ignoring error
             }
         }
         $this->_has['top'] = $this->_protocol->hasTop;
         return $this->_protocol->hasTop;
     }
     if (strtolower($var) == 'hasuniqueid') {
         $id = null;
         try {
             $id = $this->_protocol->uniqueid(1);
         } catch (Zend_Mail_Exception $e) {
             // ignoring error
         }
         $this->_has['uniqueid'] = $id ? true : false;
         return $this->_has['uniqueid'];
     }
     return $result;
 }
開發者ID:ismaelmelus,項目名稱:home,代碼行數:39,代碼來源:Pop3.php

示例2: __get

 /**
  * Special handling for hasTop. The headers of the first message is
  * retrieved if Top wasn't needed/tried yet.
  *
  * @see Zend_Mail_Storage_Abstract:__get()
  * @param  string $var
  * @return string
  * @throws Zend_Mail_Storage_Exception
  */
 public function __get($var)
 {
     if (strtolower($var) == 'hastop') {
         if ($this->_protocol->hasTop === null) {
             // need to make a real call, because not all server are honest in their capas
             try {
                 $this->_protocol->top(1, 0, false);
             } catch (Zend_Mail_Exception $e) {
                 // ignoring error
             }
         }
         return $this->_protocol->hasTop;
     }
     return parent::__get($var);
 }
開發者ID:jorgenils,項目名稱:zend-framework,代碼行數:24,代碼來源:Pop3.php

示例3: getHeaders

 /**
  * Get all headers
  *
  * The returned headers are as saved internally. All names are lowercased. The value is a string or an array
  * if a header with the same name occurs more than once.
  *
  * @return array headers as array(name => value)
  */
 public function getHeaders()
 {
     if ($this->_headers === null) {
         if (!$this->_mail) {
             $this->_headers = array();
         } else {
             $part = $this->_mail->getRawHeader($this->_messageNum);
             Zend_Mime_Decode::splitMessage($part, $this->_headers, $null);
         }
     }
     return $this->_headers;
 }
開發者ID:bartolomeu,項目名稱:estoque_gusella,代碼行數:20,代碼來源:Part.php


注:本文中的Zend_Mail_Storage_Abstract類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。