annotate IniCommentLine.cs @ 13:ee9f11c67399 default tip

* Correct version number pattern no-open-ticket
author IBBoard <dev@ibboard.co.uk>
date Mon, 28 Feb 2011 20:22:41 +0000
parents f6f726c92e56
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
1 // This file (IniCommentLine.cs) is a part of the IBBoard.Ini library and is copyright 2009 IBBoard.
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
2 //
6
f6f726c92e56 Re #8 - License code
IBBoard <dev@ibboard.co.uk>
parents: 1
diff changeset
3 // The file and the library/program it is in are licensed under the GNU LGPL license, either version 3 of the License or (at your option) any later version. Please see COPYING.LGPL for more information and the full license.
1
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
4
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
5 using System;
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
6
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
7 namespace IBBoard.Ini
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
8 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
9 /// <summary>
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
10 /// A line in an IniFile that contains a comment
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
11 /// </summary>
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
12 public class IniCommentLine : IIniLine
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
13 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
14 private string comment;
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
15
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
16 public IniCommentLine(string comment)
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
17 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
18 this.comment = comment.TrimStart(';');
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
19 }
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
20
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
21 //// <value>
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
22 /// Gets the content of the comment
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
23 /// </value>
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
24 public string Comment
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
25 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
26 get
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
27 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
28 return comment;
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
29 }
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
30 }
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
31
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
32 public override string ToString()
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
33 {
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
34 return ";" + Comment;
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
35 }
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
36
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
37 }
f9444f1786cd Re #6 - INI parsing library
IBBoard <dev@ibboard.co.uk>
parents:
diff changeset
38 }