Class KeyVaultBackupClientBuilder


  • public final class KeyVaultBackupClientBuilder
    extends Object
    This class provides a fluent builder API to help aid the configuration and instantiation of the KeyVaultBackupAsyncClient and KeyVaultBackupClient, by calling buildAsyncClient() and buildClient() respectively. It constructs an instance of the desired client.

    The minimal configuration options required by KeyVaultBackupClientBuilder to build an an KeyVaultBackupAsyncClient are vaultUrl and credential.

    Samples to construct a sync client

     KeyVaultBackupClient keyVaultBackupClient = new KeyVaultBackupClientBuilder()
         .vaultUrl("https://myaccount.managedhsm.azure.net/")
         .credential(new DefaultAzureCredentialBuilder().build())
         .buildClient();
     

    Samples to construct an async client

     KeyVaultBackupAsyncClient keyVaultBackupAsyncClient = new KeyVaultBackupClientBuilder()
         .vaultUrl("https://myaccount.managedhsm.azure.net/")
         .credential(new DefaultAzureCredentialBuilder().build())
         .buildAsyncClient();
     
    See Also:
    KeyVaultBackupClient, KeyVaultBackupAsyncClient