public SwapStream(XmlNode xmlNode) : base(xmlNode) { XmlNode calculationAmountNode = xmlNode.SelectSingleNode("calculationAmount"); if (calculationAmountNode != null) { if (calculationAmountNode.Attributes["href"] != null || calculationAmountNode.Attributes["id"] != null) { if (calculationAmountNode.Attributes["id"] != null) { calculationAmountIDRef_ = calculationAmountNode.Attributes["id"].Value; CalculationAmount ob = new CalculationAmount(calculationAmountNode); IDManager.SetID(calculationAmountIDRef_, ob); } else if (calculationAmountNode.Attributes["href"] != null) { calculationAmountIDRef_ = calculationAmountNode.Attributes["href"].Value; } else { calculationAmount_ = new CalculationAmount(calculationAmountNode); } } else { calculationAmount_ = new CalculationAmount(calculationAmountNode); } } XmlNode irCalculationNode = xmlNode.SelectSingleNode("irCalculation"); if (irCalculationNode != null) { if (irCalculationNode.Attributes["href"] != null || irCalculationNode.Attributes["id"] != null) { if (irCalculationNode.Attributes["id"] != null) { irCalculationIDRef_ = irCalculationNode.Attributes["id"].Value; IRCalculation ob = new IRCalculation(irCalculationNode); IDManager.SetID(irCalculationIDRef_, ob); } else if (irCalculationNode.Attributes["href"] != null) { irCalculationIDRef_ = irCalculationNode.Attributes["href"].Value; } else { irCalculation_ = new IRCalculation(irCalculationNode); } } else { irCalculation_ = new IRCalculation(irCalculationNode); } } }