SearchIndexClient.GetAlias Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| GetAlias(String, RequestContext) |
[Protocol Method] Retrieves an alias definition.
|
| GetAlias(String, CancellationToken) |
Retrieves an alias definition. |
GetAlias(String, RequestContext)
- Source:
- SearchIndexClient.cs
[Protocol Method] Retrieves an alias definition.
- This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual Azure.Response GetAlias(string aliasName, Azure.RequestContext context);
abstract member GetAlias : string * Azure.RequestContext -> Azure.Response
override this.GetAlias : string * Azure.RequestContext -> Azure.Response
Public Overridable Function GetAlias (aliasName As String, context As RequestContext) As Response
Parameters
- aliasName
- String
The name of the alias.
- 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
aliasName is null.
aliasName is an empty string, and was expected to be non-empty.
Service returned a non-success status code.
Applies to
GetAlias(String, CancellationToken)
- Source:
- SearchIndexClient.cs
- Source:
- SearchIndexClient.Aliases.cs
Retrieves an alias definition.
public virtual Azure.Response<Azure.Search.Documents.Indexes.Models.SearchAlias> GetAlias(string aliasName, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAlias : string * System.Threading.CancellationToken -> Azure.Response<Azure.Search.Documents.Indexes.Models.SearchAlias>
override this.GetAlias : string * System.Threading.CancellationToken -> Azure.Response<Azure.Search.Documents.Indexes.Models.SearchAlias>
Public Overridable Function GetAlias (aliasName As String, Optional cancellationToken As CancellationToken = Nothing) As Response(Of SearchAlias)
Parameters
- aliasName
- String
The name of the alias.
- cancellationToken
- CancellationToken
The cancellation token that can be used to cancel the operation.
Returns
SearchAlias defined by aliasName.
Exceptions
aliasName is null.
aliasName is an empty string, and was expected to be non-empty.
Service returned a non-success status code.