Class ExpressionFactory.VariableImpl
- java.lang.Object
-
- org.glassfish.pfl.dynamic.codegen.impl.AttributedObjectBase
-
- org.glassfish.pfl.dynamic.codegen.impl.NodeBase
-
- org.glassfish.pfl.dynamic.codegen.impl.ExpressionFactory.ExpressionBase
-
- org.glassfish.pfl.dynamic.codegen.impl.ExpressionFactory.VariableImpl
-
- All Implemented Interfaces:
AttributedObject,ExpressionInternal,Node,Statement,VariableInternal,Expression,Variable,CopyInterceptor
- Enclosing class:
- ExpressionFactory
public static final class ExpressionFactory.VariableImpl extends ExpressionFactory.ExpressionBase implements VariableInternal
-
-
Constructor Summary
Constructors Constructor Description VariableImpl(ExpressionFactory ef, Type type, java.lang.String ident)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(Visitor visitor)Accept the visitor and allow it to perform actions on this Node.voidclose()Mark the variable so that it is no longer in scope.booleanequals(java.lang.Object obj)inthashCode()java.lang.Stringident()Return the name of this variable.booleanisAssignable()booleanisAvailable()Returns true if this variable is still in scope.java.lang.StringtoString()Typetype()Return the type of this variable.-
Methods inherited from class org.glassfish.pfl.dynamic.codegen.impl.ExpressionFactory.ExpressionBase
copy, copy
-
Methods inherited from class org.glassfish.pfl.dynamic.codegen.impl.NodeBase
getAncestor, id, parent, parent, postCopy, preCopy
-
Methods inherited from class org.glassfish.pfl.dynamic.codegen.impl.AttributedObjectBase
attributes, get, set
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.glassfish.pfl.dynamic.codegen.impl.AttributedObject
attributes, get, set
-
-
-
-
Field Detail
-
type
private Type type
-
ident
private java.lang.String ident
-
available
private boolean available
-
-
Constructor Detail
-
VariableImpl
VariableImpl(ExpressionFactory ef, Type type, java.lang.String ident)
-
-
Method Detail
-
isAssignable
public boolean isAssignable()
- Specified by:
isAssignablein interfaceExpressionInternal- Overrides:
isAssignablein classExpressionFactory.ExpressionBase
-
ident
public java.lang.String ident()
Description copied from interface:VariableReturn the name of this variable.
-
isAvailable
public boolean isAvailable()
Description copied from interface:VariableInternalReturns true if this variable is still in scope. Only variables still in scope may be referenced in expressions.- Specified by:
isAvailablein interfaceVariableInternal
-
close
public void close()
Description copied from interface:VariableInternalMark the variable so that it is no longer in scope.- Specified by:
closein interfaceVariableInternal
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
type
public Type type()
Description copied from interface:VariableReturn the type of this variable.- Specified by:
typein interfaceExpressionInternal- Specified by:
typein interfaceVariable- Returns:
- The variable type.
-
-