SectionDescriptorpublic class SectionDescriptor extends Object
Fields Summary |
---|
private short | fn | private int | fc | private short | fnMpr | private int | fcMpr |
Constructors Summary |
---|
public SectionDescriptor()
| public SectionDescriptor(byte[] buf, int offset)
fn = LittleEndian.getShort(buf, offset);
offset += LittleEndian.SHORT_SIZE;
fc = LittleEndian.getInt(buf, offset);
offset += LittleEndian.INT_SIZE;
fnMpr = LittleEndian.getShort(buf, offset);
offset += LittleEndian.SHORT_SIZE;
fcMpr = LittleEndian.getInt(buf, offset);
|
Methods Summary |
---|
public boolean | equals(java.lang.Object o)
SectionDescriptor sed = (SectionDescriptor)o;
return sed.fn == fn && sed.fnMpr == fnMpr;
| public int | getFc()
return fc;
| public void | setFc(int fc)
this.fc = fc;
| public byte[] | toByteArray()
int offset = 0;
byte[] buf = new byte[12];
LittleEndian.putShort(buf, offset, fn);
offset += LittleEndian.SHORT_SIZE;
LittleEndian.putInt(buf, offset, fc);
offset += LittleEndian.INT_SIZE;
LittleEndian.putShort(buf, offset, fnMpr);
offset += LittleEndian.SHORT_SIZE;
LittleEndian.putInt(buf, offset, fcMpr);
return buf;
|
|