Package-level declarations

Types

Link copied to clipboard
interface Converter<F, T>

Converts values from one type to another bi-directionally. The type parameters F and T can be read as FROM and TO, as the forwards conversion converts F to T.

Link copied to clipboard
class DefaultValueConverter<V : Any>(val defaultValue: V) : Converter<V?, V>

Converts between an Optional property and a non-Optional property, using a default value when the Optional property's value is null.

Link copied to clipboard
data class GenConfig(val optional: Boolean = true, val stylable: Boolean = false, val delegates: Boolean = true, val functions: Boolean = false, val indirect: Boolean = false, val stylableOnly: Boolean = false, val validated: Boolean = false)
Link copied to clipboard
Link copied to clipboard
expect class Weak<V>(value: V)
actual class Weak<V>(val value: V)
actual class Weak<V>(value: V)

Properties

Functions

Link copied to clipboard

Note, this returns a Double, rather than a Long, so that the javascript implementation is efficient. (Javascript doesn't support longs).

Note, this returns a Double, rather than a Long, so that the javascript implementation is efficient. (Javascript doesn't support longs).

Link copied to clipboard
fun generateBoilerplate(baseDirectory: File, boilerplatePackageName: String, klass: KClass<*>, config: GenConfig = GenConfig(), outputFilename: String = "Boilerplate.kt")

fun generateBoilerplate(baseDirectory: File, boilerplatePackageName: String, name: String, type: String, imports: List<String>, templates: List<(String, String, String, GenConfig) -> String>, config: GenConfig, outputFilename: String = "Boilerplate.kt")

Only use this directly if you need additional control over the imports, or if the type isn't a simple type (i.e. it is a generic type), or if you wish to add your own custom templates.

Link copied to clipboard
fun main(vararg args: String)

Generates property boilerplate for the following types :