Esempio n. 1
0
        public void Add(ComputerData computerData)
        {
            var history = computerDataHistories.FirstOrDefault(p => p.ComputerName == computerData.ComputerName);

            if (history != null && history.ComputerName == computerData.ComputerName)
            {
                var historyElement = new ComputerDataHistoryElement(computerData);
                history.Add(historyElement);
            }
            else
            {
                var newHistory     = new ComputerDataHistory(computerData.ComputerName);
                var historyElement = new ComputerDataHistoryElement(computerData);
                newHistory.Add(historyElement);
                computerDataHistories.Add(newHistory);
            }
        }
Esempio n. 2
0
 public Details(ComputerDataHistory _history)
 {
     InitializeComponent();
     history = _history;
 }