Record Class SimulationContext
java.lang.Object
java.lang.Record
energy.eddie.regionconnector.simulation.engine.SimulationContext
- Record Components:
documentStreams- the streams that aStepcan emit topermissionId- provided by the entity executing the test simulationconnectionId- provided by the entity executing the test simulationdataNeedId- provided by the entity executing the test simulation, must be a valid data need ID
public record SimulationContext(DocumentStreams documentStreams, String permissionId, String connectionId, String dataNeedId)
extends Record
The simulation context contains information, which is not available during the
Model creation, but during the runtime phase.
Can be thought of similar to command line arguments.-
Constructor Summary
ConstructorsConstructorDescriptionSimulationContext(DocumentStreams documentStreams, String permissionId, String connectionId, String dataNeedId) Creates an instance of aSimulationContextrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theconnectionIdrecord component.Returns the value of thedataNeedIdrecord component.Returns the value of thedocumentStreamsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thepermissionIdrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
SimulationContext
public SimulationContext(DocumentStreams documentStreams, String permissionId, String connectionId, String dataNeedId) Creates an instance of aSimulationContextrecord class.- Parameters:
documentStreams- the value for thedocumentStreamsrecord componentpermissionId- the value for thepermissionIdrecord componentconnectionId- the value for theconnectionIdrecord componentdataNeedId- the value for thedataNeedIdrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
documentStreams
Returns the value of thedocumentStreamsrecord component.- Returns:
- the value of the
documentStreamsrecord component
-
permissionId
Returns the value of thepermissionIdrecord component.- Returns:
- the value of the
permissionIdrecord component
-
connectionId
Returns the value of theconnectionIdrecord component.- Returns:
- the value of the
connectionIdrecord component
-
dataNeedId
Returns the value of thedataNeedIdrecord component.- Returns:
- the value of the
dataNeedIdrecord component
-