public class OwExprScopeValue extends OwExprValue
Scope values represent values obtained during evaluation that need to be queried for
properties or functions.
Example:
employee.birthDate.year
The employee.birthDate sub-expression will be evaluated to a OwExprScopeValue
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
| Constructor and Description |
|---|
OwExprScopeValue(OwExprScope scope_p)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
OwExprValue |
accept(OwExprBinaryOperator binaryOperator_p,
OwExprScopeValue v1_p)
Stage 2 binary operator visitor acceptance method
|
OwExprValue |
accept(OwExprBinaryOperator binaryOperator_p,
OwExprValue v2_p)
Stage 1 binary operator visitor acceptance method
|
OwExprProperty |
at(int index_p)
Indexed access delegate.
Delegates to m_scope. |
OwExprFunction |
function(String functionName_p,
OwExprExpressionType[] argunmentTypes_p)
Scope
OwExprScope.function(String, OwExprExpressionType[]) default implementation. |
OwExprScope |
getScope() |
protected Map |
getValuePropeties()
Overridable default value properties factory method
|
boolean |
hasProperty(String propertyName_p)
Scope
OwExprScope.hasProperty(String) default implementation. |
int |
length()
Indexed access delegate.
Delegates to m_scope. |
OwExprProperty |
property(String propertyName_p)
Scope
OwExprScope.property(String) default implementation. |
OwExprScope |
solveScope(String name_p) |
Object |
toJavaObject(Class javaSuperType_p)
Java class conversion method.
|
String |
toString() |
accept, accept, accept, accept, accept, accept, fromJavaValue, fromJavaValue, getJavaTypepublic OwExprScopeValue(OwExprScope scope_p)
scope_p - the scope represented by this valueprotected Map getValuePropeties()
OwExprValuegetValuePropeties in class OwExprValueMap of OwExprProperty for this valuepublic OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprValue v2_p) throws OwExprEvaluationException
OwExprValueaccept in class OwExprValuebinaryOperator_p - binary operator visitorv2_p - right side operator valueOwExprValueOwExprEvaluationException - if the operation fails for any reason (unsupported operand types ,
incompatible operands, unimplemented operation or operation failure at evaluation time)public OwExprValue accept(OwExprBinaryOperator binaryOperator_p, OwExprScopeValue v1_p) throws OwExprEvaluationException
OwExprValueaccept in class OwExprValuebinaryOperator_p - binary operator visitorv1_p - lef side operator valueOwExprValueOwExprEvaluationException - if the operation fails for any reason (unsupported operand types ,
incompatible operands, unimplemented operation or operation failure at evaluation time)public Object toJavaObject(Class javaSuperType_p) throws OwExprEvaluationException
OwExprValuetoJavaObject in class OwExprValuejavaSuperType_p - the requested java super type
The returned type should be a subclass of this type.
This is necessary for values having more than one possible java peers
such as OwExprNumericValue's Integer and Double support.OwExprEvaluationExceptionpublic final OwExprScope solveScope(String name_p) throws OwExprEvaluationException
OwExprEvaluationExceptionpublic final OwExprFunction function(String functionName_p, OwExprExpressionType[] argunmentTypes_p) throws OwExprEvaluationException
OwExprValueOwExprScope.function(String, OwExprExpressionType[]) default implementation.
By default value-scopes have no functions definedfunction in interface OwExprScopefunction in class OwExprValuefunctionName_p - the requested function nameargunmentTypes_p - array of OwExprExpressionType that defines the argument signature
of the requested functionOwExprProperty designated by propertyName_p and found in this value's scopeOwExprEvaluationException - if the requested property is not found in this scope or
the creation of the corresponding OwExprProperty has failedpublic final OwExprProperty property(String propertyName_p) throws OwExprEvaluationException
OwExprValueOwExprScope.property(String) default implementation.
A default value properties mechanism is implemented.
Concrete values must create properties via OwExprValue.getValuePropeties().property in interface OwExprScopeproperty in class OwExprValuepropertyName_p - the requested property nameOwExprProperty designated by propertyName_p and found in this value's scopeOwExprEvaluationException - if the requested property is not found in this scope or
the creation of the corresponding OwExprProperty has failedpublic OwExprProperty at(int index_p) throws OwExprEvaluationException
m_scope.at in interface OwExprScopeat in class OwExprValueindex_p - OwExprProperty property found at the requested indexOwExprEvaluationExceptionpublic int length()
throws OwExprEvaluationException
m_scope.length in interface OwExprScopelength in class OwExprValueOwExprEvaluationExceptionpublic final OwExprScope getScope()
public boolean hasProperty(String propertyName_p) throws OwExprEvaluationException
OwExprValueOwExprScope.hasProperty(String) default implementation.
A default value properties mechanism is implemented.
Concrete values must create properties via OwExprValue.getValuePropeties().hasProperty in interface OwExprScopehasProperty in class OwExprValuepropertyName_p - OwExprEvaluationExceptionCopyright © 2014 Alfresco Business Solutions. All Rights Reserved.