jcaas
Class AnnotationScript

java.lang.Object
  extended by jcaas.AnnotationScript

public class AnnotationScript
extends java.lang.Object

This clase takes a reference to a script file and then interprets that script file. Any instance of this class will have the behavior as defined in the script file it is given.


Method Summary
static AnnotationScript compile(java.io.File script)
          Compiles the script.
static AnnotationScript compile(java.io.InputStream input)
          Compiles the script.
 AnnotationContext getContext()
          Gives the current context of the script.
 org.apache.bcel.generic.MethodGen run(org.apache.bcel.generic.MethodGen gmethod)
          This method runs the script against a given InstructionList.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

compile

public static AnnotationScript compile(java.io.File script)
                                throws java.lang.Exception
Compiles the script.

Parameters:
script -
Returns:
Throws:
java.lang.Exception

compile

public static AnnotationScript compile(java.io.InputStream input)
                                throws java.lang.Exception
Compiles the script.

Parameters:
input -
Returns:
Throws:
java.lang.Exception

run

public org.apache.bcel.generic.MethodGen run(org.apache.bcel.generic.MethodGen gmethod)
                                      throws java.lang.Exception
This method runs the script against a given InstructionList.

Parameters:
list - - a list to run the script on.
Throws:
java.lang.Exception - - thrown if the script file is not found or if there is a parsing error.

getContext

public AnnotationContext getContext()
Gives the current context of the script.

Returns:
the current context.