I've been evaluating SmartClient Pro 7.0rc2 (not SmartGWT) and I can't find anywhere in the documentation or forums a clear example of mapping a Java POJO collection in a .ds.xml.
An example is in order...
Application.java
Vehicle.java
application.ds.xml
Basically I need a DynamicForm where I can add 'n' tuples of (year,make,model) inputs which will get submitted in the 'saveData' operation once the form is submitted.
Any help is appreciated!
Thanks,
mgbowman
An example is in order...
Application.java
Code:
public class Application implements Serializable { List<Vehicle> vehicles; // getters & setters }
Code:
public class Vehicle implements Serializable { private Integer year; private String make; private String model; // getters & setters }
Code:
<DataSource ID="application"> <serverObject ... /> <fields> <!-- mgb: I'm not sure what to do here --> <field name="vehicles" multiple="true" /> <field name="vehicle_year" type="integer" /> <field name="vehicle_make" type="text" /> <field name="vehicle_model" type="text" /> </fields>
Any help is appreciated!
Thanks,
mgbowman
Comment