Class SepaBankInfos
Container that holds the bank informations for a particular country.
public class SepaBankInfos : IEnumerable<SepaBankInfo>, IEnumerable
- Inheritance
-
SepaBankInfos
- Implements
- Inherited Members
Constructors
SepaBankInfos(string, List<SepaBankInfo>)
public SepaBankInfos(string sCountryCode, List<SepaBankInfo> vBankInfos)
Parameters
sCountryCode
stringThe country for which this container holds the bank informations.
vBankInfos
List<SepaBankInfo>
Fields
CSVHEADER_BANKCODE
public const string CSVHEADER_BANKCODE = "BankCode"
Field Value
CSVHEADER_BANKNAME
public const string CSVHEADER_BANKNAME = "BankName"
Field Value
CSVHEADER_BIC
public const string CSVHEADER_BIC = "BIC"
Field Value
Properties
Count
public int Count { get; }
Property Value
CountryCode
public string CountryCode { get; }
Property Value
IBANSpec
public SepaIBANSpec IBANSpec { get; }
Property Value
this[int]
public SepaBankInfo this[int i] { get; }
Parameters
i
int
Property Value
Methods
DetermineBIC(string)
public SepaBIC DetermineBIC(string sBankCode)
Parameters
sBankCode
stringThe bank code for which to determine the BIC. This must not be
null
or an empty string.
Returns
- SepaBIC
If the bank code was found, then its BIC is returned. If the bank code is not known, then NullBIC is returned.
DetermineBankName(string)
public string DetermineBankName(string sBankCode)
Parameters
sBankCode
stringThe bank code for which to determine the bank name. This must not be
null
or an empty string.
Returns
- string
If the bank code was found, and a bank name is known for it, then it is returned. If the bank code is not known, or no name for the bank is known, then
null
is returned.
FindBankInfo(string)
public SepaBankInfo FindBankInfo(string sBankCode)
Parameters
sBankCode
stringThe bank identification code. Must not be
null
.
Returns
- SepaBankInfo
If the given bank code is not found in the table, then this method returns
null
. If the bank code is contained, then its SepaBankInfo is returned.
Exceptions
- ArgumentNullException
The parameter
sBankCode
wasnull
.- ArgumentException
LoadBankInfosCsv(string, Stream)
public static SepaBankInfos LoadBankInfosCsv(string sCountryCode, Stream aStream)
Parameters
Returns
LoadBankInfosCsv(string, TextReader)
public static SepaBankInfos LoadBankInfosCsv(string sCountryCode, TextReader aReader)
Parameters
sCountryCode
stringaReader
TextReader
Returns
LoadBankInfosCsvFile(string, string)
Loads all bank informations from a given CSV file.
public static SepaBankInfos LoadBankInfosCsvFile(string sCountryCode, string sFileName)
Parameters
Returns
Remarks
The CSV file must be UTF-8 encoded and must use a semi-colon ';' as the field separator. It must start with a header line with at least the headers "BankCode", "BIC", and "BankName". Additional headers may be present. The order of the columns is irrelevant. If additional columns are present, their values will be loaded as additional attributes that can be obtained through GetAttribute(string), using the header name.