namespace SweetLib.Classes.Storer { /// /// Interface, which provides several methods to store simple data. /// public interface IStorer { /// /// Reads a string value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Default value, if this value does not exist. /// Value of the in . string ReadString(string section, string key, string defaultValue = ""); /// /// Reads an integer value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Default value, if this value does not exist. /// Value of the in . int ReadInteger(string section, string key, int defaultValue = 0); /// /// Reads a bool value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Default value, if this value does not exist. /// Value of the in . bool ReadBool(string section, string key, bool defaultValue = false); /// /// Checks, if a key exists inside a section. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// True, if is found inside . bool HasKey(string section, string key); /// /// Writes a string value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Value to be stored. void WriteString(string section, string key, string value); /// /// Writes an integer value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Value to be stored. void WriteInteger(string section, string key, int value); /// /// Writes a bool value. /// /// Represents the section in which the data is stored. /// Represents the key of the stored data. /// Value to be stored. void WriteBool(string section, string key, bool value); /// /// Deletes a key inside a . /// /// Represents the section in which the data is stored. /// Represents the key to be deleted. void DeleteKey(string section, string key); /// /// Deletes a section with all its keys. /// /// Represents the section to be deleted. void DeleteSection(string section); } }