com.yandex.div.dsl.model.DivStroke.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 DivStroke internal constructor(
@JsonIgnore val color: Property?,
@JsonIgnore val unit: Property?,
@JsonIgnore val width: Property?,
) {
@JsonAnyGetter
internal fun properties(): Map {
return propertyMapOf(
"color" to color,
"unit" to unit,
"width" to width,
)
}
}
fun TemplateContext.divStroke(): LiteralProperty {
return value(DivStroke(
color = null,
unit = null,
width = null,
))
}
fun TemplateContext.divStroke(
color: Property? = null,
unit: Property? = null,
width: Property? = null,
): LiteralProperty {
return value(DivStroke(
color = color,
unit = unit,
width = width,
))
}
fun TemplateContext.divStroke(
color: Color? = null,
unit: DivSizeUnit? = null,
width: Int? = null,
): LiteralProperty {
return value(DivStroke(
color = optionalValue(color),
unit = optionalValue(unit),
width = optionalValue(width),
))
}
fun CardContext.divStroke(
color: ValueProperty,
unit: ValueProperty? = null,
width: ValueProperty? = null,
): DivStroke {
return DivStroke(
color = color,
unit = unit,
width = width,
)
}
fun CardContext.divStroke(
color: Color,
unit: DivSizeUnit? = null,
width: Int? = null,
): DivStroke {
return DivStroke(
color = value(color),
unit = optionalValue(unit),
width = optionalValue(width),
)
}