LiteralPredicate

class LiteralPredicate(val output: Boolean) : ComponentPredicate(source)

A predicate that always returns output.

Constructors

Link copied to clipboard
constructor(output: Boolean)

Properties

Link copied to clipboard
private val output: Boolean

Functions

Link copied to clipboard
open override fun addListener(listener: (Boolean) -> Unit)

Does nothing, because there's no need to respond to any events to determine the output of invoke.

Link copied to clipboard
open operator override fun invoke(): Boolean

Returns output.