nwnintf.format.itp.element
Class ItpListElt

java.lang.Object
  |
  +--nwnintf.format.itp.ItpElement
        |
        +--nwnintf.format.itp.element.ItpListElt

public class ItpListElt
extends ItpElement


Field Summary
 
Fields inherited from class nwnintf.format.itp.ItpElement
DATA, NAMEIDX, SIZE, TYPE, TYPE_CAPREF, TYPE_DATREF, TYPE_FLOAT32, TYPE_FLOAT64, TYPE_INT16, TYPE_INT32, TYPE_INT64, TYPE_INT8, TYPE_LIST, TYPE_RESREF, TYPE_STRING, TYPE_STRREF, TYPE_UINT16, TYPE_UINT32, TYPE_UINT64, TYPE_UINT8
 
Constructor Summary
ItpListElt(ItpFile f)
           
 
Method Summary
 void addEntry(ItpEntry ent)
          Add a new element.
protected  int childData(ItpWriter w)
          Write the element type-specific data to ItpWriter and return the contents that should go in the data field in the element structure for output.
 ItpEntry entry(int entidx)
           
 int length()
           
 void read(byte[] bytes, int eltoffset, int varnameoffset, int vardataoffset, int listoffset)
           
 void removeChildren()
          Subclasses that contain other entries or elements should override this.
 void removeEntry(ItpEntry ent)
           
 int type()
           
 
Methods inherited from class nwnintf.format.itp.ItpElement
file, name, newElement, setName, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ItpListElt

public ItpListElt(ItpFile f)
Method Detail

read

public void read(byte[] bytes,
                 int eltoffset,
                 int varnameoffset,
                 int vardataoffset,
                 int listoffset)
Overrides:
read in class ItpElement

entry

public ItpEntry entry(int entidx)

length

public int length()

type

public int type()
Specified by:
type in class ItpElement

childData

protected int childData(ItpWriter w)
                 throws java.io.IOException
Description copied from class: ItpElement
Write the element type-specific data to ItpWriter and return the contents that should go in the data field in the element structure for output.

Specified by:
childData in class ItpElement
java.io.IOException

removeChildren

public void removeChildren()
Description copied from class: ItpElement
Subclasses that contain other entries or elements should override this.

Overrides:
removeChildren in class ItpElement

addEntry

public void addEntry(ItpEntry ent)
Add a new element. Remember to add it to the ItpFile as well.


removeEntry

public void removeEntry(ItpEntry ent)