Abstract2DEnvironment

abstract class Abstract2DEnvironment<T, P : Position2D<P>?> : AbstractEnvironment<T, P> (source)

Models a bidimensional environment.

Parameters

<T>

concentration type

<P>

Position2D type

Properties

Link copied to clipboard
@get:Nonnull
val globalReactions: ListSet<GlobalReaction<T>>
Link copied to clipboard
@get:Nonnull
open val incarnation: Incarnation<T, P>
Link copied to clipboard
@get:Nonnull
val nodes: ListSet<Node<T>>
Link copied to clipboard
@Nullable
@get:Nonnull
open var simulation: Simulation<T, P>

Functions

Link copied to clipboard
abstract fun addGlobalReaction(p: GlobalReaction<T>)
open fun addGlobalReaction(@Nonnull reaction: GlobalReaction<T>)
Link copied to clipboard
abstract fun addLayer(p: Molecule, p1: Layer<T, P>)
fun addLayer(@Nonnull molecule: Molecule, @Nonnull layer: Layer<T, P>)
Link copied to clipboard
abstract fun addNode(p: Node<T>, p1: P): Boolean
fun addNode(@Nonnull node: Node<T>, @Nonnull p: P): Boolean
Link copied to clipboard
abstract fun addTerminator(p: TerminationPredicate<T, P>)

open fun addTerminator(@NotNull terminator: TerminationPredicate<T, P>)
Adds to the simulation a predicate that determines whether a simulation should be terminated.
Link copied to clipboard
fun forEach(action: Consumer<in Node<T>>)
open fun forEach(p: Consumer<in T>)
Link copied to clipboard
Link copied to clipboard
abstract fun getDistanceBetweenNodes(p: Node<T>, p1: Node<T>): Double
fun getDistanceBetweenNodes(@Nonnull n1: Node<T>, @Nonnull n2: Node<T>): Double
Link copied to clipboard
abstract fun getGlobalReactions(): ListSet<GlobalReaction<T>>
Link copied to clipboard
abstract fun getIncarnation(): Incarnation<T, P>
Link copied to clipboard
abstract fun getLayer(p: Molecule): Layer<T, P>
@Nullable
fun getLayer(@Nonnull molecule: Molecule): Layer<T, P>
Link copied to clipboard
abstract fun getLayers(): ListSet<Layer<T, P>>
fun getLayers(): ListSet<Layer<T, P>>
Link copied to clipboard
abstract fun getLinkingRule(): LinkingRule<T, P>
fun getLinkingRule(): LinkingRule<T, P>
Link copied to clipboard
abstract fun getNeighborhood(p: Node<T>): Neighborhood<T>
fun getNeighborhood(@Nonnull node: Node<T>): Neighborhood<T>
Link copied to clipboard
abstract fun getNodeByID(p: Int): Node<T>
fun getNodeByID(id: Int): Node<T>
Link copied to clipboard
abstract fun getNodeCount(): Int
Link copied to clipboard
abstract fun getNodes(): ListSet<Node<T>>
Link copied to clipboard
abstract fun getNodesWithinRange(p: Node<T>, p1: Double): ListSet<Node<T>>
fun getNodesWithinRange(@Nonnull position: P, range: Double): ListSet<Node<T>>
fun getNodesWithinRange(@Nonnull node: Node<T>, range: Double): ListSet<Node<T>>
Link copied to clipboard
Link copied to clipboard
abstract fun getPosition(p: Node<T>): P
fun getPosition(@Nonnull node: Node<T>): P
Link copied to clipboard
abstract fun getSimulation(): Simulation<T, P>
Link copied to clipboard
abstract fun getSimulationOrNull(): Simulation<T, P>
@Nullable
open fun getSimulationOrNull(): Simulation<T, P>
Link copied to clipboard
Link copied to clipboard

Override this method if units measuring distance do not match with units used for coordinates.
Link copied to clipboard
Link copied to clipboard
fun iterator(): Iterator<Node<T>>
abstract fun iterator(): Iterator<T>
Link copied to clipboard
abstract fun makePosition(p: Array<Number>): P
Link copied to clipboard
open fun moveNodeToPosition(node: Node<T>, newpos: P)
Subclasses may override this method if they want to change the way a node moves towards some absolute position.
Link copied to clipboard
abstract fun removeGlobalReaction(p: GlobalReaction<T>)
open fun removeGlobalReaction(@Nonnull reaction: GlobalReaction<T>)
Link copied to clipboard
abstract fun removeNode(p: Node<T>)
fun removeNode(@Nonnull node: Node<T>)
Link copied to clipboard
abstract fun setLinkingRule(p: LinkingRule<T, P>)
fun setLinkingRule(@Nonnull rule: LinkingRule<T, P>)
Link copied to clipboard
abstract fun setSimulation(p: Simulation<T, P>)
Link copied to clipboard
fun spliterator(): Spliterator<Node<T>>
Link copied to clipboard
open fun toString(): String
Not used internally.