RtecUDPAdmin.idl

Go to the documentation of this file.
00001 /**
00002  * @file RtecUDPAdmin.idl
00003  *
00004  * @brief Define the RtecUDPAdmin module
00005  *
00006  * $Id: RtecUDPAdmin.idl 78550 2007-06-05 19:01:50Z mesnier_p $
00007  *
00008  * TAO's Real-time Event Service is described in:
00009  *
00010  * http://doc.ece.uci.edu/~coryan/EC/
00011  *
00012  * @author Carlos O'Ryan <coryan@uci.edu>
00013  */
00014 
00015 #ifndef TAO_RTEC_UDP_ADMIN_IDL
00016 #define TAO_RTEC_UDP_ADMIN_IDL
00017 
00018 #include "RtecEventComm.idl"
00019 #include "tao/OctetSeq.pidl"
00020 
00021 /**
00022  * @namespace RtecUDPAdmin
00023  *
00024  * @brief Define the data structures and interfaces used by UDP-based
00025  *   gateways
00026  */
00027 module RtecUDPAdmin
00028 {
00029   /**
00030    * @struct UDP_Addr
00031    *
00032    * @brief Represent a UDP SAP.
00033    */
00034   struct UDP_Addr
00035   {
00036     /// The IP address
00037     unsigned long ipaddr;
00038     /// The UDP port
00039     unsigned short port;
00040   };
00041 
00042   /**
00043    * @struct UDP_Addr_v6
00044    *
00045    * @brief Represent a UDP SAP sufficient to hold an IPv6 address.
00046    */
00047 
00048   struct UDP_Addr_v6
00049   {
00050     char ipaddr[16]; // used to match with ACE_INET_Addr::set_address
00051     unsigned short port;
00052   };
00053 
00054   /**
00055    * @enum Address_Family
00056    *
00057    * @brief Defines the address family identifiers. The more familiar
00058    *  AF_INET, AF_INET6 are not used to avoid potential confusion.
00059    *
00060    */
00061   enum Address_Family
00062   {
00063     Rtec_inet,
00064     Rtec_inet6
00065   };
00066 
00067   /**
00068    * @union UDP_Address
00069    *
00070    * @brief Holds either an IPv4 or IPv6 address and used for the
00071    *  return value from get_address below.
00072    *
00073    */
00074   union UDP_Address switch (Address_Family)
00075   {
00076   case Rtec_inet:
00077     UDP_Addr v4_addr;
00078   case Rtec_inet6:
00079     UDP_Addr_v6 v6_addr;
00080   };
00081 
00082   /**
00083    * @interface AddrServer
00084    *
00085    * @brief Defines a interface to configure the mapping between
00086    *   events and multicast groups (or UDP broadcast or UDP unicast)
00087    *   addresses.
00088    */
00089   interface AddrServer
00090   {
00091     /// Get the UDP address given the event header
00092     /**
00093      * @deprecated, applications should use get_address, which
00094      *   supports both IPv4 and IPv6 addresses.
00095      * @param header The event header, used to fetch the type and
00096      *   source of the event
00097      * @param addr Return the address used for the given event type
00098      */
00099     void get_addr (in RtecEventComm::EventHeader header,
00100                    out UDP_Addr addr);
00101 
00102     /// Get the UDP address given the event header, supports either
00103     /// IPv4 or IPv6
00104     /**
00105      * @param header The event header, used to fetch the type and
00106      *   source of the event
00107      * @param addr Return the address used for the given event type
00108      */
00109     void get_address (in RtecEventComm::EventHeader header,
00110                       out UDP_Address addr);
00111   };
00112 };
00113 
00114 #endif /* TAO_RTEC_UDP_ADMIN_IDL */

Generated on Tue Feb 2 17:44:06 2010 for TAO_RTEvent by  doxygen 1.4.7