Copyright 2011-2014 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
Author: Gunnar Wrobel (wrobel@pardus.de)
Inheritance: implements Horde_Kolab_Storage_Data, implements Horde_Kolab_Storage_Data_Query
Esempio n. 1
0
 /**
  * Perform a complete synchronization.
  *
  * @param Horde_Kolab_Storage_Folder_Stamp $stamp The current stamp.
  * @param array $params Additional parameters.
  *
  * @return NULL
  */
 private function _completeSynchronization(Horde_Kolab_Storage_Folder_Stamp $stamp, $params = array())
 {
     $this->_data_cache->reset();
     $ids = $stamp->ids();
     $params['last_sync'] = false;
     $params['changes'][Horde_Kolab_Storage_Folder_Stamp::ADDED] = empty($ids) ? array() : $this->fetch($ids);
     // logging
     $uids_to_log = array_keys($params['changes'][Horde_Kolab_Storage_Folder_Stamp::ADDED]);
     $this->_logger->debug(sprintf('[KOLAB_STORAGE] Full folder sync details: user: %s, folder: %s, uids: %s', $this->getAuth(), $this->getPath(), implode(', ', $uids_to_log)));
     $this->_data_cache->store($params['changes'][Horde_Kolab_Storage_Folder_Stamp::ADDED], $stamp, $this->getVersion());
     $params['current_sync'] = $this->_data_cache->getLastSync();
     parent::synchronize($params);
     $this->_data_cache->save();
 }
Esempio n. 2
0
 /**
  * Perform a complete synchronization.
  *
  * @param Horde_Kolab_Storage_Folder_Stamp $stamp The current stamp.
  * @param array $params Additional parameters.
  *
  * @return NULL
  */
 private function _completeSynchronization(Horde_Kolab_Storage_Folder_Stamp $stamp, $params = array())
 {
     $this->_data_cache->reset();
     $ids = $stamp->ids();
     $params['last_sync'] = false;
     $params['changes'][Horde_Kolab_Storage_Folder_Stamp::ADDED] = empty($ids) ? array() : $this->fetch($ids);
     $this->_data_cache->store($params['changes'][Horde_Kolab_Storage_Folder_Stamp::ADDED], $stamp, $this->getVersion());
     $params['current_sync'] = $this->_data_cache->getLastSync();
     parent::synchronize($params);
     $this->_data_cache->save();
 }