## com.bbn.openmap.dataAccess.iso8211
Class DDFSubfield

    java.lang.Object
      com.bbn.openmap.dataAccess.iso8211.DDFSubfield

public class DDFSubfield
extends java.lang.Object

Class containing subfield information for a DDFField object.

Field Summary
`protected int` `byteSize` The number of bytes the field took up in the data file.
`protected DDFSubfieldDefinition` `defn` A DDFSubfieldDefinition defining the admin part of the file that contains the subfield data.
`protected java.lang.Object` `value` The object containing the value of the field.

Constructor Summary
`protected` `DDFSubfield()`
`` `DDFSubfield(DDFSubfieldDefinition poSFDefn, byte[] pachFieldData, int nBytesRemaining)` Create a subfield with a definition and the bytes containing the information for the value.
`` `DDFSubfield(DDFSubfieldDefinition ddfsd, java.lang.Object value)` Create a subfield with a definition and a value.

Method Summary
`float` `floatValue()` Get the value of the subfield as a float.
`int` `getByteSize()`
`DDFSubfieldDefinition` `getDefn()`
`java.lang.Object` `getValue()` Get the value of the subfield.
`int` `intValue()` Get the value of the subfield as an int.
`void` `setDefn(DDFSubfieldDefinition ddsfd)`
`void` `setValue(java.lang.Object o)` Set the value of the subfield.
`java.lang.String` `stringValue()`
`java.lang.String` `toString()` Return a string 'key = value', describing the field and its value.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### defn

    protected DDFSubfieldDefinition defn

  A DDFSubfieldDefinition defining the admin part of the file that contains the subfield data.

### value

    protected java.lang.Object value

  The object containing the value of the field.

### byteSize

    protected int byteSize

  The number of bytes the field took up in the data file.

Constructor Detail

### DDFSubfield

    protected DDFSubfield()

### DDFSubfield

    public DDFSubfield(DDFSubfieldDefinition ddfsd,
                       java.lang.Object value)

  Create a subfield with a definition and a value.

### DDFSubfield

    public DDFSubfield(DDFSubfieldDefinition poSFDefn,
                       byte[] pachFieldData,
                       int nBytesRemaining)

  Create a subfield with a definition and the bytes containing the information for the value. The definition parameters will tell the DDFSubfield what kind of object to create for the data.

Method Detail

### getByteSize

    public int getByteSize()

### setDefn

    public void setDefn(DDFSubfieldDefinition ddsfd)

### getDefn

    public DDFSubfieldDefinition getDefn()

### setValue

    public void setValue(java.lang.Object o)

  Set the value of the subfield.

### getValue

    public java.lang.Object getValue()

  Get the value of the subfield.

### intValue

    public int intValue()

  Get the value of the subfield as an int. Returns 0 if the value is 0 or isn't a number.

### floatValue

    public float floatValue()

  Get the value of the subfield as a float. Returns 0f if the value is 0 or isn't a number.

### stringValue

    public java.lang.String stringValue()

### toString

    public java.lang.String toString()

  Return a string 'key = value', describing the field and its value.

Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details