public class EscherDump extends Object
Constructor and Description |
---|
EscherDump() |
Modifier and Type | Method and Description |
---|---|
private String |
dec1616(int n32)
Straight conversion from OO.
|
void |
dump(byte[] data,
int offset,
int size,
PrintStream out)
Decodes the escher stream from a byte array and dumps the results to
a print stream.
|
void |
dump(int recordSize,
byte[] data,
PrintStream out) |
void |
dumpOld(long maxLength,
InputStream in,
PrintStream out)
This version of dump is a translation from the open office escher dump routine.
|
private String |
getBlipType(byte b)
Returns the blip description given a blip id.
|
static void |
main(String[] args)
A simple test stub.
|
private void |
outHex(int bytes,
InputStream in,
PrintStream out)
Dumps out a hex value by reading from a input stream.
|
private String |
propName(short propertyId)
Returns a property name given a property id.
|
public void dump(byte[] data, int offset, int size, PrintStream out) throws IOException, LittleEndian.BufferUnderrunException
data
- The data array containing the escher records.offset
- The starting offset within the data array.size
- The number of bytes to read.out
- The output stream to write the results to.IOException
LittleEndian.BufferUnderrunException
public void dumpOld(long maxLength, InputStream in, PrintStream out) throws IOException, LittleEndian.BufferUnderrunException
maxLength
- The number of bytes to readin
- An input stream to read from.out
- An output stream to write to.IOException
LittleEndian.BufferUnderrunException
private String propName(short propertyId)
propertyId
- The property number for the nameprivate String getBlipType(byte b)
b
- blip idprivate String dec1616(int n32)
private void outHex(int bytes, InputStream in, PrintStream out) throws IOException, LittleEndian.BufferUnderrunException
bytes
- How many bytes this hex value consists of.in
- The stream to read the hex value from.out
- The stream to write the nicely formatted hex value to.IOException
LittleEndian.BufferUnderrunException
public static void main(String[] args) throws IOException
IOException
public void dump(int recordSize, byte[] data, PrintStream out) throws IOException, LittleEndian.BufferUnderrunException
Copyright © 2016 Open Microscopy Environment