public abstract class TaggedOutputStream extends ByteCountOutputStream implements TaggedOutput
| Modifier and Type | Field and Description |
|---|---|
protected ActionSet |
actionSet
Set of actions that can be used by this Stream
|
protected TagSet |
tagSet
Set of tags that can be used by this Stream
|
little, writtenout| Constructor and Description |
|---|
TaggedOutputStream(OutputStream out,
TagSet tagSet,
ActionSet actionSet)
Create a Tagged Output stream.
|
TaggedOutputStream(OutputStream out,
TagSet tagSet,
ActionSet actionSet,
boolean littleEndian)
Create a Tagged Output stream.
|
| Modifier and Type | Method and Description |
|---|---|
protected TagHeader |
createTagHeader(Tag tag,
long len)
Returns newly created TagHeader.
|
protected int |
getTagAlignment()
Specifies tag alignment: 1 byte, 2 short, 4 int and 8 long.
|
void |
writeAction(Action action)
Write action.
|
protected abstract void |
writeActionHeader(ActionHeader header)
Writes the ActionHeader, which includes an actionCode and a length.
|
void |
writeTag(Tag tag)
Write a tag.
|
protected abstract void |
writeTagHeader(TagHeader header)
Writes the TagHeader, which includes a TagID and a length.
|
append, close, getBufferLength, getLength, popBuffer, popBufferBytes, pushBuffer, writeByteArray, writeSingleBytesize, writeAsciiZString, writeBoolean, writeByte, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeInt, writeLong, writeShort, writeShort, writeString, writeUnsignedByte, writeUnsignedByte, writeUnsignedInt, writeUnsignedInt, writeUnsignedShort, writeUnsignedShort, writeUTF, writeUTFbyteAlign, finish, flushByte, minBits, minBits, minBits, writeBitFlag, writeFBits, writeSBits, writeUBitsstartCompressing, write, writeflush, writeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclosewrite, write, writeprotected TagSet tagSet
protected ActionSet actionSet
public TaggedOutputStream(OutputStream out, TagSet tagSet, ActionSet actionSet)
out - stream to writetagSet - allowable tag setactionSet - allowable action setpublic TaggedOutputStream(OutputStream out, TagSet tagSet, ActionSet actionSet, boolean littleEndian)
out - stream to writetagSet - allowable tag setactionSet - allowable action setlittleEndian - true if stream is little endianprotected abstract void writeTagHeader(TagHeader header) throws IOException
header - TagHeader to writeIOException - if write failsprotected int getTagAlignment()
public void writeTag(Tag tag) throws IOException
TaggedOutputwriteTag in interface TaggedOutputtag - tag to writeIOException - if write failsprotected TagHeader createTagHeader(Tag tag, long len)
protected abstract void writeActionHeader(ActionHeader header) throws IOException
header - ActionHeader to writeIOException - if write failspublic void writeAction(Action action) throws IOException
action - action to writeIOException - if write failsCopyright © 2016. All rights reserved.