## org.das2.qstream.FormatStreamHandler

Writes the stream based on the messages sent to it. This overlaps with the SimpleStreamFormatter, but was needed to support streams. The SimpleStreamFormatter took a QDataSet and formatted it. This formats based on the callbacks. Note the library was poorly designed, and this is pretty simple because most of the hard work is buried within the StreamDescriptor. StreamDescriptor should be simplified, and the code should be moved to here.

## FormatStreamHandler( )

## createStreamDescriptor

createStreamDescriptor( String name, boolean asciiTypes, boolean isBigEndian ) → org.das2.qstream.StreamDescriptor

create a stream descriptor packet. TODO: createPacketDescriptor. See SerialStreamFormatter for examples of how this would be done.

### Parameters

name - a String
asciiTypes - a boolean
isBigEndian - a boolean

### Returns:

an org.das2.qstream.StreamDescriptor
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## packet

packet( org.das2.qstream.PacketDescriptor pd, java.nio.ByteBuffer data ) → void

### Parameters

pd - a PacketDescriptor
data - a ByteBuffer

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## packetDescriptor

packetDescriptor( org.das2.qstream.PacketDescriptor pd ) → void

### Parameters

pd - a PacketDescriptor

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## setOutputStream

setOutputStream( java.io.OutputStream outs ) → void

### Parameters

outs - an OutputStream

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## setWritableByteChannel

setWritableByteChannel( java.nio.channels.WritableByteChannel outs ) → void

### Parameters

outs - a WritableByteChannel

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## streamClosed

streamClosed( org.das2.qstream.StreamDescriptor sd ) → void

### Parameters

sd - a StreamDescriptor

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## streamComment

streamComment( org.das2.qstream.StreamComment se ) → void

### Parameters

se - a StreamComment

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## streamDescriptor

streamDescriptor( org.das2.qstream.StreamDescriptor sd ) → void

### Parameters

sd - a StreamDescriptor

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## streamException

streamException( org.das2.qstream.StreamException se ) → void

### Parameters

se - a StreamException

### Returns:

void (returns nothing)
[search for examples] [view on GitHub] [view on old javadoc] [view source]