delegateClosureOf

fun <T> Any.delegateClosureOf(action: T.() -> Unit): Closure<Unit>(source)

Adapts a Kotlin function to a Groovy Closure that operates on the configured Closure delegate.

Parameters

T

the expected type of the delegate argument to the closure.

action

the function to be adapted.

See also