Class ClassFormatOutput
java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
java.io.DataOutputStream
org.apache.derby.iapi.services.classfile.ClassFormatOutput
- All Implemented Interfaces:
Closeable
,DataOutput
,Flushable
,AutoCloseable
A wrapper around DataOutputStream to provide input functions in terms
of the types defined on pages 83 of the Java Virtual Machine spec.
For this types use these methods of DataOutputStream
- float - writeFloat
- long - writeLong
- double - writeDouble
- UTF/String - writeUTF
- U1Array - write(byte[])
-
Field Summary
Fields inherited from class java.io.DataOutputStream
written
Fields inherited from class java.io.FilterOutputStream
out
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]
getData()
Get a reference to the data array the class data is being built in.(package private) static void
Throw an ClassFormatError if a limit of the Java class file format is reached.void
putU1
(int i) void
putU2
(int i) void
void
putU4
(int i) void
writeTo
(OutputStream outTo) Methods inherited from class java.io.DataOutputStream
flush, size, write, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLong, writeShort, writeUTF
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
Methods inherited from interface java.io.DataOutput
write
-
Constructor Details
-
ClassFormatOutput
public ClassFormatOutput() -
ClassFormatOutput
public ClassFormatOutput(int size) -
ClassFormatOutput
-
-
Method Details
-
putU1
- Throws:
IOException
-
putU2
- Throws:
IOException
-
putU2
- Throws:
IOException
-
putU4
- Throws:
IOException
-
writeTo
- Throws:
IOException
-
getData
public byte[] getData()Get a reference to the data array the class data is being built in. No copy is made. -
limit
Throw an ClassFormatError if a limit of the Java class file format is reached.- Parameters:
name
- Terse limit description from JVM spec.limit
- What the limit is.value
- What the value for the current class is- Throws:
IOException
- Thrown when limit is exceeded.
-