java - Options for defining interface mapping code in the 21st century -
currently working on re-writing several interfaces , looking @ options there defining mapping between systems. need things filtering out records, remap 1 2 etc - core of seems assigning new format old format , looking nice clear/easy maintain way this.
probably written in java - may try , throw in jruby if makes mappings cleaner...
options come mind are:
- in code, lots of if/else , assignments
- via generic system, store mapping somewhere (eg db) easy-ish items , process in interface
i preferring 1. @ moment - array/map of simple assignments code succinct. , @ least things opaque mapping in code. anticipated interface not change on time...
as write this, thinking making mountain out of mole hill... since have gone far - think?
what do/have done things this?
thanks in advance, chris.
swinging towards option 2 - storing simple mappings in config file/db (perhaps in dsl format) ease of access if change needed in future.
Comments
Post a Comment