We’re working on a new library which will be part of kawala and wanted to share our initial thoughts. The full design doc is available on the wiki. Below, you can watch our design review session.
An instantiator is meant to instantiate objects from string representation of its constructor arguments. In addition, instantiators can produce the list of string representations from an object instance.
Instantiator instantitor = ...; AddUser query = instantiator.newInstance( AddUser.class, "Pascal", "26", "email@example.com"); List parameters = instantitor.fromInstance( query);
The parameters list would be ["Pascal", "26", "firstname.lastname@example.org"].
To achieve this, the instantiation framework will require minimal input from the library user and most uses cases should work out of the box with no specific configuration.