KnowledgeBases.GetAsync Method

Definition

Overloads

Name Description
GetAsync(String, RequestContext)

[Protocol Method] Fetch a KnowledgeBase by name.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
GetAsync(String, CancellationToken)

Fetch a KnowledgeBase by name.

GetAsync(String, RequestContext)

Source:
KnowledgeBases.cs

[Protocol Method] Fetch a KnowledgeBase by name.

  • This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual System.Threading.Tasks.Task<Azure.Response> GetAsync(string knowledgeBaseName, Azure.RequestContext context);
abstract member GetAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.GetAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function GetAsync (knowledgeBaseName As String, context As RequestContext) As Task(Of Response)

Parameters

knowledgeBaseName
String

The knowledgeBase name.

context
RequestContext

The request options, which can override default behaviors of the client pipeline on a per-call basis.

Returns

The response returned from the service.

Exceptions

knowledgeBaseName is null.

knowledgeBaseName is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to

GetAsync(String, CancellationToken)

Source:
KnowledgeBases.cs

Fetch a KnowledgeBase by name.

public virtual System.Threading.Tasks.Task<Azure.Response<Azure.AI.Discovery.KnowledgeBase>> GetAsync(string knowledgeBaseName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.AI.Discovery.KnowledgeBase>>
override this.GetAsync : string * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.AI.Discovery.KnowledgeBase>>
Public Overridable Function GetAsync (knowledgeBaseName As String, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of KnowledgeBase))

Parameters

knowledgeBaseName
String

The knowledgeBase name.

cancellationToken
CancellationToken

The cancellation token that can be used to cancel the operation.

Returns

Exceptions

knowledgeBaseName is null.

knowledgeBaseName is an empty string, and was expected to be non-empty.

Service returned a non-success status code.

Applies to