Since a copy is not made, users must be careful that no more writes are made to the stream if the array reference is handed off.
Users of this must make the modifications *before* the next write is done, and then release their hold on the array.
1916191719181919192019211922192319241925
private AccessibleByteArrayOutputStream tmpArray; private boolean dumpedTempWriter; private PrintWriter getTempWriter() { if (tmpWriter == null && !dumpedTempWriter) { tmpArray = new AccessibleByteArrayOutputStream(); tmpWriter = new PrintWriter(tmpArray); } return tmpWriter; }
1926192719281929193019311932193319341935
1931193219331934193519361937193819391940
1955195619571958195919601961196219631964
1902190319041905190619071908190919101911
1913191419151916191719181919192019211922
44454647484950
public ClassFormatOutput() { this(512); } public ClassFormatOutput(int size) { super(new AccessibleByteArrayOutputStream(size)); }