Kieker 1.2

kieker.tools.traceAnalysis.systemModel
Class ExecutionTrace

java.lang.Object
  extended by kieker.tools.traceAnalysis.systemModel.Trace
      extended by kieker.tools.traceAnalysis.systemModel.ExecutionTrace
All Implemented Interfaces:
IAnalysisEvent

public class ExecutionTrace
extends Trace

Author:
Andre van Hoorn

Constructor Summary
ExecutionTrace(long traceId)
           
 
Method Summary
 void add(Execution execution)
          Adds an execution to the trace.
 boolean equals(Object obj)
          Returns whether this Execution Trace and the passed Object are equal.
 long getDurationInNanos()
          Returns the duration of this (possible incomplete) trace in nanoseconds.
 int getLength()
          Returns the length of this trace in terms of the number of contained executions.
 int getMaxEoi()
          Returns the maximum execution order index (eoi) value within the trace.
 int getMaxEss()
          Returns the maximum execution stack size (ess) value, i.e., the maximum stack depth, within the trace.
 long getMaxTout()
          Returns the maximum timestamp value of an execution return in this trace.
 int getMinEoi()
          Returns the minimum execution order index (eoi) value within the trace.
 long getMinTin()
          Returns the minimum timestamp of an execution start in this trace.
 SortedSet<Execution> getTraceAsSortedExecutionSet()
          TODO: It's not a good idea to return the internal data structure.
 MessageTrace toMessageTrace(Execution rootExecution)
          Returns the message trace representation for this trace.
 String toString()
           
 
Methods inherited from class kieker.tools.traceAnalysis.systemModel.Trace
getTraceId
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ExecutionTrace

public ExecutionTrace(long traceId)
Method Detail

add

public void add(Execution execution)
         throws InvalidTraceException
Adds an execution to the trace.

Parameters:
execution -
Throws:
InvalidTraceException - if the traceId of the passed Execution object is not the same as the traceId of this ExecutionTrace object.

toMessageTrace

public MessageTrace toMessageTrace(Execution rootExecution)
                            throws InvalidTraceException
Returns the message trace representation for this trace. The transformation to a message trace is only computed during the first execution of this method. After this, the stored reference is returned --- unless executions are added to the trace afterwards.

Throws:
InvalidTraceException

getTraceAsSortedExecutionSet

public final SortedSet<Execution> getTraceAsSortedExecutionSet()
TODO: It's not a good idea to return the internal data structure.

Returns:

getLength

public final int getLength()
Returns the length of this trace in terms of the number of contained executions.

Returns:

toString

public String toString()
Overrides:
toString in class Object

getMaxEss

public int getMaxEss()
Returns the maximum execution stack size (ess) value, i.e., the maximum stack depth, within the trace.

Returns:
the maximum ess; -1 if the trace contains no executions.

getMaxEoi

public int getMaxEoi()
Returns the maximum execution order index (eoi) value within the trace.

Returns:
the maximum eoi; -1 if the trace contains no executions.

getMinEoi

public int getMinEoi()
Returns the minimum execution order index (eoi) value within the trace.

Returns:
the minimum eoi; -1 if the trace contains no executions.

getDurationInNanos

public long getDurationInNanos()
Returns the duration of this (possible incomplete) trace in nanoseconds. This value is the difference between the maximum tout and the minimum tin value.

Returns:

getMaxTout

public long getMaxTout()
Returns the maximum timestamp value of an execution return in this trace. Notice that you should need use this value to reason about the control flow --- particularly in distributed scenarios.

Returns:
the maxmum timestamp value; -1 if the trace contains no executions.

getMinTin

public long getMinTin()
Returns the minimum timestamp of an execution start in this trace. Notice that you should need use this value to reason about the control flow --- particularly in distributed scenarios.

Returns:
the minimum timestamp value; -1 if the trace contains no executions.

equals

public boolean equals(Object obj)
Returns whether this Execution Trace and the passed Object are equal. Two execution traces are equal iff the set of contained executions is equal.

Overrides:
equals in class Object
Parameters:
obj -
Returns:

Kieker 1.2

Copyright 2010 the Kieker Project, http://kieker.sourceforge.net