Cursor Cursor Cursor Cursor Class
public ref class Cursor sealed : IDisposable
public sealed class Cursor : IDisposable
type Cursor = class interface IDisposable
Public NotInheritable Class Cursor Implements IDisposable
A Cursor is used with such methods as Peek(TimeSpan, Cursor, PeekAction) and Receive(TimeSpan, Cursor) when you need to read messages that are not at the front of the queue. This includes reading messages synchronously or asynchronously. Cursors do not need to be used to read only the first message in a queue.
When reading messages within a transaction, Message Queuing does not roll back cursor movement if the transaction is aborted. For example, suppose there is a queue with two messages, A1 and A2. If you remove message A1 while in a transaction, Message Queuing moves the cursor to message A2. However, if the transaction is aborted for any reason, message A1 is inserted back into the queue but the cursor remains pointing at message A2.
To close the cursor, call Close.
|Close() Close() Close() Close()||
Closes the cursor, allowing Message Queuing to release the associated resources.
|Dispose() Dispose() Dispose() Dispose()||
Releases all resources used by the Cursor.
|Equals(Object) Equals(Object) Equals(Object) Equals(Object)||
Determines whether the specified object is equal to the current object.(Inherited from Object)
|Finalize() Finalize() Finalize() Finalize()|
|GetHashCode() GetHashCode() GetHashCode() GetHashCode()||
Serves as the default hash function.(Inherited from Object)
|GetType() GetType() GetType() GetType()||
Gets the Type of the current instance.(Inherited from Object)
|MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()||
Creates a shallow copy of the current Object.(Inherited from Object)
|ToString() ToString() ToString() ToString()||
Returns a string that represents the current object.(Inherited from Object)