Package io.ebean.enhance.common
Class InputStreamTransform
java.lang.Object
io.ebean.enhance.common.InputStreamTransform
public class InputStreamTransform extends Object
Utility object that handles input streams for reading and writing.
-
Constructor Summary
Constructors Constructor Description InputStreamTransform(Transformer transformer, ClassLoader classLoader) -
Method Summary
Modifier and Type Method Description voidlog(int level, String msg)static byte[]readBytes(InputStream is)byte[]transform(String className, File file)Transform a file.byte[]transform(String className, InputStream is)Transform a input stream.static voidwriteBytes(byte[] bytes, File file)Helper method to write bytes to a file.static voidwriteBytes(byte[] bytes, OutputStream os)Helper method to write bytes to a OutputStream.
-
Constructor Details
-
InputStreamTransform
-
-
Method Details
-
log
-
transform
public byte[] transform(String className, File file) throws IOException, IllegalClassFormatExceptionTransform a file. -
transform
public byte[] transform(String className, InputStream is) throws IOException, IllegalClassFormatExceptionTransform a input stream. -
writeBytes
Helper method to write bytes to a file.- Throws:
IOException
-
writeBytes
Helper method to write bytes to a OutputStream.- Throws:
IOException
-
readBytes
- Throws:
IOException
-