Beispiel #1
0
 /// <summary>
 /// Ctor is based on single line from the fed's text report
 /// </summary>
 /// <param name="li"></param>
 internal Bank(dynamic li)
 {
     const string COMMA = ",";
     const string LETTER_Y = "Y";
     UpsertName(KindsOfNames.Legal, li.BankName);
     UpsertName(KindsOfNames.Abbrev, li.BankName);
     Rssd = new ResearchStatisticsSupervisionDiscount { Value = li.BankId };
     UsCityStateZip cityOut;
     if (UsCityStateZip.TryParse(li.Location, out cityOut))
         BusinessAddress = new Tuple<UsStreetPo, UsCityStateZip>(null, cityOut);
     if (FedLrgBnk.TypeOfBankAbbrev3Enum.ContainsKey(li.Chtr))
         BankType = FedLrgBnk.TypeOfBankAbbrev3Enum[li.Chtr];
     var assets = new FinancialAssets { Src = FedLrgBnk.RELEASE_URL };
     decimal conAssts = 0;
     decimal domAssts = 0;
     if (decimal.TryParse(li.ConsolAssets.Replace(COMMA, string.Empty), out conAssts))
         assets.TotalAssets = new Pecuniam(conAssts * ONE_THOUSAND);
     if (decimal.TryParse(li.DomesticAssets.Replace(COMMA, string.Empty), out domAssts))
         assets.DomesticAssets = new Pecuniam(domAssts * ONE_THOUSAND);
     int domBranches = 0;
     int frnBranches = 0;
     int pfo = 0;
     if (int.TryParse(li.NumOfDomBranches.Replace(COMMA, string.Empty), out domBranches))
         assets.DomesticBranches = domBranches;
     if (int.TryParse(li.NumOfFgnBranches.Replace(COMMA, string.Empty), out frnBranches))
         assets.ForeignBranches = frnBranches;
     IsInternational = li.Ibf == LETTER_Y;
     if (int.TryParse(li.PercentFgnOwned, out pfo))
         assets.PercentForeignOwned = Math.Round((double)pfo / 100, 2);
     Assets = new Dictionary<DateTime, FinancialAssets> { { li.RptDate, assets } };
 }
Beispiel #2
0
 /// <summary>
 /// This will produce a URI which upon being requested from FFIEC will return html in 
 /// which the <see cref="rssd"/> will map to an official name.  This name will
 /// produce results when used in SEC queries.
 /// </summary>
 /// <param name="rssd"></param>
 /// <returns></returns>
 public static Uri GetUri(ResearchStatisticsSupervisionDiscount rssd)
 {
     return new Uri(Ffiec.SEARCH_URL_BASE + "InstitutionProfile.aspx?parID_Rssd=" + rssd + "&parDT_END=99991231");
 }
Beispiel #3
0
 /// <summary>
 /// This will produce a URI which upon being requested from FFIEC will return html in
 /// which the <see cref="rssd"/> will map to an official name.  This name will
 /// produce results when used in SEC queries.
 /// </summary>
 /// <param name="rssd"></param>
 /// <returns></returns>
 public static Uri GetUri(ResearchStatisticsSupervisionDiscount rssd)
 {
     return(new Uri(UsGov.Links.Ffiec.SEARCH_URL_BASE + "InstitutionProfile.aspx?parID_Rssd=" + rssd + "&parDT_END=99991231"));
 }