-
Notifications
You must be signed in to change notification settings - Fork 35
Iban type
Martijn Bodeman edited this page Aug 24, 2023
·
8 revisions
The Iban type encapsulates an IBAN and is ideal for use in you domain/business logic layer. Because you now have a strong type (similar to using a value object), your code becomes more reliable and maintainable. It is trivial to hook up to object-to-object mappers, ORM's, serializers, etc.
The type implements several interoperability interfaces and provides helper methods and properties which makes integration with your API/infrastructure layers easy:
- Parsing an IBAN
Country,Bban,BankIdentifier,BranchIdentifierproperties- Formatting an IBAN
- Test for equality
- Type conversion to and from string
- JSON conversion
- Object mapping examples
Do check some working code examples in the repository ./examples folder for some use cases.
