Class Domain

java.lang.Object
com.esri.arcgisruntime.data.Domain
All Implemented Interfaces:
JsonSerializable
Direct Known Subclasses:
CodedValueDomain, InheritedDomain, RangeDomain

public abstract class Domain extends Object implements JsonSerializable
Represents a domain used to define and restrict the valid values for a Field.
Since:
100.0.0
  • Method Details

    • getFieldType

      public Field.Type getFieldType()
      Gets the field type of the domain.
      Returns:
      the field type of the domain
      Since:
      100.14.0
    • getName

      public String getName()
      Gets the domain name.
      Returns:
      the domain name
      Since:
      100.0.0
    • toJson

      public String toJson()
      Description copied from interface: JsonSerializable
      Serializes this object to a JSON string. Note that unknown JSON is omitted from the serialized string.
      Specified by:
      toJson in interface JsonSerializable
      Returns:
      a JSON string
    • getUnknownJson

      public Map<String,Object> getUnknownJson()
      Description copied from interface: JsonSerializable
      Gets unknown data from the source JSON.

      Unknown JSON is a Map of values not defined in the ArcGIS specification used to create this object but found in the source JSON. If the object is written back to JSON, any unknown JSON data is not persisted. The ArcGIS specification may be for a web map, web scene, REST API, and so on.

      Specified by:
      getUnknownJson in interface JsonSerializable
      Returns:
      an unmodifiable Map containing unknown data from the source JSON
    • getUnsupportedJson

      public Map<String,Object> getUnsupportedJson()
      Description copied from interface: JsonSerializable
      Gets unsupported data from the source JSON.

      Unsupported JSON is a Map of values defined in the ArcGIS specification used to create this object but not currently used in this API. If the object is written back to JSON, any unsupported JSON data is persisted. The ArcGIS specification may be from a web map, web scene, REST API, and so on.

      Specified by:
      getUnsupportedJson in interface JsonSerializable
      Returns:
      an unmodifiable Map containing unsupported data from the source JSON
    • fromJson

      public static Domain fromJson(String json)
      Creates a Domain instance from a JSON string.
      Parameters:
      json - the JSON representation of a Domain
      Returns:
      a Domain instance deserialized from the JSON string
      Throws:
      IllegalArgumentException - if json is null or empty
      Since:
      100.9.0