public class OwExprStaticArray extends OwExprExpression implements OwExprPrimaryPrefix, OwExprScope
An expression representing a static array (inlined array value like {1,2,3} ).
Alfresco Workdesk
Copyright (c) Alfresco Software, Inc.
All rights reserved.
For licensing information read the license.txt file or
go to: http://wiki.alfresco.com
m_errorTable, m_symbolTable, m_typeError| Constructor and Description |
|---|
OwExprStaticArray(OwExprSymbolTable symbolTable_p,
OwExprErrorTable errorTable_p) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(OwExprExpression expression_p)
Parse time construction method.
|
OwExprProperty |
at(int index_p)
Indexed scope access method
|
OwExprValue |
evaluate(OwExprScope scope_p)
Evaluates this expression on the
OwExprScope (scope) provided as argument. |
OwExprExpression |
expression() |
OwExprFunction |
function(String functionName_p,
OwExprExpressionType[] argunmentTyes_p)
Function access method.
|
boolean |
hasProperty(String propertyName_p)
Property access helper method.
|
int |
length()
Indexed scope access helper method
|
OwExprProperty |
property(String propertyName_p)
Property access method.
|
OwExprFunctionSymbol |
regressToFunction()
Forces this primary prefix symbol to a function.
|
OwExprPropertySymbol |
regressToPorperty()
Forces this primary prefix symbol to a property.
|
OwExprSymbolScope |
regressToScope()
Forces this primary prefix to a scope symbol.
|
String |
toString() |
OwExprExpressionType |
type()
Type check method.
|
errCount, evaluate, evaluate, getErrorTable, getSymbol, getSymbolTable, hasErrors, initType, symbolsVisibleInScopespublic OwExprStaticArray(OwExprSymbolTable symbolTable_p, OwExprErrorTable errorTable_p)
public void add(OwExprExpression expression_p)
expression_p - array item expressionpublic OwExprValue evaluate(OwExprScope scope_p) throws OwExprEvaluationException
OwExprExpressionOwExprScope (scope) provided as argument.evaluate in class OwExprExpressionscope_p - external scope to be used during evaluationOwExprEvaluationException - in case of evaluation failurepublic OwExprExpressionType type() throws OwExprTypeMissmatchException
OwExprExpressionOwExprExpression.m_typeError should
be set to truetype in class OwExprExpressionOwExprTypeMissmatchException - if type errors are encountered during type computationpublic OwExprExpression expression()
expression in interface OwExprPrimaryPrefixpublic OwExprFunctionSymbol regressToFunction() throws OwExprTypeMissmatchException
OwExprPrimaryPrefixregressToFunction in interface OwExprPrimaryPrefixOwExprTypeMissmatchException - if a type mismatch is detected during function symbol creationpublic OwExprPropertySymbol regressToPorperty() throws OwExprTypeMissmatchException
OwExprPrimaryPrefixregressToPorperty in interface OwExprPrimaryPrefixOwExprTypeMissmatchException - if a type mismatch is detected during property symbol creationpublic OwExprSymbolScope regressToScope() throws OwExprTypeMissmatchException
OwExprPrimaryPrefixregressToScope in interface OwExprPrimaryPrefixOwExprTypeMissmatchException - if a type mismatch is detected during scope symbol creationpublic OwExprProperty at(int index_p) throws OwExprEvaluationException
OwExprScopeat in interface OwExprScopeindex_p - int index of the requested propertyOwExprProperty property found at the requested indexOwExprEvaluationException - if the requested indexed access has failed (index out of bounds,
the creation of OwExprProperty has failed)public OwExprFunction function(String functionName_p, OwExprExpressionType[] argunmentTyes_p) throws OwExprEvaluationException
OwExprScopefunction in interface OwExprScopefunctionName_p - the name of the requested functionargunmentTyes_p - array of OwExprExpressionType that defines the argument signature
of the requested functionOwExprFunction with the requested name and argument signature residing in this scopeOwExprEvaluationException - if the requested function is not found in this scope or
the creation of the corresponding OwExprFunction has failedpublic boolean hasProperty(String propertyName_p) throws OwExprEvaluationException
OwExprScopehasProperty in interface OwExprScopepropertyName_p - the name of the requested propertytrue if this scope can perform property access for the requested property
- an access via OwExprScope.property(String) will NOT fail on missing property grounds,
false otherwiseOwExprEvaluationException - if the property validity check has failedpublic int length()
throws OwExprEvaluationException
OwExprScopelength in interface OwExprScopeOwExprEvaluationExceptionpublic OwExprProperty property(String propertyName_p) throws OwExprEvaluationException
OwExprScopeproperty in interface OwExprScopepropertyName_p - the name of the requested propertyOwExprProperty with the requested name residing in this scopeOwExprEvaluationException - if the requested property is not found in this scope or
the creation of the corresponding OwExprProperty has failedCopyright © 2014 Alfresco Business Solutions. All Rights Reserved.