public static srcpcon Parse(System.Xml.Linq.XElement xml, CRocrailClient rocrailClient) { srcpcon _srcpcon = new srcpcon(); _srcpcon.m_rocrailClient = rocrailClient; _srcpcon.m_active = (bool?)xml.Attribute("active"); _srcpcon.m_device = (string)xml.Attribute("device"); _srcpcon.m_maxcon = (int?)xml.Attribute("maxcon"); _srcpcon.m_port = (int?)xml.Attribute("port"); Definitions.Tools.ParseList <srcpbus>(_srcpcon.m_srcpbuslist, xml, "srcpbus", srcpbus.Parse, rocrailClient); return(_srcpcon); }
public void Update(srcpcon element) { if (element.m_active.HasValue == true) { this.active = element.active; } if (element.m_device != null) { this.device = element.device; } if (element.m_maxcon.HasValue == true) { this.maxcon = element.maxcon; } if (element.m_port.HasValue == true) { this.port = element.port; } this.srcpbuslist = element.srcpbuslist; }