add

fun <T : Any> add(objectWithParameters: T, label: String? = objectWithParameters.title()): T(source)

Add an object to the GUI

Return

pass-through of objectWithParameters

Parameters

objectWithParameters

an object of a class that annotated parameters

label

an optional label that overrides the label supplied in a Description annotation


fun <T : Any> add(label: String? = null, builder: () -> T): T(source)

Add an object to the GUI using a builder.

Return

the built object

Parameters

label

an optional label that overrides the label supplied in a Description annotation