org.quattor.pan.dml.operators
Class SetValue
java.lang.Object
org.quattor.pan.dml.AbstractOperation
org.quattor.pan.dml.operators.SetValue
- All Implemented Interfaces:
- Operation
- Direct Known Subclasses:
- SetSelf
public class SetValue
- extends AbstractOperation
Implements a special operation to allow a result to be assigned to a
variable. This is generated by the compiler, but is not explicitly visible in
the pan language.
- Author:
- loomis
|
Field Summary |
protected java.lang.String |
identifier
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
identifier
protected java.lang.String identifier
SetValue
protected SetValue(SourceRange sourceRange,
java.lang.String identifier,
Operation... operations)
throws SyntaxException
- Throws:
SyntaxException
checkStaticIndexes
protected static void checkStaticIndexes(SourceRange sourceRange,
Operation... operations)
throws SyntaxException
- Throws:
SyntaxException
validName
protected void validName(java.lang.String name)
throws SyntaxException
- A utility method to determine if the variable name collides with one of
the reserved 'automatic' variables.
- Parameters:
name - variable name to check
- Throws:
SyntaxException
getInstance
public static SetValue getInstance(SourceRange sourceRange,
java.lang.String identifier,
Operation... operations)
throws SyntaxException
- Throws:
SyntaxException
getInstance
public static SetValue getInstance(Variable v)
throws SyntaxException
- Throws:
SyntaxException
execute
public Element execute(Context context)
- Description copied from interface:
Operation
- Execute this operation within the given context. If an error occurs, an
EvaluationException will be thrown with the details.
- Specified by:
execute in interface Operation- Specified by:
execute in class AbstractOperation
- Parameters:
context - evaluation context for the statement
- Returns:
- Element produced by running operation
execute
public Element execute(Context context,
Element result)
toString
public java.lang.String toString()
- Description copied from class:
AbstractOperation
- Default string representation of an operation is the class' simple name.
- Overrides:
toString in class AbstractOperation
- Returns:
- string of class' simple name
Copyright © 2011 Quattor. All Rights Reserved.