ExObjListAtompublic class ExObjListAtom extends RecordAtom Tne atom that holds the seed info used by a ExObjList |
Fields Summary |
---|
private byte[] | _headerRecord header. | private byte[] | _dataRecord data. |
Constructors Summary |
---|
protected ExObjListAtom()Constructs a brand new link related atom record.
_header = new byte[8];
_data = new byte[4];
LittleEndian.putShort(_header, 2, (short)getRecordType());
LittleEndian.putInt(_header, 4, _data.length);
// It is fine for the other values to be zero
| protected ExObjListAtom(byte[] source, int start, int len)Constructs the link related atom record from its
source data.
// Get the header.
_header = new byte[8];
System.arraycopy(source,start,_header,0,8);
// Get the record data.
_data = new byte[len-8];
System.arraycopy(source,start+8,_data,0,len-8);
// Must be at least 4 bytes long
if(_data.length < 4) {
throw new IllegalArgumentException("The length of the data for a ExObjListAtom must be at least 4 bytes, but was only " + _data.length);
}
|
Methods Summary |
---|
public long | getObjectIDSeed()Gets the object ID seed, which will be used as the unique
OLE identifier for the next OLE object added
return LittleEndian.getUInt(_data,0);
| public long | getRecordType()Gets the record type. return RecordTypes.ExObjListAtom.typeID;
| public void | setObjectIDSeed(int seed)Sets the object ID seed
LittleEndian.putInt(_data,0,seed);
| public void | writeOut(java.io.OutputStream out)Write the contents of the record back, so it can be written
to disk
out.write(_header);
out.write(_data);
|
|