addCustom

open fun <C : StringFormControl> addCustom(key: KProperty1<K, Any?>, control: C, required: Boolean = false, requiredMessage: String? = null, legend: String? = null, validatorMessage: (C) -> String?? = null, validator: (C) -> Boolean?? = null)

Adds a string control to the form panel bound to custom field type.

Parameters

key

key identifier of the control

control

the string form control

required

determines if the control is required

requiredMessage

optional required validation message

legend

put this control inside a fieldset with given legend

validatorMessage

optional function returning validation message

validator

optional validation function