1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-11-28 20:22:24 -05:00
git-svn-id: file:///home/ksmith/gitmigration/svn/xmpp/trunk@903 4b5297f7-1745-476d-ba37-a9c6900126ab
This commit is contained in:
Peter Saint-Andre 2007-06-01 20:28:50 +00:00
parent a62d95e9f3
commit 54102e7ed1

View File

@ -15,7 +15,7 @@
<sig>Standards</sig> <sig>Standards</sig>
<dependencies> <dependencies>
<spec>XMPP Core</spec> <spec>XMPP Core</spec>
<spec>XEP-0060</spec> <spec>XEP-0163</spec>
</dependencies> </dependencies>
<supersedes/> <supersedes/>
<supersededby/> <supersededby/>
@ -25,6 +25,12 @@
</schemaloc> </schemaloc>
&hildjj; &hildjj;
&stpeter; &stpeter;
<revision>
<version>1.4pre1</version>
<date>in progress, last updated 2007-05-30</date>
<initials>psa</initials>
<remark><p>Corrected PEP examples; added uri element.</p></remark>
</revision>
<revision> <revision>
<version>1.3</version> <version>1.3</version>
<date>2006-08-21</date> <date>2006-08-21</date>
@ -240,18 +246,23 @@
<td>UTC timestamp specifying the moment when the reading was taken (MUST conform to the DateTime profile of &xep0082;)</td> <td>UTC timestamp specifying the moment when the reading was taken (MUST conform to the DateTime profile of &xep0082;)</td>
<td>2004-02-19T21:12Z</td> <td>2004-02-19T21:12Z</td>
</tr> </tr>
<tr>
<td>uri</td>
<td>A URI or URL pointing to information about the location</td>
<td>http://beta.plazes.com/plazes/1940:jabber_inc</td>
<td>xs:anyURI</td>
</tr>
</table> </table>
<p>NOTE: The datatypes specified above are defined in &w3xmlschema2;.</p> <p>NOTE: The datatypes specified above are defined in &w3xmlschema2;.</p>
</section1> </section1>
<section1 topic='Use Cases' anchor='usecases'> <section1 topic='Use Cases' anchor='usecases'>
<p>The location information SHOULD be communicated by means of &xep0060; or the subset of publish-subscribe specified in &xep0163;. Because location information is not pure presence information and can change independently of the user's availability, it SHOULD NOT be provided as an extension to &PRESENCE;, although an application MAY do so if necessary.</p> <p>Location information SHOULD be communicated and transported by means of the &xep0060; subset specified in &xep0163;. Because location information is not pure presence information and can change independently of the user's availability, it SHOULD NOT be provided as an extension to &PRESENCE;.</p>
<section2 topic='Entity publishes location via pubsub' anchor='usecases-pubsub'> <section2 topic='Entity publishes location via PEP' anchor='usecases-pubsub'>
<p>In order to provide information about one's location, the publishing entity should use the pubsub protocol (the following examples show use of the publish-subscribe subset specified in <cite>XEP-0163</cite>).</p>
<example caption='Entity publishes location'><![CDATA[ <example caption='Entity publishes location'><![CDATA[
<iq type='set' from='portia@merchantofvenice.lit/pda' id='publish1'> <iq type='set' from='portia@merchantofvenice.lit/pda' id='publish1'>
<pubsub xmlns='http://jabber.org/protocol/pubsub'> <pubsub xmlns='http://jabber.org/protocol/pubsub'>
<publish node='http://jabber.org/protocol/geoloc'> <publish node='http://jabber.org/protocol/geoloc'>
<item id='a1s2d3f4g5h6bjeh936'> <item>
<geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'> <geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'>
<country>Italy</country> <country>Italy</country>
<lat>45.44</lat> <lat>45.44</lat>
@ -268,7 +279,7 @@
to='bassanio@merchantofvenice.lit/home'> to='bassanio@merchantofvenice.lit/home'>
<event xmlns='http://jabber.org/protocol/pubsub#event'> <event xmlns='http://jabber.org/protocol/pubsub#event'>
<items node='http://jabber.org/protocol/geoloc'> <items node='http://jabber.org/protocol/geoloc'>
<item id='a1s2d3f4g5h6bjeh936'> <item id='d81a52b8-0f9c-11dc-9bc8-001143d5d5db'>
<geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'> <geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'>
<country>Italy</country> <country>Italy</country>
<lat>45.44</lat> <lat>45.44</lat>
@ -279,6 +290,9 @@
</items> </items>
</event> </event>
</message> </message>
.
.
.
]]></example> ]]></example>
</section2> </section2>
<section2 topic='Entity requests the location of another entity' anchor='usecases-request'> <section2 topic='Entity requests the location of another entity' anchor='usecases-request'>
@ -317,35 +331,26 @@
]]></example> ]]></example>
</section2> </section2>
<section2 topic='Sending location' anchor='usecases-send'> <section2 topic='Sending location' anchor='usecases-send'>
<p>If an entity wants to send another entity its postition but it does not publish that information via pubsub, it MAY do so in a message. There SHOULD be a body element so that receiving entities that do not support the geolocation protocol can present a message to the recipient.</p> <p>If an entity wants to send another entity its postition but it does not publish that information via pubsub, it MAY do so in a message. The message SHOULD NOT include an XMPP body element.</p>
<example caption='Message containing location'><![CDATA[ <example caption='Message containing location'><![CDATA[
<message <message
to='polonius@hamlet.lit' to='polonius@hamlet.lit'
from='horatio@hamlet.lit/castle'> from='horatio@hamlet.lit/castle'>
<body>This message contains a location.</body>
<geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'> <geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'>
<description>Elsinore</description> <description>Elsinore</description>
<lat>56.033</lat> <lat>56.033</lat>
<lon>12.618</lon> <lon>12.618</lon>
<uri>http://www.mapquest.com/maps/map.adp?latlongtype=decimal&latitude=56.033&longitude=12.618</uri>
</geoloc> </geoloc>
<x xmlns='jabber:x:oob'>
<url>
http://www.mapquest.com/maps/map.adp?latlongtype=decimal&latitude=56.033&longitude=12.618
</url>
</x> </x>
</message>]]></example> </message>]]></example>
</section2> </section2>
<section2 topic='Entity publishes location in presence' anchor='usecases-presence'> <section2 topic='Entity publishes location in presence' anchor='usecases-presence'>
<p>If an entity wishes all of the entities on its roster to be informed of a new location, the entity MAY publish a presence stanza that includes a location, although this is NOT RECOMMENDED (since location SHOULD be published using pubsub instead in order to ensure appropriate access control):</p> <p>If an entity has generated or been issued a random resource identifier but it wishes to inform all of the entities on its roster about its location, the entity MAY publish a presence stanza that includes a location. It is RECOMMENDED to include only the &lt;description/&gt; element, since full locations SHOULD be published using PEP in order to save bandwidth and ensure appropriate access control.</p>
<example caption='Location in presence'><![CDATA[ <example caption='Location in presence'><![CDATA[
<presence> <presence from='juliet@capulet.lit/0d662bc8-0f97-11dc-ad28-000bcd821bfb'>
<geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'> <geoloc xmlns='http://jabber.org/protocol/geoloc' xml:lang='en'>
<alt>1609</alt> <description>balcony</description>
<description>Jabber, Inc.</description>
<error>10</error>
<lat>39.75477</lat>
<lon>-104.99768</lon>
<timestamp>2004-02-19T21:12Z</timestamp>
</geoloc> </geoloc>
</presence>]]></example> </presence>]]></example>
</section2> </section2>
@ -514,6 +519,7 @@
<xs:element name='street' minOccurs='0' type='xs:string'/> <xs:element name='street' minOccurs='0' type='xs:string'/>
<xs:element name='text' minOccurs='0' type='xs:string'/> <xs:element name='text' minOccurs='0' type='xs:string'/>
<xs:element name='timestamp' minOccurs='0' type='xs:datetime'/> <xs:element name='timestamp' minOccurs='0' type='xs:datetime'/>
<xs:element name='uri' minOccurs='0' type='xs:anyURI'/>
</xs:sequence> </xs:sequence>
</xs:complexType> </xs:complexType>
</xs:element> </xs:element>