Click or drag to resize

EditFileManagerOnPrepareFileStream Method

Prepares the stream for managing the file.

Namespace:  Novacta.Transactions.IO
Assembly:  Novacta.Transactions.IO (in Novacta.Transactions.IO.dll) Version: 1.0.0
Syntax
protected override FileStream OnPrepareFileStream(
	string managedPath
)

Parameters

managedPath
Type: SystemString
The path of the managed file.

Return Value

Type: FileStream
The stream for the managed file.
Remarks

This method is called when the FileManager is notified that a transaction is being prepared for commitment.

Notes to Inheritors

You should throw an exception from this method in case the manager cannot prepare for the transaction to complete. The call to OnPrepareFileStream(String) is wrapped within the Prepare(PreparingEnlistment) method with a try/catch block: the catch block will pass any exception on via the ForceRollback(Exception) method.

See Also