Skip to content

Commit

Permalink
core: envelope-sim: migrate pipelines to kt
Browse files Browse the repository at this point in the history
Signed-off-by: Eloi Charpentier <[email protected]>
  • Loading branch information
eckter committed Dec 3, 2024
1 parent 708cf8e commit 9dedb37
Show file tree
Hide file tree
Showing 6 changed files with 318 additions and 267 deletions.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package fr.sncf.osrd.envelope_sim

import com.google.common.collect.RangeMap

class EnvelopeSimContext(
@JvmField val rollingStock: PhysicsRollingStock,
@JvmField val path: PhysicsPath,
@JvmField val timeStep: Double,
@JvmField
val tractiveEffortCurveMap: RangeMap<Double, Array<PhysicsRollingStock.TractiveEffortPoint>>
) {
/** Creates a context suitable to run simulations on envelopes */
init {
checkNotNull(tractiveEffortCurveMap)
}

fun updateCurves(
tractiveEffortCurveMap: RangeMap<Double, Array<PhysicsRollingStock.TractiveEffortPoint>>
): EnvelopeSimContext {
return EnvelopeSimContext(rollingStock, path, timeStep, tractiveEffortCurveMap)
}
}
Loading

0 comments on commit 9dedb37

Please sign in to comment.