Class TableAzureNamedKeyCredentialPolicy

  • All Implemented Interfaces:
    com.azure.core.http.policy.HttpPipelinePolicy

    public final class TableAzureNamedKeyCredentialPolicy
    extends Object
    implements com.azure.core.http.policy.HttpPipelinePolicy
    Policy that adds the SharedKey into the request's Authorization header.
    • Constructor Summary

      Constructors 
      Constructor Description
      TableAzureNamedKeyCredentialPolicy​(com.azure.core.credential.AzureNamedKeyCredential credential)
      Creates a SharedKey pipeline policy that adds the SharedKey into the request's authorization header.
    • Constructor Detail

      • TableAzureNamedKeyCredentialPolicy

        public TableAzureNamedKeyCredentialPolicy​(com.azure.core.credential.AzureNamedKeyCredential credential)
        Creates a SharedKey pipeline policy that adds the SharedKey into the request's authorization header.
        Parameters:
        credential - The SharedKey credential used to create the policy.
    • Method Detail

      • process

        public Mono<com.azure.core.http.HttpResponse> process​(com.azure.core.http.HttpPipelineCallContext context,
                                                              com.azure.core.http.HttpPipelineNextPolicy next)
        Authorizes a HttpRequest with the SharedKey credential.
        Specified by:
        process in interface com.azure.core.http.policy.HttpPipelinePolicy
        Parameters:
        context - The context of the request.
        next - The next policy in the pipeline.
        Returns:
        A reactive result containing the HTTP response.
      • getCredential

        public com.azure.core.credential.AzureNamedKeyCredential getCredential()
        Get the AzureNamedKeyCredential linked to the policy.
        Returns:
        The AzureNamedKeyCredential.