public class OwExprExternalScope extends Object implements OwExprScope
External scopes are property and function domains Java API interfaces.
External scopes can be used on their own as collections of properties and functions.
This version only supports adding properties!
By extending this class custom scopes can be made available during expressions evaluation.
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 |
|---|
OwExprExternalScope(String name_p)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
addScope(OwExprExternalScope externalScope_p)
Adds a sub scope to this scope.
Scopes are stored as properties of this scope. |
OwExprProperty |
at(int index_p)
Indexed scope access method
|
OwExprFunction |
function(String functionName_p,
OwExprExpressionType[] argunmentTypes_p)
Function access method.
|
String |
getName() |
boolean |
hasProperty(String propertyName_p)
Property access helper method.
|
int |
length()
Indexed scope access helper method
|
protected OwExprFunction |
prelevateFunction(String functionName_p,
OwExprExpressionType[] argumentTypes_p)
Function search hook for
function(String, OwExprExpressionType[]).Children of this class should override this method to perform custom |
protected OwExprProperty |
prelevateProperty(String propertyName_p)
Property search hook for
property(String). |
OwExprProperty |
property(String propertyName_p)
Property access method.
|
String |
toString() |
public OwExprExternalScope(String name_p)
name_p - the name of this scope. The scope will be referenced by this name in the evaluated expressions.public final void addScope(OwExprExternalScope externalScope_p)
externalScope_p - the sub scope to addpublic final OwExprFunction function(String functionName_p, OwExprExpressionType[] argunmentTypes_p) throws OwExprEvaluationException
OwExprScopefunction in interface OwExprScopefunctionName_p - the name of the requested functionargunmentTypes_p - the argument types of the requested functionOwExprEvaluationExceptionpublic final OwExprProperty property(String propertyName_p) throws OwExprEvaluationException
OwExprScopeproperty in interface OwExprScopepropertyName_p - OwExprEvaluationExceptionprotected OwExprFunction prelevateFunction(String functionName_p, OwExprExpressionType[] argumentTypes_p) throws OwExprEvaluationException
function(String, OwExprExpressionType[]).functionName_p - argumentTypes_p - nullOwExprEvaluationExceptionprotected OwExprProperty prelevateProperty(String propertyName_p) throws OwExprEvaluationException
property(String).propertyName_p - addScope(OwExprExternalScope) or null if no such property was addedOwExprEvaluationExceptionpublic final String getName()
public 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 int length()
throws OwExprEvaluationException
OwExprScopelength in interface OwExprScopeOwExprEvaluationExceptionpublic 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 failedCopyright © 2014 Alfresco Business Solutions. All Rights Reserved.