org.codehaus.groovy.classgen
Class ClassGenerator

Abstract base class for generator of Java class versions of Groovy AST classes

author:
James Strachan
author:
Russel Winder
version:
$Revision: 7922 $

Field Summary
 int asmJDKVersion
           
 ClassLoader classLoader
           
 LinkedList innerClasses
           
 
Constructor Summary
ClassGenerator(ClassLoader classLoader)
           
 
Method Summary
ClassLoader getClassLoader()
          
LinkedList getInnerClasses()
          
SourceUnit getSourceUnit()
           A constant that is the ASM representation of the JDK version number for use in the ClassWriter.visitor method calls.
void visitBytecodeSequence(BytecodeSequence bytecodeSequence)
          
 

Constructor Detail

ClassGenerator

public ClassGenerator(ClassLoader classLoader)


Method Detail

getClassLoader

public ClassLoader getClassLoader()


getInnerClasses

public LinkedList getInnerClasses()


getSourceUnit

SourceUnit getSourceUnit()
A constant that is the ASM representation of the JDK version number for use in the ClassWriter.visitor method calls.

Prior to version 1.5 of ASM, the code generated was always JDK1.3 compliant. As of ASM version 1.5 there is an extra (first) parameter to specify the bytecode version to generate. In version 1.5 these are in Constants. The CVS (as at 2004.12.12) and presumably in version 2.0, the interface Constants is replaced by Opcodes.


visitBytecodeSequence

public void visitBytecodeSequence(BytecodeSequence bytecodeSequence)