示例#1
0
        private void ViewModelChanged(object sender, DependencyPropertyChangedEventArgs e)
        {
            this.viewModel_ = this.DataContext as Excel_hifiveViewModel;

            //this.viewModel_.Excel_hifive_subtypeViewModel_.PropertyChanged += new System.ComponentModel.PropertyChangedEventHandler(viewModel__PropertyChanged);

            //this.IssueInfoGrid_.Children.Clear();
            this.IssueInfoGrid_.Children.Add(this.viewModel_.Excel_issueInfoViewModel_.view());
            this.UnderlyingInfoGrid_.Children.Add(this.viewModel_.Excel_underlyingCalcInfoViewModel_.view());

            // 여기는 itemsource 에 더해야함 list임
            //this.UnderlyingCalcGrid_.Children.Add(this.viewModel_.Excel_underlyingCalcIDViewModel_.View_);

            // 이건 선택해서 할거임 . default로 뭘 넣나..?
            // 우선은 default로 stepDownki을 넣자

            //this.SubTypeGrid_.Children.Add(this.viewModel_.Excel_hifive_subtypeViewModel_.View_);

            this.ScheduleGrid_.Children.Add(this.viewModel_.Excel_scheduleListViewModel_.view());

            //Excel_kiEventCalculationLoaderView e_keclv = new Excel_kiEventCalculationLoaderView();
            Excel_kiEventCalculationLoaderView e_keclv = this.viewModel_.Excel_kiEventCalculationViewModel_.loaderView() as Excel_kiEventCalculationLoaderView;

            this.kiEventCalculationGrid_.Children.Add(e_keclv);

            //this.KiScheduleGrid_.Children.Add(this.viewModel_.Excel_kiScheduleListViewModel_.view());

            // para가 없으면 만듬
            //this.paraViewModel_ = new Excel_standardParaViewModel();

            //this.viewModel_.Excel_underlyingCalcInfoViewModel_.PropertyChanged +=
            //    new System.ComponentModel.PropertyChangedEventHandler(this.paraViewModel_.T
        }
        private void ViewModelChanged(object sender, DependencyPropertyChangedEventArgs e)
        {
            this.viewModel_ = this.DataContext as Excel_hifiveViewModel;
            
            //this.viewModel_.Excel_hifive_subtypeViewModel_.PropertyChanged += new System.ComponentModel.PropertyChangedEventHandler(viewModel__PropertyChanged);

            //this.IssueInfoGrid_.Children.Clear();
            this.IssueInfoGrid_.Children.Add(this.viewModel_.Excel_issueInfoViewModel_.view());
            this.UnderlyingInfoGrid_.Children.Add(this.viewModel_.Excel_underlyingCalcInfoViewModel_.view());

            // 여기는 itemsource 에 더해야함 list임
            //this.UnderlyingCalcGrid_.Children.Add(this.viewModel_.Excel_underlyingCalcIDViewModel_.View_);

            // 이건 선택해서 할거임 . default로 뭘 넣나..?
            // 우선은 default로 stepDownki을 넣자

            //this.SubTypeGrid_.Children.Add(this.viewModel_.Excel_hifive_subtypeViewModel_.View_);

            this.ScheduleGrid_.Children.Add(this.viewModel_.Excel_scheduleListViewModel_.view());

            //Excel_kiEventCalculationLoaderView e_keclv = new Excel_kiEventCalculationLoaderView();
            Excel_kiEventCalculationLoaderView e_keclv = this.viewModel_.Excel_kiEventCalculationViewModel_.loaderView() as Excel_kiEventCalculationLoaderView;

            this.kiEventCalculationGrid_.Children.Add(e_keclv);

            //this.KiScheduleGrid_.Children.Add(this.viewModel_.Excel_kiScheduleListViewModel_.view());

            // para가 없으면 만듬
            //this.paraViewModel_ = new Excel_standardParaViewModel();

            //this.viewModel_.Excel_underlyingCalcInfoViewModel_.PropertyChanged += 
            //    new System.ComponentModel.PropertyChangedEventHandler(this.paraViewModel_.T

        }
        public override void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
        {
            FpmlSerializedCSharp.Excel_swapLeg serial_Excel_swapLeg = serial_Class as FpmlSerializedCSharp.Excel_swapLeg;
            FpmlSerializedCSharp.Excel_hifiveSwapLeg serial_Excel_hifiveSwapLeg = serial_Excel_swapLeg.Excel_hifiveSwapLeg_;
        
            //FpmlSerializedCSharp.Excel_swapLegInfo serial_excel_swapLegInfo = serial_Excel_hifiveSwapLeg.Excel_swapLegInfo_;
            ////string excel_swapLegInfotype = serial_excel_swapLegInfo.Excel_type_.ValueStr;
            //this.excel_swapLegInfoViewModel_ = new Excel_swapLegInfoViewModel();
            //this.excel_swapLegInfoViewModel_.setFromSerial(serial_excel_swapLegInfo);

            FpmlSerializedCSharp.Excel_interface serial_excel_interface = serial_Excel_hifiveSwapLeg.Excel_interface_;
            //string excel_hifivetype = serial_excel_hifive.Excel_type_.ValueStr;
            this.excel_hifiveViewModel_ = new Excel_hifiveViewModel();
            this.excel_hifiveViewModel_.setFromSerial(serial_excel_interface);
            
        }
示例#4
0
        public override void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
        {
            FpmlSerializedCSharp.Excel_swapLeg       serial_Excel_swapLeg       = serial_Class as FpmlSerializedCSharp.Excel_swapLeg;
            FpmlSerializedCSharp.Excel_hifiveSwapLeg serial_Excel_hifiveSwapLeg = serial_Excel_swapLeg.Excel_hifiveSwapLeg_;

            FpmlSerializedCSharp.Excel_swapLegInfo serial_excel_swapLegInfo = serial_Excel_hifiveSwapLeg.Excel_swapLegInfo_;
            string excel_swapLegInfotype = serial_excel_swapLegInfo.Excel_type_.ValueStr;

            this.excel_swapLegInfoViewModel_ = Excel_swapLegInfoViewModel.CreateExcel_swapLegInfo(excel_swapLegInfotype);
            this.excel_swapLegInfoViewModel_.setFromSerial(serial_excel_swapLegInfo);

            FpmlSerializedCSharp.Excel_hifive serial_excel_hifive = serial_Excel_hifiveSwapLeg.Excel_hifive_;
            string excel_hifivetype = serial_excel_hifive.Excel_type_.ValueStr;

            this.excel_hifiveViewModel_ = Excel_hifiveViewModel.CreateExcel_hifive(excel_hifivetype);
            this.excel_hifiveViewModel_.setFromSerial(serial_excel_hifive);
        }
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            Excel_Interface.Excel_hifiveViewModel e_hvm = new Excel_Interface.Excel_hifiveViewModel();

            Window w = new Window();
            w.Width = 400;
            w.Height = 300;
            w.Content = e_hvm.view();
            w.Visibility = 0;

            //e_hvm.buildHifive();

            //string kk = e_hvm.testString();

            //Console.Write(kk);

            //System.IO.File.WriteAllText("testResult.xml", kk);

            //MessageBoxResult result = MessageBox.Show(kk);
        }
        //public override string productStringGenerate()
        //{
        //    StringBuilder sb = new StringBuilder();

        //    sb.Append("Type = 2 Stock Step Down Double Callable;");

        //    string unders = this.excel_underlyingCalcInfoViewModel_.getUnderlyingString();

        //    sb.Append("Underlyings=" + unders + ";");
        //    sb.Append("Tenor=" + this.maturity_ + ";");
        //    sb.Append("Observation period=" + this.couponTenor_ + ";");

        //    sb.Append("Trigger level=;");

        //    sb.Append("Knock In barrier=;");
        //    sb.Append("Coupon(p.a)=11.3;");
        //    sb.Append("EffectiveDate=2013-07-08;");
        //    sb.Append("ExportCode=50507A3709S0;");
        //    sb.Append("Notional=300000000;");
        //    sb.Append("Name=IBK 제882회 사모ELS;");

            

        //    return sb.ToString();
        //}


        public override void DefaultSetting(Excel_hifiveViewModel e_hvm)
        {
            this.Coupon_ = "4.0";
            this.CouponTenor_ = "6m";
            this.Maturity_ = "3y";

            this.Ki_ = "55.0";

            this.KiObStartDate_ = e_hvm.Excel_issueInfoViewModel_.EffectiveDate_;
            this.KiObEndDate_ = e_hvm.Excel_issueInfoViewModel_.MaturityDate_;
        }
 public override void DefaultSetting(Excel_hifiveViewModel e_hvm)
 {
     throw new NotImplementedException();
 }
 public override void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
 {
     FpmlSerializedCSharp.Excel_swapLeg serial_Excel_swapLeg = serial_Class as FpmlSerializedCSharp.Excel_swapLeg;
     FpmlSerializedCSharp.Excel_hifiveSwapLeg serial_Excel_hifiveSwapLeg = serial_Excel_swapLeg.Excel_hifiveSwapLeg_;
 
     FpmlSerializedCSharp.Excel_swapLegInfo serial_excel_swapLegInfo = serial_Excel_hifiveSwapLeg.Excel_swapLegInfo_;
     string excel_swapLegInfotype = serial_excel_swapLegInfo.Excel_type_.ValueStr;
     this.excel_swapLegInfoViewModel_ = Excel_swapLegInfoViewModel.CreateExcel_swapLegInfo(excel_swapLegInfotype);
     this.excel_swapLegInfoViewModel_.setFromSerial(serial_excel_swapLegInfo);
     
     FpmlSerializedCSharp.Excel_hifive serial_excel_hifive = serial_Excel_hifiveSwapLeg.Excel_hifive_;
     string excel_hifivetype = serial_excel_hifive.Excel_type_.ValueStr;
     this.excel_hifiveViewModel_ = Excel_hifiveViewModel.CreateExcel_hifive(excel_hifivetype);
     this.excel_hifiveViewModel_.setFromSerial(serial_excel_hifive);
     
 }
 public abstract void DefaultSetting(Excel_hifiveViewModel e_hvm);
示例#10
0
 public abstract void DefaultSetting(Excel_hifiveViewModel e_hvm);