public class MutableIFFChunk extends DefaultMutableTreeNode
Syntax of an IFF Chunk:
Chunk ::= ID #{ UBYTE* } [0]
Property ::= Chunk
FORM ::= "FORM" #{ FormType (LocalChunk | FORM | LIST | CAT)* }
FormType ::= ID
LocalChunk ::= Property | Chunk
CAT ::= "CAT " #{ ContentsType {FROM | LIST | CAT)* }
ContentsType ::= ID -- a hint or an "abstract data type" ID
LIST ::= "LIST" #{ ContentsType PROP* {FORM | LIST | CAT)* }
PROP ::= "PROP" #{ FormType Property* }
In this extended regular expression notation the token "#" represents
a count of the following braced data types. Literal items are shown in
"quotes", [square bracketed items] are optional, and "*" means 0 or more
instances. A sometimes-needed pad is shown as "[0]".| Modifier and Type | Field and Description |
|---|---|
static int |
ID_CAT
ID for CATGroupExpression.
|
static int |
ID_FILLER
ID for unlabeled CATGroupExpressions.
|
static int |
ID_FORM
ID for FORMGroupExpression.
|
static int |
ID_LIST
ID for CATGroupExpression.
|
static int |
ID_PROP
ID for PROPGroupExpression.
|
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject| Constructor and Description |
|---|
MutableIFFChunk()
Creates a new instance.
|
MutableIFFChunk(int id,
byte[] data)
Creates a new instance.
|
MutableIFFChunk(int id,
int type)
Creates a new instance.
|
MutableIFFChunk(String id,
byte[] data)
Creates a new instance.
|
MutableIFFChunk(String id,
String type)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
Vector<MutableIFFChunk> |
childChunks() |
String |
dump() |
String |
dump(int depth) |
byte[] |
getData() |
int |
getId() |
int |
getLength() |
int |
getType() |
static String |
idToString(int anID)
Convert an integer IFF identifier to String.
|
void |
read(File f) |
void |
read(MC68000InputStream in) |
void |
setData(byte[] newValue) |
void |
setId(int newValue) |
void |
setType(int newValue) |
static int |
stringToId(String aString)
Converts the first four letters of the
String into an IFF Identifier.
|
String |
toString() |
void |
Write(File f) |
void |
write(MC68000OutputStream out) |
add, breadthFirstEnumeration, children, clone, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildAt, getChildBefore, getChildCount, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObjectpublic static final int ID_FORM
public static final int ID_CAT
public static final int ID_LIST
public static final int ID_PROP
public static final int ID_FILLER
public MutableIFFChunk()
public MutableIFFChunk(int id,
int type)
public MutableIFFChunk(int id,
byte[] data)
public MutableIFFChunk(String id, byte[] data)
public void setType(int newValue)
public void setId(int newValue)
public void setData(byte[] newValue)
public int getType()
public int getId()
public byte[] getData()
public int getLength()
public Vector<MutableIFFChunk> childChunks()
public String dump()
public String dump(int depth)
public String toString()
toString in class DefaultMutableTreeNodepublic static String idToString(int anID)
anID - to be converted.public static int stringToId(String aString)
aString - String to be converted.public void read(File f) throws IOException
IOExceptionpublic void read(MC68000InputStream in) throws IOException
IOExceptionpublic void Write(File f) throws IOException
IOExceptionpublic void write(MC68000OutputStream out) throws IOException
IOExceptionCopyright © 2014. All Rights Reserved.