Package org.postgresql.gss

# Class GSSOutputStream

java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
org.postgresql.util.internal.PgBufferedOutputStream
org.postgresql.gss.GSSOutputStream

All Implemented Interfaces:
  `Closeable`, `Flushable`, `AutoCloseable`

public class GSSOutputStream extends PgBufferedOutputStream
Output stream that wraps each packed with GSS encryption.

- ## Field Summary

  ### Fields inherited from class org.postgresql.util.internal.PgBufferedOutputStream

  `buf, count`

  ### Fields inherited from class java.io.FilterOutputStream

  `out`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `GSSOutputStream(PgBufferedOutputStream out, GSSContext gssContext, MessageProp messageProp, int maxTokenSize)`
  Creates GSS output stream.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `protected void`
  `flushBuffer()`
  `void`
  `write(byte[] b, int off, int len)`

  ### Methods inherited from class org.postgresql.util.internal.PgBufferedOutputStream

  `flush, write, write, writeInt2, writeInt4, writeZeros`

  ### Methods inherited from class java.io.FilterOutputStream

  `close, write`

  ### Methods inherited from class java.io.OutputStream

  `nullOutputStream`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### GSSOutputStream

    public GSSOutputStream(PgBufferedOutputStream out, GSSContext gssContext, MessageProp messageProp, int maxTokenSize) throws GSSException
    Creates GSS output stream.
    Parameters:
      `out` - output stream for the encrypted data
      `gssContext` - gss context
      `messageProp` - message properties
      `maxTokenSize` - maximum length of the encrypted messages
    Throws:
      `GSSException`

- ## Method Details

  - ### flushBuffer

    protected void flushBuffer() throws IOException
    Overrides:
      `flushBuffer` in class `PgBufferedOutputStream`
    Throws:
      `IOException`

  - ### write

    public void write(byte[] b, int off, int len) throws IOException
    Overrides:
      `write` in class `PgBufferedOutputStream`
    Throws:
      `IOException`