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): FormPanel<K>
Adds a string control to the form panel bound to custom field type.
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
Return
current form panel