kgraphql / com.apurebase.kgraphql.schema.dsl.types / TypeDSL

TypeDSL

open class TypeDSL<T : Any> : ItemDSL

Constructors

<init>

TypeDSL(supportedUnions: Collection<Union>, kClass: KClass<T>)

Properties

dataloadedExtensionProperties

val dataloadedExtensionProperties: MutableSet<DataLoadedFunction<T, *, *>>

kClass

val kClass: KClass<T>

name

var name: String

Functions

configure

fun <R> KProperty1<T, R>.configure(block: KotlinPropertyDSL<T, R>.() -> Unit): Unit

dataProperty

fun <KEY, TYPE> dataProperty(name: String, block: DataLoaderPropertyDSL<T, KEY, TYPE>.() -> Unit): Unit

ignore

fun <R> KProperty1<T, R>.ignore(): Unit

property

fun <R> property(kProperty: KProperty1<T, R>, block: KotlinPropertyDSL<T, R>.() -> Unit): Unit
fun <R> property(name: String, block: PropertyDSL<T, R>.() -> Unit): Unit

transformation

fun <R, E> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E) -> R): Unit
fun <R, E, W> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W) -> R): Unit
fun <R, E, W, Q> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q) -> R): Unit
fun <R, E, W, Q, A> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q, A) -> R): Unit
fun <R, E, W, Q, A, S> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q, A, S) -> R): Unit
fun <R, E, W, Q, A, S, B> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q, A, S, B) -> R): Unit
fun <R, E, W, Q, A, S, B, U> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q, A, S, B, U) -> R): Unit
fun <R, E, W, Q, A, S, B, U, C> transformation(kProperty: KProperty1<T, R>, function: suspend (R, E, W, Q, A, S, B, U, C) -> R): Unit

unionProperty

fun unionProperty(name: String, block: UnionPropertyDSL<T>.() -> Unit): Unit