public class TypeAsExpression extends Expression implements ITypeAsExpression
typeas-expression <conditional-or-expression> typeas <type-literal>
IGosuParser| Modifier and Type | Field and Description |
|---|---|
protected Expression |
_lhs |
_type_tokens, UNDEF_FILE, UNDEF_FUNCTION, UNDEF_MODULEEMPTY_ARRAY| Constructor and Description |
|---|
TypeAsExpression()
Base constructor sets type to BooleanType.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
evaluate()
Perform a type cast.
|
ICoercer |
getCoercer() |
Expression |
getLHS() |
boolean |
isCompileTimeConstant() |
void |
setCoercer(ICoercer coercer) |
void |
setLHS(Expression e) |
String |
toString()
Subclasses should return a String representing the parsed expression.
|
evaluate, getContextType, getReturnType, getType, getTypeImpl, isNullSafe, isUnchecked, setTypeaddExceptionsFrom, addParseException, addParseException, addParseException, addParseExceptions, addParseIssues, addParseWarning, addParseWarning, addParseWarnings, addToken, adjustColumn, adjustLineNum, assignTokens, clearParseExceptions, clearParseTreeInformation, clearParseWarnings, compactParseTree, findAncestorParsedElementByType, findDeclaringStatement, findLineNumberOfDeclaration, findRootParsedElement, getAnnotations, getColumn, getContainedParsedElementsByType, getContainedParsedElementsByTypes, getContainedParsedElementsByTypesWithIgnoreSet, getEnclosingFeatureInfo, getFunctionName, getGosuClass, getGosuProgram, getImmediateParseIssue, getImmediateParseIssues, getLineNum, getLocation, getModule, getParent, getParseExceptions, getParseIssues, getParseWarnings, getQualifyingEnclosingTypeInfo, getTokens, hasImmediateParseIssue, hasImmediateParseWarning, hasImmediateParseWarnings, hasParseException, hasParseExceptions, hasParseIssue, hasParseIssues, hasParseWarning, hasParseWarnings, initEmptyParseTree, initLocation, isSuppressed, isSuppressed, isSynthetic, makeDoubleValue, makeFloatValue, makeInteger, makeLong, removeParseException, removeParseWarning, removeParseWarningRecursively, setGosuProgram, setLineNum, setLocation, setParent, setSynthetic, shouldClearParseInfoclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitevaluate, getContextType, isNullSafe, isUncheckedaddExceptionsFrom, addParseException, addParseException, addParseWarning, addParseWarning, clearParseExceptions, clearParseTreeInformation, clearParseWarnings, findAncestorParsedElementByType, findDeclaringStatement, findRootParsedElement, getColumn, getContainedParsedElementsByType, getContainedParsedElementsByTypes, getContainedParsedElementsByTypesWithIgnoreSet, getFunctionName, getGosuClass, getGosuProgram, getImmediateParseIssue, getImmediateParseIssues, getLineNum, getLocation, getModule, getParent, getParseExceptions, getParseIssues, getParseWarnings, getReturnType, getTokens, hasImmediateParseIssue, hasImmediateParseWarnings, hasParseException, hasParseExceptions, hasParseIssue, hasParseIssues, hasParseWarning, hasParseWarnings, isSuppressed, isSynthetic, setLocation, setParentprotected Expression _lhs
public TypeAsExpression()
public Expression getLHS()
getLHS in interface ITypeAsExpressionpublic void setLHS(Expression e)
e - The expression for the left-hand-side operand.public boolean isCompileTimeConstant()
isCompileTimeConstant in interface IParsedElementisCompileTimeConstant in class ParsedElementpublic Object evaluate()
evaluate in interface IExpressionevaluate in class Expressionpublic void setCoercer(ICoercer coercer)
public ICoercer getCoercer()
getCoercer in interface ITypeAsExpressionpublic String toString()
ExpressiontoString in class ExpressionCopyright © 2016. All rights reserved.