Package org.codehaus.commons.compiler
Class Cookable
java.lang.Object
org.codehaus.commons.compiler.Cookable
- All Implemented Interfaces:
ICookable
- Direct Known Subclasses:
SimpleCompiler
,SimpleCompiler
Base class for a simple
ICookable
.-
Field Summary
Fields inherited from interface org.codehaus.commons.compiler.ICookable
BOOT_CLASS_LOADER, SYSTEM_PROPERTY_SOURCE_DEBUGGING_DIR, SYSTEM_PROPERTY_SOURCE_DEBUGGING_ENABLE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal void
cook
(InputStream is) Reads, scans, parses and compiles Java tokens from the givenInputStream
, encoded in the "platform default encoding".final void
cook
(InputStream is, String optionalEncoding) Reads, scans, parses and compiles Java tokens from the givenInputStream
with the givenencoding
.final void
Reads, scans, parses and compiles Java tokens from the givenReader
.void
Reads, scans, parses and compiles Java tokens from the givenString
.final void
cook
(String optionalFileName, InputStream is) Reads, scans, parses and compiles Java tokens from the givenInputStream
, encoded in the "platform default encoding".final void
cook
(String optionalFileName, InputStream is, String optionalEncoding) Reads, scans, parses and compiles Java tokens from the givenInputStream
with the givenencoding
.abstract void
Reads, scans, parses and compiles Java tokens from the givenReader
.void
Reads, scans, parses and compiles Java tokens from the givenString
.final void
Reads, scans, parses and compiles Java tokens from the givenFile
, encoded in the "platform default encoding".final void
Reads, scans, parses and compiles Java tokens from the givenFile
with the givenencoding
.final void
Reads, scans, parses and compiles Java tokens from the named file, encoded in the "platform default encoding".final void
Reads, scans, parses and compiles Java tokens from the named file with the givenencoding
.static String
readString
(Reader r) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.codehaus.commons.compiler.ICookable
setDebuggingInformation, setParentClassLoader
-
Constructor Details
-
Cookable
public Cookable()
-
-
Method Details
-
cook
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenReader
.- Specified by:
cook
in interfaceICookable
- Parameters:
optionalFileName
- Used when reporting errors and warnings.- Throws:
CompileException
IOException
- See Also:
-
cook
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenReader
.- Specified by:
cook
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cook
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenInputStream
, encoded in the "platform default encoding".- Specified by:
cook
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cook
public final void cook(String optionalFileName, InputStream is) throws CompileException, IOException Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenInputStream
, encoded in the "platform default encoding".- Specified by:
cook
in interfaceICookable
- Parameters:
optionalFileName
- Used when reporting errors and warnings.- Throws:
CompileException
IOException
- See Also:
-
cook
public final void cook(InputStream is, String optionalEncoding) throws CompileException, IOException Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenInputStream
with the givenencoding
.- Specified by:
cook
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cook
public final void cook(String optionalFileName, InputStream is, String optionalEncoding) throws CompileException, IOException Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenInputStream
with the givenencoding
.- Specified by:
cook
in interfaceICookable
- Parameters:
optionalFileName
- Used when reporting errors and warnings.- Throws:
CompileException
IOException
- See Also:
-
cook
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenString
.- Specified by:
cook
in interfaceICookable
- Throws:
CompileException
- See Also:
-
cook
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenString
.- Specified by:
cook
in interfaceICookable
- Parameters:
optionalFileName
- Used when reporting errors and warnings.- Throws:
CompileException
- See Also:
-
cookFile
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenFile
, encoded in the "platform default encoding".- Specified by:
cookFile
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cookFile
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the givenFile
with the givenencoding
.- Specified by:
cookFile
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cookFile
Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the named file, encoded in the "platform default encoding".- Specified by:
cookFile
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
cookFile
public final void cookFile(String fileName, String optionalEncoding) throws CompileException, IOException Description copied from interface:ICookable
Reads, scans, parses and compiles Java tokens from the named file with the givenencoding
.- Specified by:
cookFile
in interfaceICookable
- Throws:
CompileException
IOException
- See Also:
-
readString
- Throws:
IOException
-