<h2>org.das2.qstream.QdsToDas22</h2><p>Write QDataSets that vary over at most 2 independent variables as a Das2 
 stream.
 Since Das2 streams can have at most 2 independent variables, higher
 dimensional (not necessarily higher rank) QDataSets can't be written using
 this code.  Streams that can be written have the following plane structure
 
   X Y [Y Y Y Y ... ]
   X YScan [YScan YScan YScan ... ]
   X Y Z [Z Z Z Z ... ]
 
 All binary output is streamed in machine-native order.  Since datasets written
 on one architecture are most likely to be read on the same architecture this
 choice causes the least amount of byte swapping.  
 
 This is a direct serialization of QDataSet and does not require any legacy
 das2 dataset classes such as VectorDataset or TableDataset.</p>
<h2>QdsToDas22( )</h2>
<p></p>

<h2>QdsToDas22( int genSigDigits, int fracSecDigits )</h2>
<p></p>

<hr>
<a name="canWrite"></a>
<h2>canWrite</h2>
canWrite( <a href='http://www-pw.physics.uiowa.edu/~jbf/autoplot/doc/org/das2/qds/QDataSet.html'>QDataSet</a> qds ) &rarr; boolean

<p>Determine if a given dataset be serialized as a das2.2 stream</p>

<h3>Parameters</h3>
qds - The dataset to write

<h3>Returns:</h3>
true if this dataset can be serialized as a das2.2 stream, false
         otherwise
<br><br>
<a href="https://github.com/autoplot/dev/search?q=canWrite&unscoped_q=canWrite">[search for examples]</a>
 <a href="https://github.com/autoplot/documentation/tree/master/javadoc/org/das2/qstream/QdsToDas22.md">[view on GitHub]</a>
 <a href="http://www-pw.physics.uiowa.edu/~jbf/autoplot/javadoc2018/org/das2/qstream/QdsToDas22.html#canWrite">[view on old javadoc]</a>
 <a href="https://saturn.physics.uiowa.edu/svn/das2/dasCore/community/autoplot2011/trunk/dasCore/src/org/das2/qstream/QdsToDas22.java">[view source]</a>
<br>
<br>
<hr>
<a name="write"></a>
<h2>write</h2>
write( <a href='http://www-pw.physics.uiowa.edu/~jbf/autoplot/doc/org/das2/qds/QDataSet.html'>QDataSet</a> qds, <a href='https://docs.oracle.com/javase/8/docs/api/java/io/OutputStream.html'>java.io.OutputStream</a> os ) &rarr; boolean

<p>Write a QDataSet as a das2.2 stream
 
 To test whether it looks like this code could stream a dataset use the
 canWrite() function.  This function may be called multiple times to add
 additional data to the stream.  If a compatible header has already been
 emitted for a particular dataset it is not re-sent.</p>

<h3>Parameters</h3>
qds - The dataset to write, may have join's bundles etc. but no
        rank 3 or higher component datasets.
<br>
os - an open output stream, which is not closed by this code.

<h3>Returns:</h3>
true if the entire dataset could be written, false otherwise.
         IO failures do not return false, they throw.  False simply 
         means that this code does not know how (or can't) stream the 
         given dataset.  Since deeper inspection occurs when actually
         writing the data then when testing, false may be returned even
         if canWrite() returned true.
<br><br>
<a href="https://github.com/autoplot/dev/search?q=write&unscoped_q=write">[search for examples]</a>
 <a href="https://github.com/autoplot/documentation/tree/master/javadoc/org/das2/qstream/QdsToDas22.md">[view on GitHub]</a>
 <a href="http://www-pw.physics.uiowa.edu/~jbf/autoplot/javadoc2018/org/das2/qstream/QdsToDas22.html#write">[view on old javadoc]</a>
 <a href="https://saturn.physics.uiowa.edu/svn/das2/dasCore/community/autoplot2011/trunk/dasCore/src/org/das2/qstream/QdsToDas22.java">[view source]</a>
<br>
<br>