Class IsoHexV3<M>

java.lang.Object
cl.netswitch.iso.iso8583.IsoField<M,byte[]>
cl.netswitch.iso.iso8583.IsoHexV3<M>
Type Parameters:
M - the type of the ISO message.

public class IsoHexV3<M> extends IsoField<M,byte[]>
Binary Variable-Length (LLL) of at most N (even) hexadecimal characters (2 ≤ N ≤ 998).
  • Constructor Details

    • IsoHexV3

      public IsoHexV3(int index, int maxlen, String name)
      Constructs a new IsoHexV3 instance.
      Parameters:
      index - the index of the field.
      maxlen - fixed length of this field value.
      name - the name of this field.
      Throws:
      NullPointerException - if name is null.
      IllegalArgumentException - if an argument is invalid.
  • Method Details

    • decodeValue

      public byte[] decodeValue(ByteBuffer buffer)
      Decodes the value of this field from the supplied byte buffer.
      Specified by:
      decodeValue in class IsoField<M,byte[]>
      Parameters:
      buffer - the buffer containing the encoded field value.
      Returns:
      the value decoded from supplied byte buffer.
      Throws:
      NullPointerException - if buffer is null.
      IsoException - if contents of buffer is invalid.
    • encodeValue

      public void encodeValue(byte[] value, cl.netswitch.lib.util.ByteArray barray)
      Encodes the value of this field into the supplied byte array.
      Specified by:
      encodeValue in class IsoField<M,byte[]>
      Parameters:
      value - the value to be encoded into byte array.
      barray - the byte array containing encoded field values.
      Throws:
      NullPointerException - if an argument is null.
      IsoException - if value is invalid.