Compartilhar via


DocumentsExtensibility.OpenDocumentAsync Method

Definition

Overloads

OpenDocumentAsync(Uri, CancellationToken)

Opens the document identified by moniker.

OpenDocumentAsync(Uri, OpenDocumentOptions, CancellationToken)

Opens the document identified by moniker.

OpenDocumentAsync(Uri, CancellationToken)

Opens the document identified by moniker.

public System.Threading.Tasks.Task<Microsoft.VisualStudio.RpcContracts.Documents.DocumentSnapshot> OpenDocumentAsync (Uri moniker, System.Threading.CancellationToken token);
member this.OpenDocumentAsync : Uri * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.VisualStudio.RpcContracts.Documents.DocumentSnapshot>
Public Function OpenDocumentAsync (moniker As Uri, token As CancellationToken) As Task(Of DocumentSnapshot)

Parameters

moniker
Uri

The moniker of the document to search for.

token
CancellationToken

The cancellation token.

Returns

The document.

Remarks

If the document identified by moniker is already open, its DocumentSnapshot is returned.

Applies to

OpenDocumentAsync(Uri, OpenDocumentOptions, CancellationToken)

Opens the document identified by moniker.

public System.Threading.Tasks.Task<Microsoft.VisualStudio.RpcContracts.Documents.DocumentSnapshot> OpenDocumentAsync (Uri moniker, Microsoft.VisualStudio.RpcContracts.OpenDocument.OpenDocumentOptions options, System.Threading.CancellationToken token);
member this.OpenDocumentAsync : Uri * Microsoft.VisualStudio.RpcContracts.OpenDocument.OpenDocumentOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.VisualStudio.RpcContracts.Documents.DocumentSnapshot>
Public Function OpenDocumentAsync (moniker As Uri, options As OpenDocumentOptions, token As CancellationToken) As Task(Of DocumentSnapshot)

Parameters

moniker
Uri

The moniker of the document to search for.

options
OpenDocumentOptions

Options defining how to open the document.

token
CancellationToken

The cancellation token.

Returns

The document.

Remarks

If the document identified by moniker is already open, its DocumentSnapshot is returned.

Applies to