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

scala.googleapis.firebase.FirebaseProjectState.scala Maven / Gradle / Ivy

There is a newer version: 0.4.5-v1beta1-20240918
Show newest version
package googleapis.firebase

import io.circe._

sealed abstract class FirebaseProjectState(val value: String) extends Product with Serializable
object FirebaseProjectState {

  /** Unspecified state.
    */
  case object STATE_UNSPECIFIED extends FirebaseProjectState("STATE_UNSPECIFIED")

  /** The Project is active.
    */
  case object ACTIVE extends FirebaseProjectState("ACTIVE")

  /** The Project has been soft-deleted.
    */
  case object DELETED extends FirebaseProjectState("DELETED")
  val values = List(STATE_UNSPECIFIED, ACTIVE, DELETED)
  def fromString(input: String): Either[String, FirebaseProjectState] = values
    .find(_.value == input)
    .toRight(s"'$input' was not a valid value for FirebaseProjectState")
  implicit val decoder: Decoder[FirebaseProjectState] = Decoder[String].emap(s => fromString(s))
  implicit val encoder: Encoder[FirebaseProjectState] = Encoder[String].contramap(_.value)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy