Class ManagedHsmKeyReleasePolicy

java.lang.Object
com.azure.resourcemanager.keyvault.models.ManagedHsmKeyReleasePolicy
All Implemented Interfaces:
com.azure.json.JsonSerializable<ManagedHsmKeyReleasePolicy>

public final class ManagedHsmKeyReleasePolicy extends Object implements com.azure.json.JsonSerializable<ManagedHsmKeyReleasePolicy>
The ManagedHsmKeyReleasePolicy model.
  • Constructor Details

    • ManagedHsmKeyReleasePolicy

      public ManagedHsmKeyReleasePolicy()
      Creates an instance of ManagedHsmKeyReleasePolicy class.
  • Method Details

    • contentType

      public String contentType()
      Get the contentType property: Content type and version of key release policy.
      Returns:
      the contentType value.
    • withContentType

      public ManagedHsmKeyReleasePolicy withContentType(String contentType)
      Set the contentType property: Content type and version of key release policy.
      Parameters:
      contentType - the contentType value to set.
      Returns:
      the ManagedHsmKeyReleasePolicy object itself.
    • data

      public byte[] data()
      Get the data property: Blob encoding the policy rules under which the key can be released.
      Returns:
      the data value.
    • withData

      public ManagedHsmKeyReleasePolicy withData(byte[] data)
      Set the data property: Blob encoding the policy rules under which the key can be released.
      Parameters:
      data - the data value to set.
      Returns:
      the ManagedHsmKeyReleasePolicy object itself.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<ManagedHsmKeyReleasePolicy>
      Throws:
      IOException
    • fromJson

      public static ManagedHsmKeyReleasePolicy fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of ManagedHsmKeyReleasePolicy from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of ManagedHsmKeyReleasePolicy if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
      Throws:
      IOException - If an error occurs while reading the ManagedHsmKeyReleasePolicy.