cleanupTrash() abstract public method

Will NOT remove associated content objects nor attributes. Basically truncates ezcontentobject_trash table.
abstract public cleanupTrash ( )
Example #1
0
 /**
  * Empties the trash
  * Everything contained in the trash must be removed
  *
  * @return void
  */
 public function emptyTrash()
 {
     $trashedItems = $this->findTrashItems();
     foreach ($trashedItems as $item) {
         $this->delete($item);
     }
     $this->locationGateway->cleanupTrash();
 }
 /**
  * Removes every entries in the trash.
  * Will NOT remove associated content objects nor attributes.
  *
  * Basically truncates ezcontentobject_trash table.
  *
  * @return void
  */
 public function cleanupTrash()
 {
     try {
         return $this->innerGateway->cleanupTrash();
     } catch (DBALException $e) {
         throw new RuntimeException('Database error', 0, $e);
     } catch (PDOException $e) {
         throw new RuntimeException('Database error', 0, $e);
     }
 }