Create a IniFile from a string content

var ini = new IniFile.from_string("""
key1=value1
[section1]
key2=value2
""")
assert ini["key1"] == "value1"
assert ini["section1.key2"] == "value2"

See also stop_on_first_error and errors.

Property definitions

ini $ IniFile :: from_string
	# Create a IniFile from a `string` content
	#
	# ~~~
	# var ini = new IniFile.from_string("""
	# key1=value1
	# [section1]
	# key2=value2
	# """)
	# assert ini["key1"] == "value1"
	# assert ini["section1.key2"] == "value2"
	# ~~~
	#
	# See also `stop_on_first_error` and `errors`.
	init from_string(string: String, stop_on_first_error: nullable Bool) do
		init stop_on_first_error or else false
		load_string(string)
	end
lib/ini/ini.nit:83,2--99,4