ebics-java / ebics-java-client

Java open source EBICS client - Support for French, German and Swiss banks
GNU Lesser General Public License v2.1
36 stars 35 forks source link

Implement OrderType as interface to allow arbitrary order types #15

Closed reva closed 3 years ago

reva commented 3 years ago

The OrderType is actually not a fixed set but has bank specific codes as well. e.g. Credit Suisse in Switzerland has XTD for their test environment. There even seems to be some standardisation around Switzerland specific codes: https://www.six-group.com/dam/download/banking-services/interbank-clearing/en/standardization/ebics/ebics.pdf.

I suggest opening up the 'OrderType' to be able to set any order code in the future. This change should be completely backwards compatible.

uwemaurer commented 3 years ago

I like this change to open up this enum! I found a few places which call .toString() on the OrderType (now EbicsOrderType)

eg lines like orderType = EbicsXmlFactory.createOrderType(type.toString()); need to be changed to orderType = EbicsXmlFactory.createOrderType(type.getCode());

reva commented 3 years ago

@uwemaurer Thanks for the quick feedback! Should be fixed now. Is there a release process for this library?

uwemaurer commented 3 years ago

Thank you for your change. There is currently no release process. I suggest to use a version built on JitPack with a specific commit. Having proper releases would be good, I am planning to do this in the future.