Dot notation for hierarchical related string values
<p>I have a lot of constant string values in my application which I want to have as strongly typed objects in C# for code reuse and readability. I would like to be able to reference the string value like so:</p>

<pre><code>Category.MyCategory  //returns a string value ie “My Category”
Category.MyCategory.Type.Private //returns a string value ie “private”
Category.MyCategory.Type.Shared //returns a string value ie “shared”
</code></pre>

<p>I have started by implementing the following classes each containing a list of public string valued fields with a public property which exposes the child.</p>

<p>Category, MyCategory, Type</p>

<p>However I already know this is not the way to go so could do with a bit of advice on this one.</p>

<p>An example of this is where I am using the Syndication classes to add a category to an atom feed. I am creating the items in this feed dynamically so need to use the notation as shown.</p>

<pre><code>item.Categories.Add( new SyndicationCategory
                 {
                     Scheme = Category.PersonType, 
                     Label="My Category",
                     Name=Category.MyCategory.Type.Private  
                 });
</code></pre>
