Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Recording Namespace / Recording­Scope Class

RecordingScope Class

Defines the scope a logical operation, that is, a set of change that should be undone or redone as a whole.
Inheritance Hierarchy
System.Object
  PostSharp.Patterns.Recording.RecordingScope

Namespace:  PostSharp.Patterns.Recording
Assembly:  PostSharp.Patterns.Model (in PostSharp.Patterns.Model.dll) Version: 5.0.43.0 (5.0.43.0)
Syntax
C#
public sealed class RecordingScope : IDisposable

The RecordingScope type exposes the following members.

Properties
  NameDescription
Public propertyOperationDescriptor
Gets or sets the IOperationDescriptor for the current scope.
Methods
  NameDescription
Public methodComplete
Closes the current RecordingScope and mark it as successful.
Public methodDispose
Closes the current RecordingScope.
Extension Methods
  NameDescription
Public Extension MethodQueryInterface<T>
Gets the implementation of a specified interface for the specified object.
(Defined by QueryInterfaceExtensions.)
Remarks

Scopes can be defined declaratively using the RecordingScopeAttribute custom attribute.

To open a scope imperatively, use the OpenScope(RecordingScopeOption) method. Use the Complete() or Dispose() method to close the scope.

See Also