org.eclipse.emf.henshin.statespace.impl
Class ProfilingStateSpaceManager

java.lang.Object
  extended by org.eclipse.emf.henshin.statespace.impl.StateSpaceIndexImpl
      extended by org.eclipse.emf.henshin.statespace.impl.BasicStateSpaceManager
          extended by org.eclipse.emf.henshin.statespace.impl.ProfilingStateSpaceManager
All Implemented Interfaces:
StateSpaceIndex, StateSpaceManager

public class ProfilingStateSpaceManager
extends BasicStateSpaceManager

StateSpaceManager implementation for gathering profiling statistics.


Field Summary
protected  long derivationTime
           
protected  long explorationTime
           
protected  long lastPrintTime
           
protected  long printInterval
           
protected  long stateFindingTime
           
 
Fields inherited from class org.eclipse.emf.henshin.statespace.impl.BasicStateSpaceManager
explorers, ignoreDuplicateTransitions, maxStateDistance, stateDistanceMonitor, stateSpaceLock
 
Fields inherited from interface org.eclipse.emf.henshin.statespace.StateSpaceManager
DEBUG_ENFORCE_DETERMINISM
 
Constructor Summary
ProfilingStateSpaceManager(StateSpace stateSpace)
          Default constructor.
 
Method Summary
protected  StateExplorer acquireExplorer()
           
protected  Model deriveModel(State state, boolean fromInitial)
           
protected  State findState(Model model, int hashCode, Collection<State> states)
           
protected  State getState(Model model, int hash)
          Get the state for a given model and its hash code.
 void printStats()
           
 
Methods inherited from class org.eclipse.emf.henshin.statespace.impl.BasicStateSpaceManager
clearCache, createInitialState, createOpenState, exploreState, exploreStates, getNumThreads, getStateDistance, isOpen, mergeTerminalStates, refreshHelpers, releaseExplorer, removeState, resetStateSpace, shiftedLocation, shutdown
 
Methods inherited from class org.eclipse.emf.henshin.statespace.impl.StateSpaceIndexImpl
addToCache, addToIndex, getCachedModel, getModel, getState, getStateSpace, removeFromIndex, resetIndex
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.emf.henshin.statespace.StateSpaceIndex
getCachedModel, getModel, getState, getStateSpace
 

Field Detail

explorationTime

protected long explorationTime

derivationTime

protected long derivationTime

stateFindingTime

protected long stateFindingTime

lastPrintTime

protected long lastPrintTime

printInterval

protected long printInterval
Constructor Detail

ProfilingStateSpaceManager

public ProfilingStateSpaceManager(StateSpace stateSpace)
Default constructor.

Parameters:
stateSpace - State space.
Method Detail

getState

protected State getState(Model model,
                         int hash)
                  throws StateSpaceException
Description copied from class: StateSpaceIndexImpl
Get the state for a given model and its hash code.

Overrides:
getState in class StateSpaceIndexImpl
Parameters:
model - State model.
hash - Its hash code.
Returns:
The corresponding state if it exists.
Throws:
StateSpaceException

findState

protected State findState(Model model,
                          int hashCode,
                          Collection<State> states)
                   throws StateSpaceException
Overrides:
findState in class BasicStateSpaceManager
Throws:
StateSpaceException

deriveModel

protected Model deriveModel(State state,
                            boolean fromInitial)
                     throws StateSpaceException
Overrides:
deriveModel in class BasicStateSpaceManager
Throws:
StateSpaceException

acquireExplorer

protected StateExplorer acquireExplorer()
Overrides:
acquireExplorer in class BasicStateSpaceManager

printStats

public void printStats()