WIP
DirectOutput framework for virtual pinball cabinets WIP
Go to:
Overview 
VariablesDictionary.cs
Go to the documentation of this file.
1 using System;
2 using System.Collections.Generic;
3 using System.Linq;
4 using System.Text;
5 
6 namespace DirectOutput.LedControl.Loader
7 {
8  public class VariablesDictionary: Dictionary<string,string>
9  {
10 
11 
12 
13  public VariablesDictionary() { }
14 
15  public VariablesDictionary(List<string> DataToParse)
16  {
17  foreach (string D in DataToParse)
18  {
19  int P = D.IndexOf("=");
20  if (P > 0)
21  {
22  Add(D.Substring(0,P).Trim(),D.Substring(P+1).Trim());
23  }
24  else
25  {
26  Log.Warning("Could not find = in variables section line {0}.".Build(D));
27  }
28  }
29  }
30  }
31 }
static void Warning(string Message)
Writes a warning message to the log.
Definition: Log.cs:134
A simple logger used to record important events and exceptions.
Definition: Log.cs:14