[Standards-JIG] JEP-0004 (x:data) Examples and a Question

Peter Saint-Andre stpeter at jabber.org
Mon Apr 5 20:51:54 UTC 2004

On Wed, Mar 31, 2004 at 04:37:47PM -0800, JD Conley wrote:
> 6.1 (Example 2) - The type attribute on the data form is "result" but
> should be "form".

Um, it is form, no?

<x xmlns='jabber:x:data' type='form'>

> 6.1 (Example 3 and 4) - It appears as though Example 4 should be showing
> the result of the form submittal in Example 3, but instead it is the
> same XML as Example 3.


> 6.1 (Example 8) - The result x:data form is of type "form" and it should
> be "result".


> A situation that isn't made very clear by the JEP is the result form.
> It states that a result may contain multiple results by using the
> <item/> element to encapsulate sets of fields (rows) and a <reported/>
> element to define the fields in the rows.  Does this mean an x:data data
> provider, when returning only a single result, should not use <item/>
> elements but instead simply include the <field/> elements directly under
> the <x/> element?


It depends on what you mean by "single result". When using x:data in
something like search, it makes sense to include <item/> elements.
However, in something like Example 4 of version 2.3 of the JEP, there
are no items to be returned -- the service is simply returning to the
user what was processed (much as, after purchasing an airline ticket
online, a website will show your itinerary).

So I see no reason to say that a data form of type "result" MUST include
at least one <item/> element in all instances.


More information about the Standards mailing list