From c9f98dfdbdc3f56553b58dc226b3f841189d0fc0 Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Wed, 7 Mar 2018 13:46:10 +0100 Subject: API documentation update --- api/index-outline.html | 92 +++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 72 insertions(+), 20 deletions(-) (limited to 'api/index-outline.html') diff --git a/api/index-outline.html b/api/index-outline.html index 0815c13a..2d6124cf 100644 --- a/api/index-outline.html +++ b/api/index-outline.html @@ -764,11 +764,11 @@ -DataContainer(model: ObservableList<M>, binding: (Int) -> C, filter: (Int) -> Boolean = null, child: Container = VPanel(), init: DataContainer<M, C>.() -> Unit = null)
+DataContainer(model: ObservableList<M>, factory: (Int, M) -> C, filter: (Int, M) -> Boolean = null, mapping: (List<M>) -> List<M> = null, container: Container = VPanel(), init: DataContainer<M, C>.() -> Unit = null)
fun add(child: Component): Container
fun addAll(children: List<Component>): Container
fun clearOnUpdate(): DataContainer<M, C>
-fun <M, C : Component> Container.dataContainer(model: ObservableList<M>, binding: (Int) -> C, filter: (Int) -> Boolean = null, child: Container = VPanel(), init: DataContainer<M, C>.() -> Unit = null): DataContainer<M, C>
+fun <M, C : Component> Container.dataContainer(model: ObservableList<M>, factory: (Int, M) -> C, filter: (Int, M) -> Boolean = null, mapping: (List<M>) -> List<M> = null, container: Container = VPanel(), init: DataContainer<M, C>.() -> Unit = null): DataContainer<M, C>
fun getChildren(): List<Component>
fun onUpdate(handler: () -> Unit): DataContainer<M, C>
fun remove(child: Component): Container
@@ -1134,13 +1134,16 @@ Form(panel: FormPanel<K>? = null, modelFactory: (Map<String, Any?>) -> K)
-fun <C : FormControl> add(key: String, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): Form<K>
+fun <C : StringFormControl> add(key: KProperty1<K, String?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): Form<K>
+fun <C : BoolFormControl> add(key: KProperty1<K, Boolean?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): Form<K>
+fun <C : NumberFormControl> add(key: KProperty1<K, Number?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): Form<K>
+fun <C : DateFormControl> add(key: KProperty1<K, Date?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): Form<K>
fun clearData(): Unit
-operator fun get(key: String): Any?
-fun getControl(key: String): FormControl?
+operator fun get(key: KProperty1<K, *>): Any?
+fun getControl(key: KProperty1<K, *>): FormControl?
fun getData(): K
fun getDataJson(): Json
-fun remove(key: String): Form<K>
+fun remove(key: KProperty1<K, *>): Form<K>
fun removeAll(): Form<K>
fun setData(model: K): Unit
fun validate(): Boolean
@@ -1178,15 +1181,19 @@ FormPanel(type: FormType? = null, classes: Set<String> = setOf(), modelFactory: (Map<String, Any?>) -> K)
-open fun <C : FormControl> add(key: String, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
+open fun <C : StringFormControl> add(key: KProperty1<K, String?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
+open fun <C : BoolFormControl> add(key: KProperty1<K, Boolean?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
+open fun <C : NumberFormControl> add(key: KProperty1<K, Number?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
+open fun <C : DateFormControl> add(key: KProperty1<K, Date?>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
+protected fun <C : FormControl> addInternal(key: KProperty1<K, *>, control: C, required: Boolean = false, validatorMessage: (C) -> String? = null, validator: (C) -> Boolean? = null): FormPanel<K>
open fun clearData(): Unit
fun <K> Container.formPanel(type: FormType? = null, classes: Set<String> = setOf(), modelFactory: (Map<String, Any?>) -> K): FormPanel<K>
-operator fun get(key: String): Any?
-open fun getControl(key: String): FormControl?
+operator fun get(key: KProperty1<K, *>): Any?
+open fun getControl(key: KProperty1<K, *>): FormControl?
open fun getData(): K
open fun getDataJson(): Json
protected open fun getSnClass(): List<StringBoolPair>
-open fun remove(key: String): FormPanel<K>
+open fun remove(key: KProperty1<K, *>): FormPanel<K>
open fun removeAll(): FormPanel<K>
protected open fun render(): VNode
open fun setData(model: K): Unit
@@ -1430,6 +1437,22 @@ +open class Icon : Tag
+ open class Image : Widget
+open class Icon : Tag
+ open class Image : Widget