public class ISOField extends ISOComponent implements java.lang.Cloneable, java.io.Externalizable
ISOComponent
,
Serialized FormModifier and Type | Field and Description |
---|---|
protected int |
fieldNumber |
protected java.lang.String |
value |
Constructor and Description |
---|
ISOField()
No args constructor
(required by Externalizable support on ISOMsg)
|
ISOField(int n) |
ISOField(int n,
java.lang.String v) |
Modifier and Type | Method and Description |
---|---|
void |
dump(java.io.PrintStream p,
java.lang.String indent)
dump this field to PrintStream.
|
byte[] |
getBytes()
get Value as bytes (when possible)
|
int |
getFieldNumber() |
java.lang.Object |
getKey()
valid on Leafs only.
|
java.lang.Object |
getValue()
valid on Leafs only.
|
byte[] |
pack()
not available on Leaf - always throw ISOException
|
void |
readExternal(java.io.ObjectInput in) |
void |
setFieldNumber(int fieldNumber)
changes this Component field number
Use with care, this method does not change any reference held by a Composite. |
void |
setValue(java.lang.Object obj) |
int |
unpack(byte[] b)
not available on Leaf - always throw ISOException
|
void |
unpack(java.io.InputStream in)
not available on Leaf - always throw ISOException
|
void |
writeExternal(java.io.ObjectOutput out) |
getChildren, getComposite, getMaxField, pack, set, unset
public ISOField()
public ISOField(int n)
n
- - the FieldNumberpublic ISOField(int n, java.lang.String v)
n
- - fieldNumberv
- - fieldValuepublic byte[] pack() throws ISOException
pack
in class ISOComponent
ISOException
public int unpack(byte[] b) throws ISOException
unpack
in class ISOComponent
b
- ISOException
public void unpack(java.io.InputStream in) throws ISOException
unpack
in class ISOComponent
in
- ISOException
public java.lang.Object getKey()
ISOComponent
getKey
in class ISOComponent
public java.lang.Object getValue()
ISOComponent
getValue
in class ISOComponent
public void setValue(java.lang.Object obj) throws ISOException
setValue
in class ISOComponent
obj
- - Object representing this field valueISOException
public byte[] getBytes()
ISOComponent
getBytes
in class ISOComponent
public void dump(java.io.PrintStream p, java.lang.String indent)
dump
in class ISOComponent
p
- - print streamindent
- - optional indent stringpublic void setFieldNumber(int fieldNumber)
setFieldNumber
in class ISOComponent
fieldNumber
- new field numberpublic int getFieldNumber()
getFieldNumber
in class ISOComponent
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException