当前位置: 首页>>代码示例>>C#>>正文


C# Element.GetElementAsFloat64方法代码示例

本文整理汇总了C#中Element.GetElementAsFloat64方法的典型用法代码示例。如果您正苦于以下问题:C# Element.GetElementAsFloat64方法的具体用法?C# Element.GetElementAsFloat64怎么用?C# Element.GetElementAsFloat64使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Element的用法示例。


在下文中一共展示了Element.GetElementAsFloat64方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: ParseEquity

 public void ParseEquity(Element fieldData)
 {
     string tenor = fieldData.GetElementAsString("ID_BB_SEC_NUM_DES");
     double px_mid = fieldData.GetElementAsFloat64("PRIOR_CLOSE_MID");
     tenor = tenor.Replace(isin,"");
     pointsCourbe.Add(TenorToDate(tenor), px_mid);
 }
开发者ID:TigerSCR,项目名称:TigerAppWPF,代码行数:7,代码来源:CourbeSwap.cs

示例2: InsertData

 private static void InsertData(Element fieldData, String ticker)
 {
     if (IsValid(fieldData))
     {
         using (var context = new EFMMDataClassesDataContext())
         {
             context.insertBloombergDownload(fieldData.GetElementAsDate(DATE).ToDateId()
                 , (decimal)fieldData.GetElementAsFloat64(PX_LAST)
                 , fieldData.GetElementAsInt64(VWAP_VOLUME)
                 , fieldData.GetElementAsInt64(VWAP_LIT_VOLUME)
                 , ticker);
             context.SubmitChanges();
         }
     }
     else
     {
         Logger.WarnFormat("At least one field missing for [{0}]", ticker);
     }
 }
开发者ID:jbontik,项目名称:bloomberg_downloader,代码行数:19,代码来源:Program.cs

示例3: ParseGovt

        private static void ParseGovt(Element fieldData, string security)
        {
            Govt govt;
            try
            {
                string country = fieldData.GetElementAsString("COUNTRY_ISO");
                double px_last = fieldData.GetElementAsFloat64("PX_LAST");
                string currency = fieldData.GetElementAsString("DDIS_CURRENCY");
                string name = fieldData.GetElementAsString("NAME");
                int id_Mcorp = fieldData.GetElementAsInt32("ID_BB_ULTIMATE_PARENT_CO");
                string name_Mcorp = fieldData.GetElementAsString("ID_BB_ULTIMATE_PARENT_CO_NAME");
                double duration = fieldData.GetElementAsFloat64("YAS_MOD_DUR");
                string maturity = fieldData.GetElementAsString("MATURITY");

                string date_cpn = fieldData.GetElementAsString("NXT_CPN_DT");
                int nb_day_nxt_cpn = fieldData.GetElementAsInt32("DAYS_TO_NEXT_COUPON");
                double cpn = fieldData.GetElementAsFloat64("CPN");
                int cpn_freq = fieldData.GetElementAsInt32("CPN_FREQ");

                int rating = Rating.GetQuality(fieldData);

                govt = new Govt(security, d_title[security].Item1, country, currency, name, px_last, id_Mcorp, name_Mcorp, rating, d_title[security].Item2,date_cpn, maturity, duration, cpn, cpn_freq, nb_day_nxt_cpn);
            }
            catch (NotFoundException e)
            {
                govt = new Govt(security, d_title[security].Item1, d_title[security].Item2, e.Description());
            }
            l_title.Add(govt);
        }
开发者ID:TigerSCR,项目名称:TigerAppWPF,代码行数:29,代码来源:Connector.cs

示例4: ParseEquity

        private static void ParseEquity(Element fieldData, string security)
        {
            Equity equit;
            try
            {
                string country = fieldData.GetElementAsString("COUNTRY_ISO");
                double px_last = fieldData.GetElementAsFloat64("PX_LAST");
                string currency = fieldData.GetElementAsString("DDIS_CURRENCY");
                string name = fieldData.GetElementAsString("NAME");
                int id_Mcorp = fieldData.GetElementAsInt32("ID_BB_ULTIMATE_PARENT_CO");
                string name_Mcorp = fieldData.GetElementAsString("ID_BB_ULTIMATE_PARENT_CO_NAME");

                int rating = Rating.GetQuality(fieldData);

                equit = new Equity(security, d_title[security].Item1, country, currency, name, px_last, id_Mcorp, name_Mcorp,rating);
            }
            catch (NotFoundException e)
            {
                equit = new Equity(security, d_title[security].Item1, e.Description());
            }
            l_title.Add(equit);
        }
开发者ID:TigerSCR,项目名称:TigerAppWPF,代码行数:22,代码来源:Connector.cs

示例5: ParseGovt

        private static void ParseGovt(Element fieldData, string security)
        {
            /*valeur actuel = qt* nominale*/
            Govt govt;
            string name = "";
            try
            {
                name = fieldData.GetElementAsString("NAME");
                string maturity = fieldData.GetElementAsString("MATURITY");
                if (Convert.ToDateTime(maturity) > DateTime.Now)
                {
                    string country = fieldData.GetElementAsString("COUNTRY_ISO");
                    double px_last = fieldData.GetElementAsFloat64("PX_LAST");
                    string currency = fieldData.GetElementAsString("DDIS_CURRENCY");
                    int id_Mcorp = fieldData.GetElementAsInt32("ID_BB_ULTIMATE_PARENT_CO");
                    string name_Mcorp = fieldData.GetElementAsString("ID_BB_ULTIMATE_PARENT_CO_NAME");
                    double duration = fieldData.GetElementAsFloat64("YAS_MOD_DUR");

                    string date_cpn = fieldData.GetElementAsString("NXT_CPN_DT");
                    int nb_day_nxt_cpn = fieldData.GetElementAsInt32("DAYS_TO_NEXT_COUPON");
                    double cpn = fieldData.GetElementAsFloat64("CPN");
                    int cpn_freq = fieldData.GetElementAsInt32("CPN_FREQ");
                    double px_emit = fieldData.GetElementAsFloat64("WORKOUT_PX_BID");

                    int rating = Rating.GetQuality(fieldData);
                    govt = new Govt(security, d_title[security].Item1, country, currency, name, px_last, id_Mcorp, name_Mcorp, rating, d_title[security].Item2, date_cpn, maturity, duration, cpn, cpn_freq, nb_day_nxt_cpn, px_emit);

                    l_title.Add(govt);
                }
                else
                {
                    govt = new Govt(security,name, d_title[security].Item1, d_title[security].Item2, "Obligation ECHU, maturity : " + maturity);
                    l_err.Add(govt);
                }
            }
            catch (NotFoundException e)
            {
                govt = new Govt(security,name, d_title[security].Item1, d_title[security].Item2, e.Description());
                l_err.Add(govt);
            }
        }
开发者ID:RomainDAV,项目名称:TigerAppWPF,代码行数:41,代码来源:Connector.cs

示例6: ParseChange

 private static void ParseChange(Element fieldData, string security)
 {
     security = security.Replace(" CURNCY","");
     security = security.Replace(devise,"");
     d_change.Add(security,fieldData.GetElementAsFloat64("PX_LAST"));
 }
开发者ID:RomainDAV,项目名称:TigerAppWPF,代码行数:6,代码来源:Connector.cs

示例7: ParseEquity

        private static void ParseEquity(Element fieldData, string security)
        {
            string country = fieldData.GetElementAsString("COUNTRY_ISO");
            double px_last = fieldData.GetElementAsFloat64("PX_LAST");
            string currency = fieldData.GetElementAsString("CRNCY");
            string name = fieldData.GetElementAsString("NAME");

            Equity equit = new Equity(security, d_title[security].Item1, country, currency, name, px_last);
            l_title.Add(equit);
        }
开发者ID:TigerSCR,项目名称:tigerscr,代码行数:10,代码来源:Connector.cs


注:本文中的Element.GetElementAsFloat64方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。