|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IEvaluationContext
An evaluation context is used to manage a set of objects needed during XML expression evaluation. A context has a parent context, can manage a set of named variables and has a default variable. The default variable is used during XML expression evaluation if no explicit variable is referenced.
This interface is not intended to be implemented by clients. Clients
are allowed to instantiate EvaluationContext
.
Field Summary | |
---|---|
static java.lang.Object |
UNDEFINED_VARIABLE
Represents the value used by variables that exist but are not defined in a evaluation context. |
Method Summary | |
---|---|
void |
addVariable(java.lang.String name,
java.lang.Object value)
Adds a new named variable to this context. |
boolean |
getAllowPluginActivation()
Returns whether this evaluation context supports plug-in activation. |
java.lang.Object |
getDefaultVariable()
Returns the default variable. |
IEvaluationContext |
getParent()
Returns the parent context or null if
this is the root of the evaluation context hierarchy. |
IEvaluationContext |
getRoot()
Returns the root evaluation context. |
java.lang.Object |
getVariable(java.lang.String name)
Returns the variable managed under the given name. |
java.lang.Object |
removeVariable(java.lang.String name)
Removes the variable managed under the given name from this evaluation context. |
java.lang.Object |
resolveVariable(java.lang.String name,
java.lang.Object[] args)
Resolves a variable for the given name and arguments. |
void |
setAllowPluginActivation(boolean value)
Specifies whether this evaluation context allows activation of plug-ins for testers used in the expression tree. |
Field Detail |
---|
static final java.lang.Object UNDEFINED_VARIABLE
false
will be returned.
Method Detail |
---|
IEvaluationContext getParent()
null
if
this is the root of the evaluation context hierarchy.
null
IEvaluationContext getRoot()
void setAllowPluginActivation(boolean value)
true
and the actual test expression must have the
attribute forcePluginActivation
set to
true
as well.
value
- whether this evaluation context allows plug-in activationboolean getAllowPluginActivation()
setAllowPluginActivation(boolean)
the parent value is returned. If no parent is set false
is returned.
java.lang.Object getDefaultVariable()
null
if
no default variable is managed.void addVariable(java.lang.String name, java.lang.Object value)
name
- the variable's namevalue
- the variable's valuejava.lang.Object removeVariable(java.lang.String name)
name
- the variable's name
null
if
the variable doesn't existjava.lang.Object getVariable(java.lang.String name)
name
- the variable's name
null
if the content
doesn't manage a variable with the given namejava.lang.Object resolveVariable(java.lang.String name, java.lang.Object[] args) throws CoreException
resolve
expression.
name
- the variable to resolveargs
- an object array of arguments used to resolve the
variable
null
if no variable
can be resolved for the given name and arguments
CoreException
- if an errors occurs while resolving
the variable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |