All Downloads are FREE. Search and download functionalities are using the official Maven repository.

lucuma.itc.input.ImagingIntegrationTimeInput.scala Maven / Gradle / Ivy

There is a newer version: 0.22.3
Show newest version
// Copyright (c) 2016-2023 Association of Universities for Research in Astronomy, Inc. (AURA)
// For license information see LICENSE or https://opensource.org/licenses/BSD-3-Clause

package lucuma.itc.input

import cats.syntax.parallel.*
import lucuma.core.enums.Band
import lucuma.core.math.RadialVelocity
import lucuma.core.math.SignalToNoise
import lucuma.core.math.Wavelength
import lucuma.core.model.SourceProfile
import lucuma.odb.graphql.binding.*
import lucuma.odb.graphql.input.*
import lucuma.odb.graphql.input.sourceprofile.*

case class ImagingIntegrationTimeInput(
  wavelength:     Wavelength,
  signalToNoise:  SignalToNoise,
  sourceProfile:  SourceProfile,
  band:           Band,
  radialVelocity: RadialVelocity,
  constraints:    ConstraintSetInput,
  mode:           InstrumentModesInput
)

object ImagingIntegrationTimeInput {

  def binding: Matcher[ImagingIntegrationTimeInput] =
    ObjectFieldsBinding.rmap {
      case List(
            WavelengthInput.Binding("wavelength", wavelength),
            SignalToNoiseBinding("signalToNoise", signalToNoise),
            SourceProfileInput.CreateBinding("sourceProfile", sourceProfile),
            BandBinding("band", band),
            RadialVelocityInput.Binding("radialVelocity", radialVelocity),
            ConstraintSetInput.Binding("constraints", constraints),
            InstrumentModesInput.binding("mode", mode)
          ) =>
        (wavelength, signalToNoise, sourceProfile, band, radialVelocity, constraints, mode).parMapN(
          apply
        )
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy