Mercurial > repos > IBBoard.Ini
diff DuplicateIniSectionException.cs @ 4:01fc09ab63e2
Re #7 - Add tests for INI parsing
* Add DuplicateIniSectionException to make exception cause more obvious
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Sun, 18 Jan 2009 14:29:52 +0000 |
parents | |
children | f6f726c92e56 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/DuplicateIniSectionException.cs Sun Jan 18 14:29:52 2009 +0000 @@ -0,0 +1,18 @@ +// This file (DuplicateIniSectionException.cs) is a part of the IBBoard.Ini library and is copyright 2009 IBBoard. +// +// The file and the library/program it is in are licensed under the GNU LGPL license. Please see COPYING.LGPL for more information and the full license. + +using System; + +namespace IBBoard.Ini +{ + /// <summary> + /// An exception that indicates that a second IniSection has been added to an IniFile with the same name as a section already in the IniFile + /// </summary> + public class DuplicateIniSectionException : ArgumentException + { + public DuplicateIniSectionException(string sectionName) : base("The INI file already contained a section called ["+sectionName+"]") + { + } + } +}