Validate and calculate IBAN and BBAN codes.
author |
Eduard Mombiela mombiela.eduard@gmail.com |
---|---|
version | GIT: $Id$ |
link |
http://en.wikipedia.org/wiki/International_Bank_Account_Number |
package |
Iban |
bbanCountriesList() : array
This method returns an array with the BBAN calculation algorithm
implemented.
The key of each element is the country code defined in ISO 3166.
array
calculate(string $country, string $bban) : array
Calculate IBAN code from BBAN code and country to which it belongs.
string
Country of BBAN code.
string
BBAN code.
array
array[0]:null|string = error,
array[1]:null|string = IBAN code if array[0] is null.
checkDigits(string $iban) : integer
string
IBAN code.
integer
IBAN check digits.
countriesList() : array
This method returns an array with the names of the countries.
The key of each element is the country code defined in ISO 3166.
array
sepaCountriesList() : array
This method returns an array with the names of the SEPA countries.
The key of each element is the country code defined in ISO 3166.
array
validate(string $iban) : string|null
Returns a string with the validation error. If the string returned is null the IBAN code is correct.
string
IBAN code to validate.
string|null
Validation error.
validateStructure(string $structure, string $code, integer $start) : boolean
Each structure of an IBAN code consists in smaller substructures that define the format of this and follow the conventions shown in Country class.
string
Pattern structure.
string
Code to parse.
integer
Code position to start parsing.
boolean
True if structure is right.
lettersConversionTable : array
Conversion table from letters to digits to calculate the IBAN code.
var |
---|
array
error : array
var |
---|
array