package space.nstart.pcp.angularmotion

import ballistics.orbitalPoints.timeStepper.AbstractStepper
import ballistics.types.EarthType

object AngularMotionCalculatorFactory {
    fun create(
        mode: AngularMotionMode,
        stepper: AbstractStepper,
        earthType: EarthType = EarthType.PZ90d02,
        config: AngularMotionConfig = AngularMotionConfig(),
    ): AngularMotionCalculator =
        when (mode) {
            AngularMotionMode.CONST_ORIENT -> ConstOrientPUUD(stepper, earthType, config)
            AngularMotionMode.AZIMUTH -> AzimuthPUUD(stepper, earthType, config)
            AngularMotionMode.SMOOTH_SDI -> SmoothSDIPUUD(stepper, earthType, config)
        }
}
