azure-docs-sdk-java/legacy/docs-ref-autogen/com.microsoft.azure.service...

124 строки
10 KiB
YAML

### YamlMime:JavaType
uid: "com.microsoft.azure.servicebus.security.TokenProvider"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider"
name: "TokenProvider"
nameWithType: "TokenProvider"
summary: "This abstract class defines the contract of a token provider."
inheritances:
- "<xref href=\"java.lang.Object?displayProperty=fullName\" data-throw-if-not-resolved=\"False\" />"
inheritedClassMethods:
- classRef: "java.lang.<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html\">Object</a>"
methodsRef:
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#clone--\">clone</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#equals-java.lang.Object-\">equals</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#finalize--\">finalize</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#getClass--\">getClass</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#hashCode--\">hashCode</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notify--\">notify</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#notifyAll--\">notifyAll</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#toString--\">toString</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait--\">wait</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-\">wait</a>"
- "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html#wait-long-int-\">wait</a>"
syntax: "public abstract class **TokenProvider**"
constructors:
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.TokenProvider()"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.TokenProvider()"
name: "TokenProvider()"
nameWithType: "TokenProvider.TokenProvider()"
syntax: "public TokenProvider()"
methods:
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.createAzureActiveDirectoryTokenProvider(com.microsoft.azure.servicebus.security.AzureActiveDirectoryTokenProvider.AuthenticationCallback,java.lang.String,java.lang.Object)"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.createAzureActiveDirectoryTokenProvider(AzureActiveDirectoryTokenProvider.AuthenticationCallback callback, String authority, Object callbackState)"
name: "createAzureActiveDirectoryTokenProvider(AzureActiveDirectoryTokenProvider.AuthenticationCallback callback, String authority, Object callbackState)"
nameWithType: "TokenProvider.createAzureActiveDirectoryTokenProvider(AzureActiveDirectoryTokenProvider.AuthenticationCallback callback, String authority, Object callbackState)"
summary: "Creates a Azure Active Directory token provider that creates a token with the user defined Authentication<wbr>Callback."
modifiers:
- "static"
parameters:
- description: "A custom AuthenticationCallback that takes in the target resource and address of the authority \n to issue token and provides a security token for the target url"
name: "callback"
type: "<xref href=\"com.microsoft.azure.servicebus.security.AzureActiveDirectoryTokenProvider.AuthenticationCallback?alt=com.microsoft.azure.servicebus.security.AzureActiveDirectoryTokenProvider.AuthenticationCallback&text=AuthenticationCallback\" data-throw-if-not-resolved=\"False\" />"
- description: "URL of the Azure Active Directory instance"
name: "authority"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- description: "Custom parameter that may be provided to the AuthenticationCallback"
name: "callbackState"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html\">Object</a>"
syntax: "public static TokenProvider createAzureActiveDirectoryTokenProvider(AzureActiveDirectoryTokenProvider.AuthenticationCallback callback, String authority, Object callbackState)"
desc: "Creates a Azure Active Directory token provider that creates a token with the user defined AuthenticationCallback. This is a utility method."
returns:
description: "an instance of Azure Active Directory token provider"
type: "<xref href=\"com.microsoft.azure.servicebus.security.TokenProvider?alt=com.microsoft.azure.servicebus.security.TokenProvider&text=TokenProvider\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.createManagedIdentityTokenProvider()"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.createManagedIdentityTokenProvider()"
name: "createManagedIdentityTokenProvider()"
nameWithType: "TokenProvider.createManagedIdentityTokenProvider()"
summary: "Creates a Managed Identity token provider."
modifiers:
- "static"
syntax: "public static TokenProvider createManagedIdentityTokenProvider()"
desc: "Creates a Managed Identity token provider. This is a utility method."
returns:
description: "an instance of Managed Identity token provider"
type: "<xref href=\"com.microsoft.azure.servicebus.security.TokenProvider?alt=com.microsoft.azure.servicebus.security.TokenProvider&text=TokenProvider\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.createSharedAccessSignatureTokenProvider(java.lang.String,java.lang.String)"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.createSharedAccessSignatureTokenProvider(String sasKeyName, String sasKey)"
name: "createSharedAccessSignatureTokenProvider(String sasKeyName, String sasKey)"
nameWithType: "TokenProvider.createSharedAccessSignatureTokenProvider(String sasKeyName, String sasKey)"
summary: "Creates a Shared Access Signature token provider with the given key name and key value."
modifiers:
- "static"
parameters:
- description: "SAS key name"
name: "sasKeyName"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- description: "SAS key value"
name: "sasKey"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public static TokenProvider createSharedAccessSignatureTokenProvider(String sasKeyName, String sasKey)"
desc: "Creates a Shared Access Signature token provider with the given key name and key value. Returned token provider creates tokens with validity of 20 minutes. This is a utility method."
returns:
description: "an instance of Shared Access Signature token provider with the given key name, key value."
type: "<xref href=\"com.microsoft.azure.servicebus.security.TokenProvider?alt=com.microsoft.azure.servicebus.security.TokenProvider&text=TokenProvider\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.createSharedAccessSignatureTokenProvider(java.lang.String,java.time.Instant)"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.createSharedAccessSignatureTokenProvider(String sasToken, Instant sasTokenValidUntil)"
name: "createSharedAccessSignatureTokenProvider(String sasToken, Instant sasTokenValidUntil)"
nameWithType: "TokenProvider.createSharedAccessSignatureTokenProvider(String sasToken, Instant sasTokenValidUntil)"
summary: "Creates a Shared Access Signature token provider that always returns an already created token."
modifiers:
- "static"
parameters:
- description: "Already created Shared Access Signature token to be returned by <xref uid=\"com.microsoft.azure.servicebus.security.TokenProvider.getSecurityTokenAsync(java.lang.String)\" data-throw-if-not-resolved=\"false\" data-raw-source=\"#getSecurityTokenAsync(String)\"></xref> method."
name: "sasToken"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
- description: "Instant when the token expires"
name: "sasTokenValidUntil"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/time/Instant.html\">Instant</a>"
syntax: "public static TokenProvider createSharedAccessSignatureTokenProvider(String sasToken, Instant sasTokenValidUntil)"
desc: "Creates a Shared Access Signature token provider that always returns an already created token. This is a utility method."
returns:
description: "an instance of Shared Access Signature token provider that always returns an already created token."
type: "<xref href=\"com.microsoft.azure.servicebus.security.TokenProvider?alt=com.microsoft.azure.servicebus.security.TokenProvider&text=TokenProvider\" data-throw-if-not-resolved=\"False\" />"
- uid: "com.microsoft.azure.servicebus.security.TokenProvider.getSecurityTokenAsync(java.lang.String)"
fullName: "com.microsoft.azure.servicebus.security.TokenProvider.getSecurityTokenAsync(String audience)"
name: "getSecurityTokenAsync(String audience)"
nameWithType: "TokenProvider.getSecurityTokenAsync(String audience)"
summary: "Asynchronously gets a security token for the given audience."
modifiers:
- "abstract"
parameters:
- description: "path of the entity for which this security token is to be presented"
name: "audience"
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/lang/String.html\">String</a>"
syntax: "public abstract CompletableFuture<SecurityToken> getSecurityTokenAsync(String audience)"
desc: "Asynchronously gets a security token for the given audience. Implementations of this method may choose to create a new token for every call or return a cached token. But the token returned must be valid."
returns:
description: "an instance of CompletableFuture which returns a <xref uid=\"com.microsoft.azure.servicebus.security.SecurityToken\" data-throw-if-not-resolved=\"false\" data-raw-source=\"SecurityToken\"></xref> on completion."
type: "<a href=\"https://docs.oracle.com/javase/8/docs/api/java/util/concurrent/CompletableFuture.html\">CompletableFuture</a>&lt;<xref href=\"com.microsoft.azure.servicebus.security.SecurityToken?alt=com.microsoft.azure.servicebus.security.SecurityToken&text=SecurityToken\" data-throw-if-not-resolved=\"False\" />&gt;"
type: "class"
desc: "This abstract class defines the contract of a token provider. All token providers should inherit from this class. An instance of token provider is used to obtain a security token for a given audience."
metadata: {}
package: "com.microsoft.azure.servicebus.security"
artifact: com.microsoft.azure:azure-servicebus:3.6.7