Class CompileContext
java.lang.Object
org.jboss.byteman.rule.compiler.CompileContext
class which retains compiler state during recursive compilation of rule expressions to bytecode
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate intprivate intprivate org.objectweb.asm.MethodVisitorprivate intprivate intprivate int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLocalCount(int count) voidaddStackCount(int count) voidcompileBooleanConversion(Type fromType, Type toType) voidcompileBox(Type toType) box a value belonging to a primitive typevoidcompileCheckCast(Type toType) voidcompileNumericConversion(Type fromType, Type toType) voidcompileObjectConversion(Type fromType, Type toType) voidcompilePrimitiveConversion(Type fromType, Type toType) compile code to convert a numeric or character primitive to a numeric or character primitivevoidcompileStringConversion(Type fromType, Type toType) voidcompileTypeConversion(Type fromType, Type toType) voidcompileUnbox(Type fromType, Type toType) compile code to convert a value of a boxed type to a primitive type, possibly not the immediately related primitive typeintintintintintvoidvoidnotifySourceLine(int line)
-
Field Details
-
sourceLine
private int sourceLine -
stackCount
private int stackCount -
stackMax
private int stackMax -
localCount
private int localCount -
localMax
private int localMax -
mv
private org.objectweb.asm.MethodVisitor mv
-
-
Constructor Details
-
CompileContext
CompileContext(org.objectweb.asm.MethodVisitor mv)
-
-
Method Details
-
getSourceLine
public int getSourceLine() -
getStackCount
public int getStackCount() -
getLocalCount
public int getLocalCount() -
getStackMax
public int getStackMax() -
getLocalMax
public int getLocalMax() -
addStackCount
public void addStackCount(int count) -
addLocalCount
public void addLocalCount(int count) -
notifySourceLine
public void notifySourceLine(int line) -
notifySourceEnd
public void notifySourceEnd() -
compileTypeConversion
-
compileNumericConversion
-
compileUnbox
-
compileBox
box a value belonging to a primitive type- Parameters:
toType- the type required after boxing
-
compileStringConversion
-
compilePrimitiveConversion
-
compileBooleanConversion
-
compileObjectConversion
-
compileCheckCast
-