org.eclipse.ocl.examples.impactanalyzer.instanceScope.traceback
Class AbstractTracebackStep.TracebackStepAndScopeChange

java.lang.Object
  extended by org.eclipse.ocl.examples.impactanalyzer.instanceScope.traceback.AbstractTracebackStep.TracebackStepAndScopeChange
All Implemented Interfaces:
TracebackStep
Direct Known Subclasses:
AbstractTracebackStep.TracebackStepAndScopeChangeWithOperationCallExp
Enclosing class:
AbstractTracebackStep<E extends OCLExpression>

public static class AbstractTracebackStep.TracebackStepAndScopeChange
extends java.lang.Object
implements TracebackStep

Encapsulates the scope change that has to happen before invoking a subsequent traceback step.

Author:
Axel Uhl (D043530)

Constructor Summary
AbstractTracebackStep.TracebackStepAndScopeChange(TracebackStep step, java.util.Set<Variable> variablesThatLeaveOrEnterScopeWhenCallingStep)
           
 
Method Summary
 java.lang.String toString()
           
 OperationCallExpKeyedSet traceback(AnnotatedEObject source, UnusedEvaluationRequestSet pendingUnusedEvalRequests, TracebackCache tracebackCache, org.eclipse.emf.common.notify.Notification changeEvent)
          When being executed, the step computes a conservative superset of the objects that, when used as the context for the overall OCLExpression, may cause the expression for which this TracebackStep was created to evaluate to source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AbstractTracebackStep.TracebackStepAndScopeChange

public AbstractTracebackStep.TracebackStepAndScopeChange(TracebackStep step,
                                                         java.util.Set<Variable> variablesThatLeaveOrEnterScopeWhenCallingStep)
Method Detail

traceback

public OperationCallExpKeyedSet traceback(AnnotatedEObject source,
                                          UnusedEvaluationRequestSet pendingUnusedEvalRequests,
                                          TracebackCache tracebackCache,
                                          org.eclipse.emf.common.notify.Notification changeEvent)
Description copied from interface: TracebackStep
When being executed, the step computes a conservative superset of the objects that, when used as the context for the overall OCLExpression, may cause the expression for which this TracebackStep was created to evaluate to source.

Specified by:
traceback in interface TracebackStep
Parameters:
source - the object to which the expression, for which this step was created, shall evaluate
pendingUnusedEvalRequests - When tracing back a VariableExp expression, this infers a value for the variable referred to by the expression. This may trigger a previously delayed "unused" evaluation to be triggered. Those triggerable "unused" evaluation requests are passed using this parameter. When triggering one of them proves the location of the original change to be unused, an empty set will result from this call. May be null, having the same effect as passing a set that contains no requests.
tracebackCache - cache in which previous results of TracebackStep.traceback(AnnotatedEObject, UnusedEvaluationRequestSet, org.eclipse.ocl.examples.impactanalyzer.instanceScope.traceback.TracebackCache, Notification) executions can be found
changeEvent - the original change event; used for performing pre/post evaluations
Returns:
the set of objects (with optional annotation explaining the derivation path of each object) for which, when used as context for the overall expression, the OCL (sub-)expression for which this step is responsible may evaluate to source. The resulting objects may additionally be keyed by OperationCallExp expressions in case their inference left an operation body through a self or parameter variable. These keys are removed again in the OperationCallTracebackStep, keying the results specific to the call being traced by the null key. All object reached without leaving an operation body through a self or parameter variable are also keyed by the null key.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object