Example #1
0
        public override void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
        {
            FpmlSerializedCSharp.InstrumentInfo   serial_instInfo         = serial_Class as FpmlSerializedCSharp.InstrumentInfo;
            FpmlSerializedCSharp.CreditInstrument serial_CreditInstrument = serial_instInfo.CreditInstrument_ as FpmlSerializedCSharp.CreditInstrument;

            FpmlSerializedCSharp.IssueInformation serial_issueInfo = serial_CreditInstrument.IssueInformation_;
            string issueInfotype = serial_issueInfo.Type_.ValueStr;

            this.issueInfoViewModel_ = IssueInformationViewModel.CreateIssueInformation(issueInfotype);
            this.issueInfoViewModel_.setFromSerial(serial_issueInfo);

            FpmlSerializedCSharp.UnderlyingInformation serial_underlyingInfo = serial_CreditInstrument.UnderlyingInformation_;
            string underlyingInfotype = serial_underlyingInfo.Type_.ValueStr;

            this.underlyingInfoViewModel_ = UnderlyingInfoViewModel.CreateUnderlyingInfo(underlyingInfotype);
            this.underlyingInfoViewModel_.setFromSerial(serial_underlyingInfo);

            FpmlSerializedCSharp.CreditPayoffInfo serial_creditPayoffInfo = serial_CreditInstrument.CreditPayoffInfo_;
            string creditPayoffInfotype = serial_creditPayoffInfo.Type_.ValueStr;

            this.creditPayoffInfoViewModel_ = CreditPayoffInfoViewModel.CreateCreditPayoffInfo(creditPayoffInfotype);
            this.creditPayoffInfoViewModel_.setFromSerial(serial_creditPayoffInfo);

            this.view_             = new CreditInstrumentView();
            this.view_.DataContext = this;
        }
        public void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
        {
            FpmlSerializedCSharp.CreditInstrument serial_CreditInstrument = serial_Class as FpmlSerializedCSharp.CreditInstrument;

            FpmlSerializedCSharp.IssueInformation serial_issueInformation = serial_CreditInstrument.IssueInformation_;
            string issueInformationtype = serial_issueInformation.Excel_type_.ValueStr;

            this.issueInformationViewModel_ = IssueInformationViewModel.CreateIssueInformation(issueInformationtype);
            this.issueInformationViewModel_.setFromSerial(serial_issueInformation);

            FpmlSerializedCSharp.UnderlyingInformation serial_underlyingInformation = serial_CreditInstrument.UnderlyingInformation_;
            string underlyingInformationtype = serial_underlyingInformation.Excel_type_.ValueStr;

            this.underlyingInformationViewModel_ = UnderlyingInformationViewModel.CreateUnderlyingInformation(underlyingInformationtype);
            this.underlyingInformationViewModel_.setFromSerial(serial_underlyingInformation);

            FpmlSerializedCSharp.CreditPayoffInfo serial_creditPayoffInfo = serial_CreditInstrument.CreditPayoffInfo_;
            string creditPayoffInfotype = serial_creditPayoffInfo.Excel_type_.ValueStr;

            this.creditPayoffInfoViewModel_ = CreditPayoffInfoViewModel.CreateCreditPayoffInfo(creditPayoffInfotype);
            this.creditPayoffInfoViewModel_.setFromSerial(serial_creditPayoffInfo);
        }