EnvironmentMonitor

class EnvironmentMonitor<T, P : Position<P>, TS : Any, PS : PositionSurrogate>(toConcentrationSurrogate: (T) -> TS, toPositionSurrogate: (P) -> PS) : OutputMonitor<T, P>

A monitor that maps an Environment into an EnvironmentSurrogate and saves it in the store.

Parameters

concentration surrogate type.
toConcentrationSurrogate

the mapping function from to .

toPositionSurrogate

the mapping function from

to .

Constructors

Link copied to clipboard
constructor(toConcentrationSurrogate: (T) -> TS, toPositionSurrogate: (P) -> PS)

Functions

Link copied to clipboard
open override fun finished(environment: Environment<T, P>, time: Time, step: Long)

Call the stepDone(Environment, Actionable?, Time, Long) method setting the reaction to null.

Link copied to clipboard
open override fun initialized(environment: Environment<T, P>)

Call the stepDone(Environment, Actionable?, Time, Long) method setting time and step to 0.

Link copied to clipboard
open override fun stepDone(environment: Environment<T, P>, reaction: Actionable<T>?, time: Time, step: Long)

Every time the Environment changes, map it to EnvironmentSurrogate class and save it in the store.