From cbda99e74a5031e14ab60fb7c9b5e9d000c73944 Mon Sep 17 00:00:00 2001 From: olivier Date: Tue, 14 May 2024 17:42:12 +0800 Subject: [PATCH] Added Angola Iban validation (#139) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add angola iban valid * Add test data --------- Co-authored-by: 王书然 --- src/main/java/org/iban4j/bban/BbanStructure.java | 7 +++++++ src/test/java/org/iban4j/TestDataHelper.java | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/src/main/java/org/iban4j/bban/BbanStructure.java b/src/main/java/org/iban4j/bban/BbanStructure.java index 0f39825..92fd314 100644 --- a/src/main/java/org/iban4j/bban/BbanStructure.java +++ b/src/main/java/org/iban4j/bban/BbanStructure.java @@ -74,6 +74,13 @@ private BbanStructure(final BbanStructureEntry... entries) { BbanStructureEntry.branchCode(4, 'n'), BbanStructureEntry.accountNumber(12, 'c'))); + structures.put(CountryCode.AO, + new BbanStructure( + BbanStructureEntry.bankCode(4, 'n'), + BbanStructureEntry.branchCode(4, 'n'), + BbanStructureEntry.accountNumber(11, 'n'), + BbanStructureEntry.nationalCheckDigit(2, 'n'))); + structures.put(CountryCode.AT, new BbanStructure( BbanStructureEntry.bankCode(5, 'n'), diff --git a/src/test/java/org/iban4j/TestDataHelper.java b/src/test/java/org/iban4j/TestDataHelper.java index cce8927..847fd8f 100644 --- a/src/test/java/org/iban4j/TestDataHelper.java +++ b/src/test/java/org/iban4j/TestDataHelper.java @@ -39,6 +39,13 @@ public static Collection getIbanData() { .branchCode("2030") .accountNumber("200359100100") .build(), "AD1200012030200359100100"}, + {new Iban.Builder() + .countryCode(CountryCode.AO) + .bankCode("0006") + .branchCode("0000") + .accountNumber("53518203301") + .nationalCheckDigit("69") + .build(), "AO06000600005351820330169"}, {new Iban.Builder() .countryCode(CountryCode.AT) .bankCode("19043")