public void Update(stcondition element) { if (element.m_allowschedules.HasValue == true) { this.allowschedules = element.allowschedules; } if (element.m_chdir.HasValue == true) { this.chdir = element.chdir; } if (element.m_commuter.HasValue == true) { this.commuter = element.commuter; } if (element.m_notprevbk.HasValue == true) { this.notprevbk = element.notprevbk; } if (element.m_prevbkid != null) { this.prevbkid = element.prevbkid; } if (element.m_type != null) { this.type = element.type; } }
public static stcondition Parse(System.Xml.Linq.XElement xml, CRocrailClient rocrailClient) { stcondition _stcondition = new stcondition(); _stcondition.m_rocrailClient = rocrailClient; _stcondition.m_allowschedules = (bool?)xml.Attribute("allowschedules"); _stcondition.m_chdir = (bool?)xml.Attribute("chdir"); _stcondition.m_commuter = (bool?)xml.Attribute("commuter"); _stcondition.m_notprevbk = (bool?)xml.Attribute("notprevbk"); _stcondition.m_prevbkid = (string)xml.Attribute("prevbkid"); _stcondition.m_type = (string)xml.Attribute("type"); return(_stcondition); }