/** * Object destructor */ public function __destruct() { $this->commit(); if ($this->_closeDirOnExit) { $this->_directory->close(); } }
/** * Object destructor */ public function __destruct() { $this->commit(); // Free shared lock $this->_lock->unlock(); if ($this->_closeDirOnExit) { $this->_directory->close(); } }
/** * Close current index and free resources * * @internal */ public function close() { $this->commit(); // Free shared lock $this->_lock->unlock(); if ($this->_closeDirOnExit) { $this->_directory->close(); } $this->_directory = null; $this->_writer = null; $this->_segmentInfos = null; }
/** * Close current index and free resources */ private function _close() { if ($this->_closed) { // index is already closed and resources are cleaned up return; } $this->commit(); if ($this->_closeDirOnExit) { $this->_directory->close(); } $this->_directory = null; $this->_writer = null; $this->_segmentInfos = null; $this->_closed = true; }
/** * Close current index and free resources */ private function _close() { if ($this->_closed) { // index is already closed and resources are cleaned up return; } $this->commit(); // Release "under processing" flag Zend_Search_Lucene_LockManager::releaseReadLock($this->_directory); if ($this->_closeDirOnExit) { $this->_directory->close(); } $this->_directory = null; $this->_writer = null; $this->_segmentInfos = null; $this->_closed = true; }
/** * Close current index and free resources * * @internal */ public function close() { if ($this->_closed) { // index is already closed and resources are cleaned up return; } $this->commit(); // Free shared lock $this->_lock->unlock(); if ($this->_closeDirOnExit) { $this->_directory->close(); } $this->_directory = null; $this->_writer = null; $this->_segmentInfos = null; $this->_closed = true; }