interface DependencyGraph<T : Any!>
This interface allows to separate the usage of a dependency graph from its implementation.
addNeighbor |
Given two nodes, the graph assumes they are now neighbors and calculates the neighborhood dependencies between them. abstract fun addNeighbor(n1: Node<T>!, n2: Node<T>!): Unit |
createDependencies |
This method creates the dependencies when a new reaction is added to the environment. Please be careful when building the environment and populating the existing reactions map: this method assumes that all the dependencies among the existing reactions are correct and up to date. abstract fun createDependencies(rh: Reaction<T>!): Unit |
globalInputContextReactions |
abstract fun globalInputContextReactions(): ListSet<Reaction<T>!>! |
outboundDependencies |
Returns the set of reactions that may be influenced by the provided reaction. abstract fun outboundDependencies(reaction: Reaction<T>!): ListSet<Reaction<T>!>! |
removeDependencies |
This method removes all the dependencies (both in and out dependencies) for a given reaction handler. This method is meant to be used in order to keep the dependencies clean when removing a reaction. abstract fun removeDependencies(rh: Reaction<T>!): Unit |
removeNeighbor |
Given two nodes, the engine assumes they are no longer neighbors and deletes the neighborhood dependencies between them. abstract fun removeNeighbor(n1: Node<T>!, n2: Node<T>!): Unit |