Package net.janino

The classes in this package pose the core of the Janino JavaTM compiler.

See:
          Description

Interface Summary
ClassFile.FixUp A throw-in interface that marks ClassFile.CodeAttribute.Offsets as "fix-ups": During the execution of ClassFile.CodeAttribute.fixUp(), all "fix-ups" are invoked and can do last touches to the code attribute.
Compiler.ClassFileHandler  
IClassLoader Loads an IClass by type name.
Java.BlockStatement Base of all statements that can appear in a block.
Java.Locatable This interface is implemented by objects which are associated with a location in the source code.
Java.Scope  
Opcode Definitions of Java bytecode opcodes.
 

Class Summary
ClassBodyEvaluator Parses a class body and returns it as a java.lang.Class object ready for use with java.lang.reflect.
ClassFile An object that represents the JavaTM "class file" format.
ClassLoaderIClassLoader An IClassLoader that loads IClasses through a reflection ClassLoader.
Compiler A simplified substitute for the javac tool.
Descriptor Helper class that defines useful methods for handling "field descriptors" (JVMS 4.3.2) and "method descriptors" (JVMS 4.3.3).
EvaluatorBase Utilities for the various "...Evaluator" classes.
EvaluatorBase.ByteArrayClassLoader This classes publishes the ClassLoader's "defineClass()" method.
ExpressionEvaluator An expression evaluator that evaluates expressions in JavaTM bytecode.
IClass A simplified equivalent to "java.lang.reflect".
Java This wrapper class defines classes that represent the elements of the JavaTM programming language.
Java.AmbiguousName This class is special: It does not extend/implement the Atom subclasses, but overrides Atom's "to...(
Java.ArrayAccessExpression This class implements an array access.
Java.ArrayInitializer Represents a JavaTM array initializer (JLS 10.6).
Java.ArrayType Representation of a JavaTM array type (JLS 10.1).
Java.Assignment  
Java.Atom Abstract base class for Java.Type, Java.Rvalue and Java.Lvalue.
Java.BasicType Representation of a JavaTM "basic type" (obviously equaivalent to a "primitive type") (JLS 4.2).
Java.BinaryOperation Representation of all non-operand-modifying JavaTM binary operations.
Java.Block Representation of a JavaTM "block" (JLS 14.2).
Java.BooleanRvalue Base class for Java.Rvalues that compile better as conditional branches.
Java.BreakableStatement Base class for statements that can be terminated abnormally with a "break" statement.
Java.BreakStatement Representation of the JavaTM "break" statement (JLS 14.14).
Java.Cast  
Java.CatchClause  
Java.ClassDeclaration  
Java.ClassLiteral  
Java.ClassOrInterfaceDeclaration  
Java.CompilationUnit Holds the result of Parser.parseCompilationUnit().
Java.ConditionalExpression  
Java.ConstructorDeclarator  
Java.ConstructorInvocation  
Java.ContinuableStatement  
Java.ContinueStatement Representation of the JavaTM "continue" statement (JLS 14.15).
Java.Crement Objects of this class represent represent one pre- or post-increment or decrement.
Java.DoStatement  
Java.ExpressionStatement  
Java.FieldAccessExpression This class implements class field access.
Java.FieldDeclarator This class is derived from "Statement", because it provides for the initialization of the field.
Java.FormalParameter  
Java.ForStatement  
Java.FunctionDeclarator Abstract base class for Java.ConstructorDeclarator and Java.MethodDeclarator.
Java.IfStatement  
Java.Instanceof  
Java.InterfaceDeclaration  
Java.Invocation  
Java.LabeledStatement  
Java.Literal  
Java.LocalVariableDeclarationStatement  
Java.Lvalue Representation of an "lvalue", i.e. an expression that has a type and a value, and can be assigned to: An expression that can be the left-hand-side of an assignment.
Java.MethodDeclarator  
Java.MethodInvocation  
Java.NewArray  
Java.NewClassInstance  
Java.ReferenceType  
Java.ReturnStatement  
Java.Rvalue Representation of an "rvalue", i.e. an expression that has a type and a value, but cannot be assigned to: An expression that can be the right-hand-side of an assignment.
Java.Statement  
Java.SuperclassMethodInvocation  
Java.SwitchBlockStatementGroup  
Java.SwitchStatement  
Java.SynchronizedStatement  
Java.ThisReference  
Java.ThrowStatement  
Java.TryStatement  
Java.Type Representation of a JavaTM type.
Java.UnaryOperation This class implements the unary operators "+", "-", "~" and "!".
Java.VariableDeclarator  
Java.WhileStatement  
Mod This class defines constants and convenience methods for the handling of modifiers as defined by the JVM.
Parser Implementation of a simplified compiler for the JavaTM programming language.
ReflectionIClass An implementation of IClass using "java.lang.reflect".
Scanner Splits up a character stream into tokens and returns them as String objects.
Scanner.Location  
ScriptEvaluator An expression evaluator that evaluates expressions in Java bytecode.
 

Exception Summary
Java.CompileException An exception that reflects an error during compilation.
Parser.ParseException An exception that reflects an error during parsing.
Scanner.ScanException An exception that reflects an error during parsing.
 

Package net.janino Description

The classes in this package pose the core of the Janino JavaTM compiler.

The package comprises a scanner (Scanner, a parser (Parser) and a class file library. The parser builds a syntax tree from the "Java.*" classes that represents the parsed code. The Java.BlockStatement.compile(net.janino.ClassFile.CodeAttribute) method compiles this syntax tree into a ClassFile object, which can write JavaTM bytecode to an "OutputStream".