[Standards] XEP-0258 and XEP-0060

Ashley Ward ashley.ward at surevine.com
Fri Nov 18 10:53:10 UTC 2011


On 18/11/2011 06:47, "Ralph Meijer" <ralphm at ik.nu> wrote:

>On Thu, Nov 17, 2011 at 07:55:09PM +0000, Ashley Ward wrote:
>> On 17/11/2011 18:53, "Ralph Meijer" <ralphm at ik.nu> wrote:
>> [..]
>>Yeah. I think it would make most sense for the label to be contained
>> within the <item> element, and I believe XEP-0060 already allows the
>> <item> element to contain a sequence of any xml elements, so
>>implementing
>> this in XEP-0258 shouldn't require any change to XEP-0060.
>
>Alas, this is incorrect. An <item/> element MUST NOT have more than one
>child element. See the schema. If present, the child element is the
>payload. This restriction doesn't apply to other elements, so I think it
>/would/ be ok to have the <securitylabel/> elements as a sibling of
><item/>.

You're right. Looking closer at the xml spec for XEP-0060 you can only
have one child of an <item/>.

I don't think it could be a sibling of <item> as the <publish> element can
only contain a list of <item/> elements.

There also doesn't appear to be any way of including any arbitrary xml
elements outside of the <item> element, so it would require a change to
the XEP-0060 spec too :(


(I suppose we could introduce another element type which can contain the
<event/> and the <securitylabel/> element and make this the child of the
<item/> - but this feels wrong!)





More information about the Standards mailing list