Class MhsmServiceTagRule

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

public final class MhsmServiceTagRule extends Object implements com.azure.json.JsonSerializable<MhsmServiceTagRule>
A rule governing the accessibility of a managed hsm pool from a specific service tags.
  • Constructor Details

    • MhsmServiceTagRule

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

    • tag

      public String tag()
      Get the tag property: Name of the service tag.
      Returns:
      the tag value.
    • withTag

      public MhsmServiceTagRule withTag(String tag)
      Set the tag property: Name of the service tag.
      Parameters:
      tag - the tag value to set.
      Returns:
      the MhsmServiceTagRule 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<MhsmServiceTagRule>
      Throws:
      IOException
    • fromJson

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