| org.eclipse.ui.internal.services.IEvaluationResultCache
All known Subclasses: org.eclipse.ui.internal.services.EvaluationResultCache,
IEvaluationResultCache | public interface IEvaluationResultCache (Code) | |
A cache of the result of an expression. This also provides the source
priority for the expression.
This interface is not intended to be implemented or extended by clients.
since: 3.2 See Also: org.eclipse.ui.ISources See Also: org.eclipse.ui.ISourceProvider |
Method Summary | |
public void | clearResult() Clears the cached computation of the evaluate method, if
any. | public boolean | evaluate(IEvaluationContext context) Evaluates the expression -- given the current state of the workbench.
This method should cache its computation. | public Expression | getExpression() Returns the expression controlling the activation or visibility of this
item. | public int | getSourcePriority() Returns the priority that has been given to this expression. | public void | setResult(boolean result) Forces the cached result to be a particular value. |
clearResult | public void clearResult()(Code) | | Clears the cached computation of the evaluate method, if
any. This method is only intended for internal use. It provides a
mechanism by which ISourceProvider events can invalidate
state on a IEvaluationResultCache instance.
|
evaluate | public boolean evaluate(IEvaluationContext context)(Code) | | Evaluates the expression -- given the current state of the workbench.
This method should cache its computation. The cache will be cleared by a
call to clearResult .
Parameters: context - The context in which this state should be evaluated; must notbe null . true if the expression currently evaluates totrue ; false otherwise. |
getExpression | public Expression getExpression()(Code) | | Returns the expression controlling the activation or visibility of this
item.
The expression associated with this item; may benull . |
getSourcePriority | public int getSourcePriority()(Code) | | Returns the priority that has been given to this expression.
The priority. See Also: ISources |
setResult | public void setResult(boolean result)(Code) | | Forces the cached result to be a particular value. This will not
notify any users of the cache that it has changed.
Parameters: result - The cached result to use. since: 3.3 |
|
|