getStamp() 공개 메소드

Returns a stamp for the current folder status. This stamp can be used to identify changes in the folder data.
public getStamp ( string $folder ) : Horde_Kolab_Storage_Folder_Stamp
$folder string Return the stamp for this folder.
리턴 Horde_Kolab_Storage_Folder_Stamp A stamp indicating the current folder status.
예제 #1
0
파일: Base.php 프로젝트: platolin/horde
 /**
  * Report the status of this folder.
  *
  * @param Horde_Kolab_Storage_Folder_Stamp $previous  The previous stamp,
  *                                                    if available.
  *
  * @return Horde_Kolab_Storage_Folder_Stamp The stamp that can be used for
  *                                          detecting folder changes.
  */
 public function getStamp(Horde_Kolab_Storage_Folder_Stamp $previous = null)
 {
     if (empty($previous) || $previous->getToken() === false) {
         $this->_logger->debug('[KOLAB_STORAGE] Fetching stamp without token.');
         return $this->_driver->getStamp($this->_folder->getPath());
     }
     try {
         $this->_logger->debug('[KOLAB_STORAGE] Fetching stamp WITH token.');
         return $this->_driver->getStampFromToken($this->_folder->getPath(), $previous->getToken(), $previous->ids());
     } catch (Horde_Kolab_Storage_Exception $e) {
         // Possibly not supported with the current IMAP driver.
         $this->_logger->debug('[KOLAB_STORAGE] Attempted to fetch stamp with token, but backend did not support.');
         return $this->_driver->getStamp($this->_folder->getPath());
     }
 }
예제 #2
0
파일: Base.php 프로젝트: jubinpatel/horde
 /**
  * Returns a stamp for the current folder status. This stamp can be used to
  * identify changes in the folder data.
  *
  * @param string $folder Return the stamp for this folder.
  *
  * @return Horde_Kolab_Storage_Folder_Stamp A stamp indicating the current
  *                                          folder status.
  */
 public function getStamp($folder)
 {
     return $this->_driver->getStamp($folder);
 }
예제 #3
0
파일: Base.php 프로젝트: jubinpatel/horde
 /**
  * Report the status of this folder.
  *
  * @return Horde_Kolab_Storage_Folder_Stamp The stamp that can be used for
  *                                          detecting folder changes.
  */
 public function getStamp()
 {
     return $this->_driver->getStamp($this->_folder->getPath());
 }