Package org.codehaus.groovy.classgen.asm
Class ExpressionAsVariableSlot
- java.lang.Object
- 
- org.codehaus.groovy.ast.ASTNode
- 
- org.codehaus.groovy.ast.AnnotatedNode
- 
- org.codehaus.groovy.ast.expr.Expression
- 
- org.codehaus.groovy.classgen.BytecodeExpression
- 
- org.codehaus.groovy.classgen.asm.ExpressionAsVariableSlot
 
 
 
 
 
- 
 public class ExpressionAsVariableSlot extends BytecodeExpression Helper class that takes an Expression and if visited will load it normally, storing the result in a helper variable, which then can be requested after the visit is completed. A copy of the variable will stay on the stack. Subsequent visits will load the stored value instead of visiting the expression again
- 
- 
Field Summary- 
Fields inherited from class org.codehaus.groovy.classgen.BytecodeExpressionNOP
 
- 
 - 
Constructor SummaryConstructors Constructor Description ExpressionAsVariableSlot(WriterController controller, Expression expression)ExpressionAsVariableSlot(WriterController controller, Expression expression, java.lang.String name)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetIndex()returns the index of the bytecode variablejava.lang.StringgetText()voidvisit(org.objectweb.asm.MethodVisitor mv)- 
Methods inherited from class org.codehaus.groovy.classgen.BytecodeExpressiontransformExpression, visit
 - 
Methods inherited from class org.codehaus.groovy.ast.expr.ExpressiongetType, setType, transformExpressions, transformExpressions
 - 
Methods inherited from class org.codehaus.groovy.ast.AnnotatedNodeaddAnnotation, addAnnotations, getAnnotations, getAnnotations, getDeclaringClass, hasNoRealSourcePosition, isSynthetic, setDeclaringClass, setHasNoRealSourcePosition, setSynthetic
 - 
Methods inherited from class org.codehaus.groovy.ast.ASTNodecopyNodeMetaData, getColumnNumber, getLastColumnNumber, getLastLineNumber, getLineNumber, getMetaDataMap, getNodeMetaData, getNodeMetaData, putNodeMetaData, removeNodeMetaData, setColumnNumber, setLastColumnNumber, setLastLineNumber, setLineNumber, setNodeMetaData, setSourcePosition
 
- 
 
- 
- 
- 
Constructor Detail- 
ExpressionAsVariableSlotpublic ExpressionAsVariableSlot(WriterController controller, Expression expression, java.lang.String name) 
 - 
ExpressionAsVariableSlotpublic ExpressionAsVariableSlot(WriterController controller, Expression expression) 
 
- 
 - 
Method Detail- 
visitpublic void visit(org.objectweb.asm.MethodVisitor mv) - Specified by:
- visitin class- BytecodeExpression
 
 - 
getIndexpublic int getIndex() returns the index of the bytecode variable
 - 
getTextpublic java.lang.String getText() - Overrides:
- getTextin class- BytecodeExpression
 
 
- 
 
-