from

fun TomlValue.Companion.from(string: String): TomlValue.Map

Parse the given TOML-formatted string into a TOML map.

If the string does not contain a valid TOML document, a TomlException.ParseError is thrown.


fun TomlValue.Companion.from(stream: InputStream): TomlValue.Map

Parse the given TOML-formatted input stream into a TOML map.

If the stream does not contain a valid TOML document, a TomlException.ParseError is thrown.


fun TomlValue.Companion.from(path: Path): TomlValue.Map

Parse the given TOML-formatted file into a TOML map.

If the indicated file does not contain a valid TOML document, a TomlException.ParseError is thrown.