void CheckArguments(string username, string sectionName, string subSectionName, object settings) { _userName = username; _sectionName = sectionName; _subSectionName = subSectionName; if (_ReadWriteProvider == null) { throw new InvalidOperationException("ReadWriteProvider must be set."); } if (Hlp.IsNullOrWhiteSpace(sectionName)) { throw new ArgumentException("Section's name must be set."); } if (Hlp.IsNullOrWhiteSpace(subSectionName)) { throw new ArgumentException("Subsection's name must be set."); } if (settings == null) { throw new ArgumentNullException("Setting class can not be null."); } }