Package org.apache.catalina.tribes.io

# Class DirectByteArrayOutputStream

java.lang.Object
java.io.OutputStream
org.apache.catalina.tribes.io.DirectByteArrayOutputStream

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

public class DirectByteArrayOutputStream extends OutputStream
Byte array output stream that exposes the byte array directly

## Constructor Summary

Constructors
Constructor
Description
`DirectByteArrayOutputStream(int size)`

## Method Summary

Modifier and Type
Method
Description
`byte[]`
`getArray()`
`byte[]`
`getArrayDirect()`
`int`
`size()`
`void`
`write(int b)`

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

`close, flush, nullOutputStream, write, write`

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

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

## Constructor Details

### DirectByteArrayOutputStream

public DirectByteArrayOutputStream(int size)

## Method Details

### write

public void write(int b) throws IOException

Specified by:
  `write` in class `OutputStream`
Throws:
  `IOException`

### size

public int size()

### getArrayDirect

public byte[] getArrayDirect()

### getArray

public byte[] getArray()