//public TestPointTreeModel(string name, string sn, Guid id) // : base(name) //{ // TestPointId = id; // IsExpanded = false; // MSSN = new BindableValue<string>(sn); // InitializeLocation(); //} //public TestPointTreeModel(string name, string sn) // : this(name, sn, Guid.NewGuid()) //{ //} public TestPointTreeModel(TestPoint tp) : base(tp.Name) { TestPoint = tp; IsExpanded = false; MSSN = new BindableValue <string>(TestPoint.MSSN); if (!string.IsNullOrEmpty(TestPoint.IP) && !string.IsNullOrEmpty(TestPoint.CardNum) && !string.IsNullOrEmpty(TestPoint.ChannelNum)) { ChannelId = ChannelIdentity.Create(TestPoint.IP, TestPoint.CardNum, TestPoint.ChannelNum).Value; } InitializeLocation(); }
public ChannelTreeModel(ChannelIdentity channelId) : base("Channel") { IsExpanded = true; ChannelId = channelId; }
public void Bind(ChannelIdentity id) { ChannelId = id; OnPropertyChanged(nameof(IsPaired)); }