Class AliasPattern

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

public final class AliasPattern extends Object implements com.azure.json.JsonSerializable<AliasPattern>
The type of the pattern for an alias path.
  • Constructor Details

    • AliasPattern

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

    • phrase

      public String phrase()
      Get the phrase property: The alias pattern phrase.
      Returns:
      the phrase value.
    • withPhrase

      public AliasPattern withPhrase(String phrase)
      Set the phrase property: The alias pattern phrase.
      Parameters:
      phrase - the phrase value to set.
      Returns:
      the AliasPattern object itself.
    • variable

      public String variable()
      Get the variable property: The alias pattern variable.
      Returns:
      the variable value.
    • withVariable

      public AliasPattern withVariable(String variable)
      Set the variable property: The alias pattern variable.
      Parameters:
      variable - the variable value to set.
      Returns:
      the AliasPattern object itself.
    • type

      public AliasPatternType type()
      Get the type property: The type of alias pattern.
      Returns:
      the type value.
    • withType

      public AliasPattern withType(AliasPatternType type)
      Set the type property: The type of alias pattern.
      Parameters:
      type - the type value to set.
      Returns:
      the AliasPattern 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<AliasPattern>
      Throws:
      IOException
    • fromJson

      public static AliasPattern fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of AliasPattern from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of AliasPattern 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 AliasPattern.