Sample XML File Data Service builder for quick prototyping and UI-first development
In many situations, it's valuable to be able to create a data provider in Web Experience Factory (WEF) without a dependency on any back end data store. You may want this for:
- Learning the UI-related tools of WEF without the complexity of real back end data access. With WEF's service provider/consumer architecture, your UI layer is always independent of your back end data, and any UI techniques can be used with any provider. Now with this builder you can easily make providers that have the data fields you need for your UI.
- Doing “UI first” development. In this scenario you build your application UI using a stub data provider before you have access to your real final data source. Then later you can create your real provider using your actual back end data source and swap it in for the XML file provider.
- Creating user interface samples or demos that have no back end dependency.
The attached XML File Data Service builder is a sample builder that can be used for these scenarios. It can be used to quickly create a service provider that accesses data from an XML file. You select an XML file that contains a table with a flat data structure, and the builder will generate complete CRUD (create, read, update, delete) operations. You can make a complete service provider model with just a single builder. The XML file data is included right in the project and generated WAR.
Note that this builder is for prototyping and development purposes only and is not suitable for production use.
The builder also generates “logical operation” metadata for service operations, making it suitable for use with the Data Services User Interface builder. One of the attached consumer models uses the View & Form builder and the other one uses the Data Services User Interface builder.
Here is a screenshot showing the builder inputs. This single builder is the only builder needed in the service provider model for the “contacts” sample shown below.
Below is a screenshot of the "contacts" sample application that's included in the sample package. This model uses the View & Form builder along with a Data Layout, and it includes list, details, and update support from the View & Form builder. It provides “create” support using the Input Form builder.
This screenshot shows another sample, this time using the Data Services User Interface builder, with list, details, update, create, delete, and search support.
About the builder
This builder is an example of a data access builder created using documented APIs. It can be examined for a number of techniques used when making builders, such as schema generation and use of a “helper” LJO class. Since complete source is included you can also enhance/modify it to suit your needs.
Click here to download the package, then use the Import / Web Experience Factory Archive command to import it into a project.