[standards-jig] JEP-0049 Private XML Storage

Richard Dobson richard at dobson-i.net
Tue Nov 12 21:21:01 UTC 2002


On Tuesday, November 12, 2002, at 02:32  am, Robert Norris wrote:

>> <iq type='set'>
>>   <query xmlns='jabber:iq:private'>
>>     <remove xmlns='namespace/to/remove'/>
>>   </query>
>> </iq>
>
> Except that the data I want to store might actually start with a
> "remove" element. I think a better way might be:
>
>   <iq type='set'>
>     <query xmlns='jabber:iq:private'>
>       <remove>namespace/to/remove</remove>
>     </query>
>   </iq>
>
> Something like that anyway - we need to distinguish the remove command
> from any data that the client may wish to store.

Why does there need to be a remove command anyway? If you query for a 
particular stored namespace which has not been previously stored it 
does not send back an error, but just sends back a blank result, why 
not just have it so that blank store commands are what do the delete 
e.g.

The remove request:

<iq type='set'>
	<query xmlns='jabber:iq:private'>
		<item xmlns='namespace:to:remove'/>
	</query>
</iq>

Request for a stored namespace which is not already stored:

<iq type='get'>
	<query xmlns='jabber:iq:private'>
		<item xmlns='namespace:to:get'/>
	</query>
</iq>

The result

<iq type='result'>
	<query xmlns='jabber:iq:private'>
		<item xmlns='namespace:to:get'/>
	</query>
</iq>

Richard





More information about the Standards mailing list