Sunday, July 30, 2006

XForms, metadata and MDA

For the last several weeks I have been looking at the XForms standard. This has been related to my contract at the Minnesota Department of Revenue to replace many of their paper forms with electronic versions. Although my contact is to design XML Schemas, ultimately they need to be entered through a web form. I started to build some mock-ups of web forms to clarify requirements but found the older HTLM forms lacking in many areas. I also wanted to be able to validate the data using the XML Schemas that I was building.

What I found was that XForms is a wonderfully designed specification. It integrates XML Schemas, XML data-types and XPath expressions directly into the standard and also adds the new XML Events standard. XForms also faithfully uses both the Model-View-Controller pattern and several separation-of-concerns issues. In short, XForms is an excellent design and appears to be very well thought out. My congrats to the XForms team.

My other worry was that it would be hard to setup and test XForms. I have been happy to find out that FireFox has a new plug-in that supports XForms and there is a plug-in free solution using the FormFaces javascript tools. Many of the examples just run without modification. Just build your XForms and out pops complex XML documents.

What I am most interested in is that there appears to be several things that XForms demonstrates that will make software engineering better: the drive away from the complex procedural world and toward a more model-driven declarative style of development that allows non-programmers to maintain complex systems. This means less complex javascript and complex server-side coding in Java. I hope to have a sample PowerPoint presentation on my web site soon that goes through these arguments. Look for an XForms user interface to data element entry in the near future.

Another last point is that if a large audience starts to build XForms you are going to start to have fully-formed XML documents flying around. This means you will need more XML Schemas being generated and web services to accept them and respond with XML documents and XML services. This will make the creation of new XForms go even faster. Positive feedback cycles. All the more reason to build a metadata registry!

I have been thinking about creating an transform from a constraint schema directly into an XForm. This would be an nice MDA-type approach.

Let me know your thoughts. - Dan

1 comment:

Anonymous said...

Hi Dan,
Good post. I am starting to go through your posts(finally!). Here you mention a powerpoint presentation that were going to post - Is this something that is available at this time? I would like to go through it.

-Arun