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

scala.googleapis.bigquery.ForeignViewDefinition.scala Maven / Gradle / Ivy

There is a newer version: 0.4.5-v2-20240905
Show newest version
package googleapis.bigquery

import io.circe._
import io.circe.syntax._

final case class ForeignViewDefinition(
    /** Optional. Represents the dialect of the query.
      */
    dialect: Option[String] = None,
    /** Required. The query that defines the view.
      */
    query: Option[String] = None,
)
object ForeignViewDefinition {
  implicit val encoder: Encoder[ForeignViewDefinition] = Encoder.instance { x =>
    Json.obj("dialect" := x.dialect, "query" := x.query)
  }
  implicit val decoder: Decoder[ForeignViewDefinition] = Decoder.instance { c =>
    for {
      v0 <- c.get[Option[String]]("dialect")
      v1 <- c.get[Option[String]]("query")
    } yield ForeignViewDefinition(v0, v1)

  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy