tuweni / org.apache.tuweni.toml / TomlTable / getLocalTime

getLocalTime

@Nullable open fun getLocalTime(dottedKey: String): LocalTime? (source)

Get a local time from the TOML document.

Parameters

dottedKey - A dotted key (e.g. "server.address.port").

Exceptions

IllegalArgumentException - If the key cannot be parsed.

TomlInvalidTypeException - If the value is present but not a LocalTime, or any element of the path preceding the final key is not a table.

Return
The value, or null if no value was set in the TOML document.

@Nullable open fun getLocalTime(path: MutableList<String>): LocalTime? (source)

Get a local time from the TOML document.

Parameters

path - The key path.

Exceptions

TomlInvalidTypeException - If the value is present but not a LocalTime, or any element of the path preceding the final key is not a table.

Return
The value, or null if no value was set in the TOML document.

open fun getLocalTime(dottedKey: String, defaultValue: Supplier<LocalTime>): LocalTime (source)

Get a local time from the TOML document, or return a default.

Parameters

dottedKey - A dotted key (e.g. "server.address.port").

defaultValue - A supplier for the default value.

Exceptions

IllegalArgumentException - If the key cannot be parsed.

TomlInvalidTypeException - If the value is present but not a LocalTime, or any element of the path preceding the final key is not a table.

Return
The value, or the default.

open fun getLocalTime(path: MutableList<String>, defaultValue: Supplier<LocalTime>): LocalTime (source)

Get a local time from the TOML document, or return a default.

Parameters

path - The key path.

defaultValue - A supplier for the default value.

Exceptions

TomlInvalidTypeException - If the value is present but not a LocalTime, or any element of the path preceding the final key is not a table.

Return
The value, or the default.