public Alarm(Alarm rhs)
 {
     State           = rhs.State;
     Key             = rhs.Key;
     _events         = rhs._events.Select(x => (Event)x.Clone()).ToHashSet();
     _eventIdHistory = rhs._eventIdHistory.ToList();
 }
 public Alarm(Event evt)
 {
     State   = AlarmState.New;
     Key     = evt.LinkedTo;
     _events = new HashSet <Event> {
         evt
     };
 }
 public ShortView(Guid id, AlarmState state, EventLinkKey key)
 {
     Id    = id;
     State = state;
     Key   = key;
 }
 public virtual bool Remove(EventLinkKey key) => _alarms.Remove(key);
 public virtual void Add(EventLinkKey key, Alarm value) => _alarms.Add(key, value);
 public virtual bool TryGetValue(EventLinkKey key, out Alarm value) => _alarms.TryGetValue(key, out value);
Esempio n. 7
0
 public Event(Event rhs)
 {
     Id        = rhs.Id;
     LinkedTo  = rhs.LinkedTo;
     completed = rhs.completed;
 }