<!--
  $Id: ciao_rt_cad_ext.dtd 54720 2003-12-22 21:56:59Z boris $

  DTD for CIAO ComponentAssembly real-time extension.
        The extension for this type of XML document should be .RTD

  A component server can be associated to one conforming XML
  descriptor file of this DTD via the <extension> tag under
  <hostcollocation>, <processcollocation> as

    <extension class="RT-CAD-EXT"
               origin="CIAO">pathname_to_xml_file.xml</extension>

  The root element is <rtcad-ext>.

  The <extension> tag under <homeplacement> element can be used to
  specify the <rtpolicyset> named in this file (using rtpolicyset's
  id attribute.)  For example,

    <extension class="RT-POLICY-SET"
               origin="CIAO">IDREF_of_some_rtpolicyset</extension>

-->

<!ELEMENT rtcad_ext ( rtresources?, rtpolicyset+ ) >

<!-- RT Resources grammar definitions -->

<!ELEMENT rtresources (threadpool | threadpoolwithlanes | connectionbands)* >

<!ELEMENT threadpool EMPTY>
<!ATTLIST threadpool
        id              ID      #REQUIRED
        stacksize       CDATA   #REQUIRED
        static_threads  CDATA   #REQUIRED
        dynamic_threads CDATA   #REQUIRED
        priority        CDATA   #REQUIRED
        buffering       (yes | no)   #REQUIRED
        max_buffer      CDATA   #REQUIRED
        buffer_size     CDATA   #REQUIRED >

<!ELEMENT threadpoolwithlanes (lane+) >
<!ATTLIST threadpoolwithlanes
          id            ID      #REQUIRED
          stacksize     CDATA   #REQUIRED
          borrowing     (yes | no)   #REQUIRED
          buffering     (yes | no)   #REQUIRED
          max_buffer    CDATA   #REQUIRED
          buffer_size   CDATA   #REQUIRED >

<!ELEMENT lane EMPTY>
<!ATTLIST lane
        priority        CDATA   #REQUIRED
        static_threads  CDATA   #REQUIRED
        dynamic_threads CDATA   #REQUIRED >

<!ELEMENT connectionbands (band+) >
<!ATTLIST connectionbands
        id              ID      #REQUIRED >

<!ELEMENT band EMPTY>
<!ATTLIST band
        low             CDATA   #REQUIRED
        high            CDATA   #REQUIRED >

<!-- RT Policy_Set grammar definitions -->
<!-- Each type of policy in rtpoliyset can only appear once -->
<!ELEMENT rtpolicyset (priority_model_policy,
                       threadpool_policy,
                       banded_connection_policy)+ >
<!ATTLIST rtpolicyset
        id              ID      #REQUIRED>

<!ELEMENT priority_model_policy EMPTY>
<!ATTLIST priority_model_policy
        type            (server_declared | client_propagated) #REQUIRED
        priority        CDATA   #REQUIRED>

<!ELEMENT threadpool_policy EMPTY>
<!--
     "idref" must be previously defined by the id attribute of
     either <threadpool> or <threadpoollanes> element
-->
<!ATTLIST threadpool_policy
        idref           IDREF   #REQUIRED>

<!ELEMENT banded_connection_policy EMPTY>
<!--
     "idref" must be previously defined by the id attribute of
     <connectionbands> element.
-->
<!ATTLIST banded_connection_policy
        idref           IDREF   #REQUIRED>