KeyForDiskEncryptionSet Class

  • java.lang.Object
    • com.azure.resourcemanager.compute.models.KeyForDiskEncryptionSet

Implements

public final class KeyForDiskEncryptionSet
implements JsonSerializable<KeyForDiskEncryptionSet>

Key Vault Key Url to be used for server side encryption of Managed Disks and Snapshots.

Constructor Summary

Constructor Description
KeyForDiskEncryptionSet()

Creates an instance of KeyForDiskEncryptionSet class.

Method Summary

Modifier and Type Method and Description
static KeyForDiskEncryptionSet fromJson(JsonReader jsonReader)

Reads an instance of KeyForDiskEncryptionSet from the JsonReader.

String keyUrl()

Get the keyUrl property: Fully versioned Key Url pointing to a key in KeyVault.

SourceVault sourceVault()

Get the sourceVault property: Resource id of the KeyVault containing the key or secret.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

KeyForDiskEncryptionSet withKeyUrl(String keyUrl)

Set the keyUrl property: Fully versioned Key Url pointing to a key in KeyVault.

KeyForDiskEncryptionSet withSourceVault(SourceVault sourceVault)

Set the sourceVault property: Resource id of the KeyVault containing the key or secret.

Methods inherited from java.lang.Object

Constructor Details

KeyForDiskEncryptionSet

public KeyForDiskEncryptionSet()

Creates an instance of KeyForDiskEncryptionSet class.

Method Details

fromJson

public static KeyForDiskEncryptionSet fromJson(JsonReader jsonReader)

Reads an instance of KeyForDiskEncryptionSet from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of KeyForDiskEncryptionSet if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

keyUrl

public String keyUrl()

Get the keyUrl property: Fully versioned Key Url pointing to a key in KeyVault. Version segment of the Url is required regardless of rotationToLatestKeyVersionEnabled value.

Returns:

the keyUrl value.

sourceVault

public SourceVault sourceVault()

Get the sourceVault property: Resource id of the KeyVault containing the key or secret. This property is optional and cannot be used if the KeyVault subscription is not the same as the Disk Encryption Set subscription.

Returns:

the sourceVault value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withKeyUrl

public KeyForDiskEncryptionSet withKeyUrl(String keyUrl)

Set the keyUrl property: Fully versioned Key Url pointing to a key in KeyVault. Version segment of the Url is required regardless of rotationToLatestKeyVersionEnabled value.

Parameters:

keyUrl - the keyUrl value to set.

Returns:

the KeyForDiskEncryptionSet object itself.

withSourceVault

public KeyForDiskEncryptionSet withSourceVault(SourceVault sourceVault)

Set the sourceVault property: Resource id of the KeyVault containing the key or secret. This property is optional and cannot be used if the KeyVault subscription is not the same as the Disk Encryption Set subscription.

Parameters:

sourceVault - the sourceVault value to set.

Returns:

the KeyForDiskEncryptionSet object itself.

Applies to