Class JsonDescriptor

java.lang.Object
org.symbol.sdk.JsonDescriptor

public final class JsonDescriptor extends Object
JsonDescriptor

Parses a JSON document into the descriptor Map the facade createTransactionFromDescriptor methods consume; integral numbers deserialize as Integer/Long/BigInteger by magnitude — the descriptor coercions accept all three. Note that descriptor byte fields read strings as UTF-8, not the hex of the model toJson() projection.

  • Method Details

    • parse

      public static Map<String,Object> parse(String json)
      JsonDescriptor.parse

      Parses a JSON object into a descriptor map.

      Parameters:

      json - JSON document whose top level is an object.

      Returns:

      Descriptor map with String keys and String/Number/List/Map values.

      Throws:

      InvalidDescriptorException - If the document is malformed or not a JSON object.