title: Designing c# class from json template
body: <p>I have to design a class based on a json template that i received. I'm stuck at this part of the json:</p>
  
  <pre><code>events: {
      "door": [
          5,
          {
              valueone: 27,
              valuetwo: "something"
          }
      ],
      "window": [
          2,
          {
              valueone: 13,
              valuetwo: "something"
          }
      ]
  }
  </code></pre>
  
  <p>The best i can come up with is this property in the root object:</p>
  
  <pre><code>public Dictionary&lt;string, EventData&gt; Events { get; set; }
  </code></pre>
  
  <p>Where Events is defined like this:</p>
  
  <pre><code>public class EventData
  {
      public int valueone { get; set; }
      public string valuetwo { get; set; }
  }
  </code></pre>
  
  <p>This gives me for example the following output:</p>
  
  <pre><code>Events: {
      door: {
          valueone: 27,
          valuetwo: "something"
      }
  }
  </code></pre>
  
  <p>But i have no idea how to design the class to get the numbers in the json example (5 and 2) in the output. I have tried to google for this for a long time today but i'm not quite sure what to search for.</p>