예제 #1
0
 /** Flushes this output stream and forces any buffered output bytes to be written out. */
 public void flush() {
   super.flush();
   if (data != 0) {
     writeEncodedData();
     try {
       encodedOut.flush();
     } catch (IOException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     }
   }
 }
예제 #2
0
 /** Closes this output stream and releases any system resources associated with this stream. */
 public void close() {
   super.close();
   flush();
 }
예제 #3
0
 /** Constructor */
 private BitEncoderImpl(OutputStream out, int maxBitsWidth) {
   super.setOutputStream(out);
   this.maxBitsWidth = maxBitsWidth;
 }