Source code for schwifty.exceptions

[docs]class SchwiftyException(ValueError): # noqa: N818 """Base exception of all schwifty related errors."""
[docs]class InvalidLength(SchwiftyException): """Indicates that the length of the input does not match the specifcation."""
[docs]class InvalidStructure(SchwiftyException): """Indicates a strctural error of the input (e.g. invalid characters)."""
[docs]class InvalidCountryCode(SchwiftyException): """Unknown country code in the input."""
[docs]class InvalidBankCode(SchwiftyException): """Indicates that the bank code has an invalid structure."""
[docs]class InvalidBranchCode(SchwiftyException): """Indicates that the branch code has an invalid strucutre."""
[docs]class InvalidAccountCode(SchwiftyException): """Indicates that the account code has an invalid strucutre."""
[docs]class InvalidChecksumDigits(SchwiftyException): """Indicates that the IBAN's checksum is invalid."""
[docs]class InvalidBBANChecksum(SchwiftyException): """Indicates that the BBAN's checksum is invalid."""