com.yandex.div.dsl.model.DivRadialGradient.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of kotlin-json-builder Show documentation
Show all versions of kotlin-json-builder Show documentation
DivKit is an open source Server-Driven UI (SDUI) framework. SDUI is a an emerging technique that leverage the server to build the user interfaces of their mobile app.
// Generated code. Do not modify.
package com.yandex.div.dsl.model
import java.net.URI
import com.fasterxml.jackson.annotation.*
import com.yandex.div.dsl.*
import com.yandex.div.dsl.context.*
import com.yandex.div.dsl.type.*
import com.yandex.div.dsl.util.*
class DivRadialGradient internal constructor(
@JsonIgnore val centerX: Property?,
@JsonIgnore val centerY: Property?,
@JsonIgnore val colors: Property>?,
@JsonIgnore val radius: Property?,
) : DivTextGradient, DivBackground {
@JsonProperty("type") override val type = "radial_gradient"
@JsonAnyGetter
internal fun properties(): Map {
return propertyMapOf(
"center_x" to centerX,
"center_y" to centerY,
"colors" to colors,
"radius" to radius,
)
}
}
fun TemplateContext.divRadialGradient(): LiteralProperty {
return value(DivRadialGradient(
centerX = null,
centerY = null,
colors = null,
radius = null,
))
}
fun TemplateContext.divRadialGradient(
colors: Property>? = null,
centerX: Property? = null,
centerY: Property? = null,
radius: Property? = null,
): LiteralProperty {
return value(DivRadialGradient(
centerX = centerX,
centerY = centerY,
colors = colors,
radius = radius,
))
}
fun TemplateContext.divRadialGradient(
colors: List? = null,
centerX: DivRadialGradientCenter? = null,
centerY: DivRadialGradientCenter? = null,
radius: DivRadialGradientRadius? = null,
): LiteralProperty {
return value(DivRadialGradient(
centerX = optionalValue(centerX),
centerY = optionalValue(centerY),
colors = optionalValue(colors),
radius = optionalValue(radius),
))
}
fun CardContext.divRadialGradient(
colors: ValueProperty>,
centerX: ValueProperty? = null,
centerY: ValueProperty? = null,
radius: ValueProperty? = null,
): DivRadialGradient {
return DivRadialGradient(
centerX = centerX,
centerY = centerY,
colors = colors,
radius = radius,
)
}
fun CardContext.divRadialGradient(
colors: List,
centerX: DivRadialGradientCenter? = null,
centerY: DivRadialGradientCenter? = null,
radius: DivRadialGradientRadius? = null,
): DivRadialGradient {
return DivRadialGradient(
centerX = optionalValue(centerX),
centerY = optionalValue(centerY),
colors = value(colors),
radius = optionalValue(radius),
)
}