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

public final class Hub extends Object implements com.azure.json.JsonSerializable<Hub>
Hub Item.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Hub()
    Creates an instance of Hub class.
  • Method Summary

    Modifier and Type
    Method
    Description
    static Hub
    fromJson(com.azure.json.JsonReader jsonReader)
    Reads an instance of Hub from the JsonReader.
    Get the resourceId property: Resource Id.
    Get the resourceType property: Resource Type.
    com.azure.json.JsonWriter
    toJson(com.azure.json.JsonWriter jsonWriter)
    void
    Validates the instance.
    withResourceId(String resourceId)
    Set the resourceId property: Resource Id.
    withResourceType(String resourceType)
    Set the resourceType property: Resource Type.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.azure.json.JsonSerializable

    toJson, toJson, toJsonBytes, toJsonString
  • Constructor Details

    • Hub

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

    • resourceId

      public String resourceId()
      Get the resourceId property: Resource Id.
      Returns:
      the resourceId value.
    • withResourceId

      public Hub withResourceId(String resourceId)
      Set the resourceId property: Resource Id.
      Parameters:
      resourceId - the resourceId value to set.
      Returns:
      the Hub object itself.
    • resourceType

      public String resourceType()
      Get the resourceType property: Resource Type.
      Returns:
      the resourceType value.
    • withResourceType

      public Hub withResourceType(String resourceType)
      Set the resourceType property: Resource Type.
      Parameters:
      resourceType - the resourceType value to set.
      Returns:
      the Hub 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<Hub>
      Throws:
      IOException
    • fromJson

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