FSTransaction Class Reference

Wrapper for file store transaction stuff. More...

List of all members.

Public Member Functions

 add (FSTransaction $transaction)
 Combine more items into a fancier transaction.
 commit ()
 Perform final actions for success.
 rollback ()
 Perform final actions for failure.
 __construct ()
 addCommit ($action, $path)
 addRollback ($action, $path)

Public Attributes

const DELETE_FILE = 1

Private Member Functions

 apply ($actions)


Detailed Description

Wrapper for file store transaction stuff.

FileStore methods may return one of these for undoable operations; you can then call its rollback() or commit() methods to perform final cleanup if dependent database work fails or succeeds.

Definition at line 294 of file FileStore.php.


Constructor & Destructor Documentation

FSTransaction::__construct (  ) 

Definition at line 325 of file FileStore.php.


Member Function Documentation

FSTransaction::add ( FSTransaction transaction  ) 

Combine more items into a fancier transaction.

Definition at line 300 of file FileStore.php.

FSTransaction::addCommit ( action,
path 
)

Definition at line 330 of file FileStore.php.

References $action, and $path.

FSTransaction::addRollback ( action,
path 
)

Definition at line 334 of file FileStore.php.

References $action, and $path.

FSTransaction::apply ( actions  )  [private]

Definition at line 338 of file FileStore.php.

References $action, $ok, $path, $result, wfDebug(), wfRestoreWarnings(), and wfSuppressWarnings().

Referenced by commit(), and rollback().

FSTransaction::commit (  ) 

Perform final actions for success.

Returns:
true if actions applied ok, false if errors

Definition at line 311 of file FileStore.php.

References apply().

FSTransaction::rollback (  ) 

Perform final actions for failure.

Returns:
true if actions applied ok, false if errors

Definition at line 319 of file FileStore.php.

References apply().


Member Data Documentation

Definition at line 295 of file FileStore.php.

Referenced by FileStore::copyFile(), DeleteArchivedFiles(), and FileStore::deleteFile().


The documentation for this class was generated from the following file:

Generated on Sat Sep 5 02:08:38 2009 for MediaWiki by  doxygen 1.5.9