Click or drag to resize

CreateFileManagerOnRollback Method

Called when the transaction is rolled back.

Namespace:  Novacta.Transactions.IO
Assembly:  Novacta.Transactions.IO (in Novacta.Transactions.IO.dll) Version: 1.0.0
Syntax
protected override void OnRollback()
Remarks

If the manager voted for rolling back the transaction, this method does nothing. Otherwise, the method operates as follows.

If the manager can overwrite the file, i.e. CanOverwrite evaluates to true, and the file already exists when the manager prepared for the transaction (FileAlreadyExists returns true), then the file is truncated when the stream is successfully instantiated. In such case, this method will restore the initial content of the managed file.

If the file did not exist when the manager prepared for the transaction, then the file is newly created when the stream is successfully instantiated. In such case, this method will mark the managed file for deletion.

See Also