TomlBasicString constructor
TomlBasicString(
- String value
Creates a new basic TOML string value with the given contents.
Throws a ArgumentError when the given value cannot be encoded as a basic string (see canEncode).
Implementation
factory TomlBasicString(String value) {
if (!canEncode(value)) {
throw ArgumentError('Invalid basic string: $value');
}
return TomlBasicString._fromEncodable(value);
}