DdsDcpsInfrastructure.idl

Go to the documentation of this file.
00001 /*
00002  *
00003  *
00004  * Distributed under the OpenDDS License.
00005  * See: http://www.opendds.org/license.html
00006  */
00007 
00008 #ifndef OPENDDS_DCPS_INFRASTRUCTURE_IDL
00009 #define OPENDDS_DCPS_INFRASTRUCTURE_IDL
00010 
00011 #include "dds/DdsDcpsCore.idl"
00012 #include "dds/DdsDcpsConditionSeq.idl"
00013 
00014 #define DOMAINID_TYPE_NATIVE long
00015 #define HANDLE_NIL_NATIVE 0
00016 // Implementation Note:
00017 //   Client code must include "Service_Participant.h"
00018 //   to have these definitions.
00019 //#define TheParticipantFactory
00020 
00021 // Implementation Note:
00022 //   Client code must include "Marked_Default_Qos.h"
00023 //   to have these definitions.
00024 //#define PARTICIPANT_QOS_DEFAULT
00025 //#define TOPIC_QOS_DEFAULT
00026 //#define PUBLISHER_QOS_DEFAULT
00027 //#define SUBSCRIBER_QOS_DEFAULT
00028 //#define DATAWRITER_QOS_DEFAULT
00029 //#define DATAREADER_QOS_DEFAULT
00030 //#define DATAWRITER_QOS_USE_TOPIC_QOS
00031 //#define DATAREADER_QOS_USE_TOPIC_QOS
00032 
00033 #pragma ciao lem "dds/DdsDcpsInfrastructureE.idl"
00034 
00035 module DDS {
00036     typedef DOMAINID_TYPE_NATIVE  DomainId_t;
00037     // Moved to DdsDcpsCore.idl
00038     // typedef HANDLE_TYPE_NATIVE    InstanceHandle_t;
00039     // typedef BUILTIN_TOPIC_KEY_TYPE_NATIVE BuiltinTopicKeyValue[3];
00040     // typedef sequence<InstanceHandle_t> InstanceHandleSeq;
00041 
00042     typedef long ReturnCode_t;
00043 
00044     // ----------------------------------------------------------------------
00045     // Pre-defined values
00046     // ----------------------------------------------------------------------
00047     const InstanceHandle_t HANDLE_NIL = HANDLE_NIL_NATIVE;
00048 
00049     const long LENGTH_UNLIMITED = -1;
00050 
00051     // ----------------------------------------------------------------------
00052     // Return codes
00053     // ----------------------------------------------------------------------
00054     const ReturnCode_t RETCODE_OK = 0;
00055     const ReturnCode_t RETCODE_ERROR = 1;
00056     const ReturnCode_t RETCODE_UNSUPPORTED = 2;
00057     const ReturnCode_t RETCODE_BAD_PARAMETER = 3;
00058     const ReturnCode_t RETCODE_PRECONDITION_NOT_MET = 4;
00059     const ReturnCode_t RETCODE_OUT_OF_RESOURCES = 5;
00060     const ReturnCode_t RETCODE_NOT_ENABLED = 6;
00061     const ReturnCode_t RETCODE_IMMUTABLE_POLICY = 7;
00062     const ReturnCode_t RETCODE_INCONSISTENT_POLICY = 8;
00063     const ReturnCode_t RETCODE_ALREADY_DELETED = 9;
00064     const ReturnCode_t RETCODE_TIMEOUT = 10;
00065     const ReturnCode_t RETCODE_NO_DATA = 11;
00066     const ReturnCode_t RETCODE_ILLEGAL_OPERATION     = 12;
00067 
00068     // ----------------------------------------------------------------------
00069     // Status to support listeners and conditions
00070     // ----------------------------------------------------------------------
00071 
00072     typedef unsigned long StatusKind;
00073     typedef unsigned long StatusMask; // bit-mask StatusKind
00074 
00075     const StatusKind INCONSISTENT_TOPIC_STATUS            = 0x0001 << 0;
00076     const StatusKind OFFERED_DEADLINE_MISSED_STATUS       = 0x0001 << 1;
00077     const StatusKind REQUESTED_DEADLINE_MISSED_STATUS     = 0x0001 << 2;
00078     const StatusKind OFFERED_INCOMPATIBLE_QOS_STATUS      = 0x0001 << 5;
00079     const StatusKind REQUESTED_INCOMPATIBLE_QOS_STATUS    = 0x0001 << 6;
00080     const StatusKind SAMPLE_LOST_STATUS                   = 0x0001 << 7;
00081     const StatusKind SAMPLE_REJECTED_STATUS               = 0x0001 << 8;
00082     const StatusKind DATA_ON_READERS_STATUS               = 0x0001 << 9;
00083     const StatusKind DATA_AVAILABLE_STATUS                = 0x0001 << 10;
00084     const StatusKind LIVELINESS_LOST_STATUS               = 0x0001 << 11;
00085     const StatusKind LIVELINESS_CHANGED_STATUS            = 0x0001 << 12;
00086     const StatusKind PUBLICATION_MATCHED_STATUS           = 0x0001 << 13;
00087     const StatusKind SUBSCRIPTION_MATCHED_STATUS          = 0x0001 << 14;
00088 
00089     struct InconsistentTopicStatus {
00090                 long total_count;
00091                 long total_count_change;
00092                 };
00093 
00094     struct SampleLostStatus {
00095                 long total_count;
00096                 long total_count_change;
00097                 };
00098 
00099     enum SampleRejectedStatusKind {
00100                 NOT_REJECTED,
00101                 REJECTED_BY_INSTANCES_LIMIT,
00102                 REJECTED_BY_SAMPLES_LIMIT,
00103                 REJECTED_BY_SAMPLES_PER_INSTANCE_LIMIT
00104                 };
00105 
00106     struct SampleRejectedStatus {
00107                 long total_count;
00108                 long total_count_change;
00109                 SampleRejectedStatusKind last_reason;
00110                 InstanceHandle_t last_instance_handle;
00111                 };
00112 
00113     struct LivelinessLostStatus {
00114                 long total_count;
00115                 long total_count_change;
00116                 };
00117 
00118     struct LivelinessChangedStatus {
00119                 long alive_count;
00120                 long not_alive_count;
00121                 long alive_count_change;
00122                 long not_alive_count_change;
00123                 InstanceHandle_t last_publication_handle;
00124                 };
00125 
00126     struct OfferedDeadlineMissedStatus {
00127                 long total_count;
00128                 long total_count_change;
00129                 InstanceHandle_t last_instance_handle;
00130                 };
00131 
00132     struct RequestedDeadlineMissedStatus {
00133                 long total_count;
00134                 long total_count_change;
00135                 InstanceHandle_t last_instance_handle;
00136                 };
00137 
00138     struct OfferedIncompatibleQosStatus {
00139                 long total_count;
00140                 long total_count_change;
00141                 QosPolicyId_t last_policy_id;
00142                 QosPolicyCountSeq policies;
00143                 };
00144 
00145     struct RequestedIncompatibleQosStatus {
00146                 long total_count;
00147                 long total_count_change;
00148                 QosPolicyId_t last_policy_id;
00149                 QosPolicyCountSeq policies;
00150                 };
00151 
00152 
00153     struct PublicationMatchedStatus {
00154                 long total_count;
00155                 long total_count_change;
00156                 long current_count;
00157                 long current_count_change;
00158                 InstanceHandle_t last_subscription_handle;
00159                 };
00160 
00161 
00162     struct SubscriptionMatchedStatus {
00163                 long total_count;
00164                 long total_count_change;
00165                 long current_count;
00166                 long current_count_change;
00167                 InstanceHandle_t last_publication_handle;
00168                 };
00169 
00170     // ----------------------------------------------------------------------
00171     // Listeners
00172     // ----------------------------------------------------------------------
00173 
00174     local interface Listener;
00175     local interface Entity;
00176     //interface TopicDescription;
00177     //interface Topic;
00178     //interface ContentFilteredTopic;
00179     //interface MultiTopic;
00180     //interface DataWriter;
00181     //interface DataReader;
00182     //interface Subscriber;
00183     //interface Publisher;
00184 
00185     //typedef sequence<Topic> TopicSeq;
00186     //typedef sequence<DataReader> DataReaderSeq;
00187 
00188     local interface Listener {};
00189 
00190     // ----------------------------------------------------------------------
00191     // Conditions
00192     // ----------------------------------------------------------------------
00193 
00194     local interface Condition {
00195         boolean get_trigger_value();
00196     };
00197 
00198     // WaitSet and GuardCondition can't be expressed in IDL because they are
00199     // required by the spec to be default-constructable by the user
00200     // (07-01-01 section 7.2.2 pgh 11).  Therefore in IDL we have WaitSetInterf
00201     // and GuardConditionInterf.  Application code should #include
00202     // "dds/DCPS/WaitSet.h", "dds/DCPS/GuardCondition.h" and construct heap
00203     // objects with "new WaitSet()" and "new GuardCondition()".  Those objects
00204     // (in the DDS namespace/package) implement the interfaces described below.
00205     // In C++, these are reference-counted local CORBA objects.
00206 
00207     local interface WaitSetInterf {
00208         ReturnCode_t wait(
00209             inout ConditionSeq active_conditions,
00210             in Duration_t timeout);
00211         ReturnCode_t attach_condition(
00212             in Condition cond);
00213         ReturnCode_t detach_condition(
00214             in Condition cond);
00215         ReturnCode_t get_conditions(
00216             inout ConditionSeq attached_conditions);
00217     };
00218 
00219     local interface GuardConditionInterf : Condition {
00220         ReturnCode_t set_trigger_value(
00221             in boolean value);
00222     };
00223 
00224 
00225     local interface StatusCondition : Condition {
00226         StatusMask get_enabled_statuses();
00227         ReturnCode_t set_enabled_statuses(
00228             in StatusMask mask);
00229         Entity get_entity();
00230     };
00231 
00232     // ----------------------------------------------------------------------
00233     // Qos
00234     // ----------------------------------------------------------------------
00235     const string USERDATA_QOS_POLICY_NAME            = "UserData";
00236     const string DURABILITY_QOS_POLICY_NAME          = "Durability";
00237     const string PRESENTATION_QOS_POLICY_NAME        = "Presentation";
00238     const string DEADLINE_QOS_POLICY_NAME            = "Deadline";
00239     const string LATENCYBUDGET_QOS_POLICY_NAME       = "LatencyBudget";
00240     const string OWNERSHIP_QOS_POLICY_NAME           = "Ownership";
00241     const string OWNERSHIPSTRENGTH_QOS_POLICY_NAME   = "OwnershipStrength";
00242     const string LIVELINESS_QOS_POLICY_NAME          = "Liveliness";
00243     const string TIMEBASEDFILTER_QOS_POLICY_NAME     = "TimeBasedFilter";
00244     const string PARTITION_QOS_POLICY_NAME           = "Partition";
00245     const string RELIABILITY_QOS_POLICY_NAME         = "Reliability";
00246     const string DESTINATIONORDER_QOS_POLICY_NAME    = "DestinationOrder";
00247     const string HISTORY_QOS_POLICY_NAME             = "History";
00248     const string RESOURCELIMITS_QOS_POLICY_NAME      = "ResourceLimits";
00249     const string ENTITYFACTORY_QOS_POLICY_NAME       = "EntityFactory";
00250     const string WRITERDATALIFECYCLE_QOS_POLICY_NAME = "WriterDataLifecycle";
00251     const string READERDATALIFECYCLE_QOS_POLICY_NAME = "ReaderDataLifecycle";
00252     const string TOPICDATA_QOS_POLICY_NAME           = "TopicData";
00253     const string GROUPDATA_QOS_POLICY_NAME           = "GroupData";
00254     const string TRANSPORTPRIORITY_QOS_POLICY_NAME   = "TransportPriority";
00255     const string LIFESPAN_QOS_POLICY_NAME            = "Lifespan";
00256     const string DURABILITYSERVICE_POLICY_NAME       = "DurabilityService";
00257 
00258     const QosPolicyId_t INVALID_QOS_POLICY_ID              = 0;
00259     const QosPolicyId_t USERDATA_QOS_POLICY_ID            = 1;
00260     const QosPolicyId_t DURABILITY_QOS_POLICY_ID          = 2;
00261     const QosPolicyId_t PRESENTATION_QOS_POLICY_ID        = 3;
00262     const QosPolicyId_t DEADLINE_QOS_POLICY_ID            = 4;
00263     const QosPolicyId_t LATENCYBUDGET_QOS_POLICY_ID       = 5;
00264     const QosPolicyId_t OWNERSHIP_QOS_POLICY_ID           = 6;
00265     const QosPolicyId_t OWNERSHIPSTRENGTH_QOS_POLICY_ID   = 7;
00266     const QosPolicyId_t LIVELINESS_QOS_POLICY_ID          = 8;
00267     const QosPolicyId_t TIMEBASEDFILTER_QOS_POLICY_ID     = 9;
00268     const QosPolicyId_t PARTITION_QOS_POLICY_ID           = 10;
00269     const QosPolicyId_t RELIABILITY_QOS_POLICY_ID         = 11;
00270     const QosPolicyId_t DESTINATIONORDER_QOS_POLICY_ID    = 12;
00271     const QosPolicyId_t HISTORY_QOS_POLICY_ID             = 13;
00272     const QosPolicyId_t RESOURCELIMITS_QOS_POLICY_ID      = 14;
00273     const QosPolicyId_t ENTITYFACTORY_QOS_POLICY_ID       = 15;
00274     const QosPolicyId_t WRITERDATALIFECYCLE_QOS_POLICY_ID = 16;
00275     const QosPolicyId_t READERDATALIFECYCLE_QOS_POLICY_ID = 17;
00276     const QosPolicyId_t TOPICDATA_QOS_POLICY_ID           = 18;
00277     const QosPolicyId_t GROUPDATA_QOS_POLICY_ID           = 19;
00278     const QosPolicyId_t TRANSPORTPRIORITY_QOS_POLICY_ID   = 20;
00279     const QosPolicyId_t LIFESPAN_QOS_POLICY_ID            = 21;
00280     const QosPolicyId_t DURABILITYSERVICE_QOS_POLICY_ID   = 22;
00281 
00282     // ----------------------------------------------------------------------
00283     local interface Entity {
00284     //  ReturnCode_t set_qos(
00285     //      in EntityQos qos);
00286     //  ReturnCode_t get_qos(
00287     //      inout EntityQos qos);
00288     //  ReturnCode_t set_listener(
00289     //      in Listener l,
00290     //      in StatusMask mask);
00291     //  Listener get_listener();
00292 
00293       ReturnCode_t enable();
00294 
00295       StatusCondition get_statuscondition();
00296 
00297       StatusMask get_status_changes();
00298 
00299       InstanceHandle_t get_instance_handle();
00300     };
00301 
00302 };
00303 
00304 module OpenDDS
00305 {
00306   const string TRANSPORTTYPE_QOS_POLICY_NAME = "TransportType";
00307 
00308   // OpenDDS-specific QosPolicyId_t values start from the maximum
00309   // QosPolicyId_t (a 32-bit signed integer) and decrement as new
00310   // OpenDDS-specific values are added.  The goal is to avoid
00311   // potential conflicts with new OMG defined QosPolicyId_t values.
00312   const ::DDS::QosPolicyId_t TRANSPORTTYPE_QOS_POLICY_ID = 0x7fffffff;
00313 
00314   // DomainIds used by the implementation will be larger than this constant:
00315   const ::DDS::DomainId_t MAX_USER_DOMAINID = 0x7fffffff;
00316 
00317   module DCPS
00318   {
00319     const DDS::StatusMask ALL_STATUS_MASK = 0xffffffff;
00320     const DDS::StatusMask NO_STATUS_MASK  = 0x00000000;
00321     const DDS::StatusMask DEFAULT_STATUS_MASK = ALL_STATUS_MASK;
00322   };
00323 };
00324 
00325 #endif  /* OPENDDS_DCPS_INFRASTRUCTURE_IDL */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 10 Aug 2018 for OpenDDS by  doxygen 1.6.1