Events.xid.xml 5.33 KB
<?xml version="1.0" encoding="UTF-8" ?>

<specification xmlns="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd"
               xmlns:xid="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="https://xid.location.studio/schema/V1.0.0/XtensibleInterfaceDefinition.xsd XtensibleInterfaceDefinition.xsd"
               identity="GeoObjectStoreApi.xid.xml">
  <title>GeoObject Storage API</title>
  <comment>
    This file defines the GeoObject Storage interface(s), which provides interactions for editing, searching, and retrieving various Geo Objects.
  </comment>

  <!-- Include all known definitions -->
  <import ref="https://xid.location.studio/Tensor/V1.0.0/Definitions.xid.xml" />
  <import ref="https://xid.location.studio/Tensor/V1.0.0/ApiBase.xid.xml" />
  <import ref="https://xid.location.studio/GeoSpatial/V1.0/Location.xid.xml" local="Location.xid.xml" />

  <namespace name="GeoSpatial">
    <using namespace="Tensor"/>


    <!--
    *************************************
    * Event Structures 
    *************************************
    -->

    <struct name="ProducerInfo" type="Object" rttkey="GeoSpatial.ObjectType.ProducerInfo">

      <elem name="events" type="Object" multiplicity="0..*" ord="21">
        <comment>Events defined by this producer.</comment>
      </elem>
    </struct>

    <struct name="Event">
      <comment>Structure contains information about an event occurring at the specified event producer (uriProducer).</comment>
      
      <struct name="SpeedInfo" pack="true">
        <comment>Structure contains speed information of the object.</comment>
        <elem name="horizontal" type="float32" multiplicity="1" ord ="1">
          <tag name="unit" value="meters/sec"/>
          <comment>Optional horizontal speed of device in meters/sec</comment>
        </elem>
        <elem name="vertical" type="float32" multiplicity="1" ord ="2">
          <tag name="unit" value="meters/sec"/>
          <comment>Optional vertical speed of device in meters/sec</comment>
        </elem>
        <elem name="azimuth" type="float32" multiplicity="1" ord ="3">
          <tag name="unit" value="degrees"/>
          <comment>Optional azimuthal heading of the associated object in degrees (true North).</comment>
        </elem>
        <elem name="uncertainty" type="float32" multiplicity="1" default="-1" ord ="4">
          <tag name="unit" value="degrees"/>
          <comment>Optional azimuthal heading of the associated object in degrees (true North).</comment>
        </elem>
      </struct>

      <elem name="infoEvent" type="Object" multiplicity="1" ord ="1">
        <comment>Event definitional information.  This describes the nature of the event.  Event information can be a copy
        of the information specified by the producer or a minimum subset of identifiers (e.g. uuid, uriExternal, uriClassifier).  
        The amount of event information provided is application specific.
        </comment>
      </elem>
      
      <elem name="infoProducer" type="ProducerInfo" multiplicity="1" ord ="2">
        <comment>
          Producer information.  This describes the producer sending the information. Typically this is just the top level of producer
          information, the events contained are not typically provided as the event information is provided 
          separately.  Exact information provided is application specific.
        </comment>
      </elem>

      <elem name="uuid" type="Tensor.UUID" multiplicity="1" ord="3">
        <comment>Instance UUID for the Event,  Every event must specify a UUID associated with its unique time and place.</comment>
      </elem>
      
      <elem name="epoch" type="datetime" multiplicity="1" ord="4">
        <comment>Epoch defines the point in time for which the estimate applies.</comment>
      </elem>
      <elem name="location" type="Location" multiplicity="0..1" ord="5">
        <comment>Optional location the event occurred.</comment>
      </elem>
      <elem name="speed" type="SpeedInfo" multiplicity="0..1" ord="6">
        <comment>Optional speed information of the associated object at the time the event occurred.</comment>
      </elem>
    </struct>


    <!-- 
    *******************************************************
    EventProducer API
    *******************************************************
    -->
    <interface name="EventProducer">
      <comment>Interface defines the interactions common to all event producers. </comment>

      <operation name="RequestInfo">
        <comment>
          Interaction requests and returns a zero or more information sets of producer information containing
          zero or more events
        </comment>
        <input name="input" type="InputBase"  sid="0x1090">
        </input>
        <output name="output" type="OutputBase" sid="0x1091">
          <elem name="producer" multiplicity="0..*" type="ProducerInfo"></elem>          
        </output>
      </operation>

      <event name="Notify">
        <comment>Notifies bound event consumers of one or more events specified by the EventProducer.</comment>
        <output name="output" type="InputBase"  sid="0x1092">
          <elem name="event" multiplicity="1..*" type="Event"></elem>
        </output>
      </event>

    </interface>
  </namespace>
</specification>