Class ConnectivityStatusContract

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

public final class ConnectivityStatusContract extends Object implements com.azure.json.JsonSerializable<ConnectivityStatusContract>
Details about connectivity to a resource.
  • Constructor Details

    • ConnectivityStatusContract

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

    • name

      public String name()
      Get the name property: The hostname of the resource which the service depends on. This can be the database, storage or any other azure resource on which the service depends upon.
      Returns:
      the name value.
    • withName

      public ConnectivityStatusContract withName(String name)
      Set the name property: The hostname of the resource which the service depends on. This can be the database, storage or any other azure resource on which the service depends upon.
      Parameters:
      name - the name value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • status

      public ConnectivityStatusType status()
      Get the status property: Resource Connectivity Status Type identifier.
      Returns:
      the status value.
    • withStatus

      Set the status property: Resource Connectivity Status Type identifier.
      Parameters:
      status - the status value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • error

      public String error()
      Get the error property: Error details of the connectivity to the resource.
      Returns:
      the error value.
    • withError

      public ConnectivityStatusContract withError(String error)
      Set the error property: Error details of the connectivity to the resource.
      Parameters:
      error - the error value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • lastUpdated

      public OffsetDateTime lastUpdated()
      Get the lastUpdated property: The date when the resource connectivity status was last updated. This status should be updated every 15 minutes. If this status has not been updated, then it means that the service has lost network connectivity to the resource, from inside the Virtual Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Returns:
      the lastUpdated value.
    • withLastUpdated

      public ConnectivityStatusContract withLastUpdated(OffsetDateTime lastUpdated)
      Set the lastUpdated property: The date when the resource connectivity status was last updated. This status should be updated every 15 minutes. If this status has not been updated, then it means that the service has lost network connectivity to the resource, from inside the Virtual Network.The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Parameters:
      lastUpdated - the lastUpdated value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • lastStatusChange

      public OffsetDateTime lastStatusChange()
      Get the lastStatusChange property: The date when the resource connectivity status last Changed from success to failure or vice-versa. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Returns:
      the lastStatusChange value.
    • withLastStatusChange

      public ConnectivityStatusContract withLastStatusChange(OffsetDateTime lastStatusChange)
      Set the lastStatusChange property: The date when the resource connectivity status last Changed from success to failure or vice-versa. The date conforms to the following format: `yyyy-MM-ddTHH:mm:ssZ` as specified by the ISO 8601 standard.
      Parameters:
      lastStatusChange - the lastStatusChange value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • resourceType

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

      public ConnectivityStatusContract withResourceType(String resourceType)
      Set the resourceType property: Resource Type.
      Parameters:
      resourceType - the resourceType value to set.
      Returns:
      the ConnectivityStatusContract object itself.
    • isOptional

      public boolean isOptional()
      Get the isOptional property: Whether this is optional.
      Returns:
      the isOptional value.
    • withIsOptional

      public ConnectivityStatusContract withIsOptional(boolean isOptional)
      Set the isOptional property: Whether this is optional.
      Parameters:
      isOptional - the isOptional value to set.
      Returns:
      the ConnectivityStatusContract 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<ConnectivityStatusContract>
      Throws:
      IOException
    • fromJson

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