public class IBANBICPlugin
extends org.imixs.workflow.engine.plugins.AbstractPlugin
Validation is skipped in case no data is provided.
For validation we use the open source library 'iban4j'
Note: In some cases the IBAN/BIC is provided on a external invoice with spaces at positions which are strictly not allowed. For example a space between the country and the first to digits 'DE 99'. We accept those settings by removing all spaces before validation. You can disable this behaviour by setting the property sepa.validation.strict=true.
https://github.com/arturmkrtchyan/iban4j| Modifier and Type | Field and Description |
|---|---|
static String[] |
BIC_ITEMS |
static String |
ERROR_INVALID_IBANBIC |
static String[] |
IBAN_BIC_ITEMS |
static String[] |
IBAN_ITEMS |
static String |
SEPA_VALIDATION_STRICT |
| Constructor and Description |
|---|
IBANBICPlugin() |
| Modifier and Type | Method and Description |
|---|---|
org.imixs.workflow.ItemCollection |
run(org.imixs.workflow.ItemCollection workitem,
org.imixs.workflow.ItemCollection event)
Validates the items dbtr.iban, dbtr.bic, cdtr.iban and cdtr.bic.
|
void |
setSepaValidationStrict(boolean sepaValidationStrict) |
void |
validateBIC(org.imixs.workflow.ItemCollection workitem,
String... itemNames)
This method validates an bic item.
|
void |
validateIBAN(org.imixs.workflow.ItemCollection workitem,
String... itemNames)
This method validates an iban item.
|
public static final String ERROR_INVALID_IBANBIC
public static final String SEPA_VALIDATION_STRICT
public static final String[] IBAN_BIC_ITEMS
public static final String[] IBAN_ITEMS
public static final String[] BIC_ITEMS
public org.imixs.workflow.ItemCollection run(org.imixs.workflow.ItemCollection workitem,
org.imixs.workflow.ItemCollection event)
throws org.imixs.workflow.exceptions.PluginException
If the event result provides the tag
the validation will be scipped
org.imixs.workflow.exceptions.PluginException - - if invalid iban/bicpublic void setSepaValidationStrict(boolean sepaValidationStrict)
public void validateIBAN(org.imixs.workflow.ItemCollection workitem,
String... itemNames)
The method supports formated IBAN input as well as normal IBAN (without spaces)
workitem - itemName - org.imixs.workflow.exceptions.PluginExceptionpublic void validateBIC(org.imixs.workflow.ItemCollection workitem,
String... itemNames)
workitem - itemName - org.imixs.workflow.exceptions.PluginExceptionCopyright © 2021 Imixs Software Solutions GmbH. All rights reserved.