vertx / io.vertx.core.cli.converters / BooleanConverter

BooleanConverter

class BooleanConverter : Converter<Boolean>

A converter for boolean. This converter considered as 'true' : "true", "on", "1", "yes". All other values are considered as 'false' (as a consequence, 'null' is considered as 'false').

Author
Clement Escoffier

Properties

INSTANCE

static val INSTANCE: BooleanConverter

The converter.

Functions

fromString

fun fromString(value: String): Boolean

Creates the boolean value from the given String. If the given String does not match one of the 'true' value, false is returned.