Enum Class SCAddressType

java.lang.Object
java.lang.Enum<SCAddressType>
org.stellar.sdk.xdr.SCAddressType
All Implemented Interfaces:
Serializable, Comparable<SCAddressType>, Constable, XdrElement

public enum SCAddressType extends Enum<SCAddressType> implements XdrElement
SCAddressType's original definition in the XDR file is:
 enum SCAddressType
 {
     SC_ADDRESS_TYPE_ACCOUNT = 0,
     SC_ADDRESS_TYPE_CONTRACT = 1,
     SC_ADDRESS_TYPE_MUXED_ACCOUNT = 2,
     SC_ADDRESS_TYPE_CLAIMABLE_BALANCE = 3,
     SC_ADDRESS_TYPE_LIQUIDITY_POOL = 4
 };
 
  • Enum Constant Details

    • SC_ADDRESS_TYPE_ACCOUNT

      public static final SCAddressType SC_ADDRESS_TYPE_ACCOUNT
    • SC_ADDRESS_TYPE_CONTRACT

      public static final SCAddressType SC_ADDRESS_TYPE_CONTRACT
    • SC_ADDRESS_TYPE_MUXED_ACCOUNT

      public static final SCAddressType SC_ADDRESS_TYPE_MUXED_ACCOUNT
    • SC_ADDRESS_TYPE_CLAIMABLE_BALANCE

      public static final SCAddressType SC_ADDRESS_TYPE_CLAIMABLE_BALANCE
    • SC_ADDRESS_TYPE_LIQUIDITY_POOL

      public static final SCAddressType SC_ADDRESS_TYPE_LIQUIDITY_POOL
  • Method Details

    • values

      public static SCAddressType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static SCAddressType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public int getValue()
    • decode

      public static SCAddressType decode(XdrDataInputStream stream, int maxDepth) throws IOException
      Throws:
      IOException
    • decode

      public static SCAddressType decode(XdrDataInputStream stream) throws IOException
      Throws:
      IOException
    • encode

      public void encode(XdrDataOutputStream stream) throws IOException
      Description copied from interface: XdrElement
      Encodes this value to XDR and writes it to the provided stream.
      Specified by:
      encode in interface XdrElement
      Parameters:
      stream - the destination XDR output stream
      Throws:
      IOException - if an I/O error occurs while writing the value
    • fromXdrBase64

      public static SCAddressType fromXdrBase64(String xdr) throws IOException
      Throws:
      IOException
    • fromXdrByteArray

      public static SCAddressType fromXdrByteArray(byte[] xdr) throws IOException
      Throws:
      IOException
    • toJson

      public String toJson()
      Description copied from interface: XdrElement
      Serializes this value to JSON.
      Specified by:
      toJson in interface XdrElement
      Returns:
      the JSON representation of this value
    • fromJson

      public static SCAddressType fromJson(String json)