]> git.llucax.com Git - software/posixx.git/commitdiff
Move tipc::event::type_t to tipc::event_t
authorLeandro Lucarella <llucarella@integratech.com.ar>
Fri, 27 Feb 2009 17:30:26 +0000 (15:30 -0200)
committerLeandro Lucarella <llucarella@integratech.com.ar>
Fri, 27 Feb 2009 18:46:15 +0000 (16:46 -0200)
Having nested constant definitions makes their use a little annoying.

src/linux/tipc.hpp

index 69bf4c085cac5839a20055c99a0b896dd07dd57c..01446a5e9793841cf88ac9540d53a989461b7cac 100644 (file)
@@ -168,9 +168,9 @@ enum reason_t
 enum subscr_t
 {
        /**
-        * Causes the topology service to generate a event::PUBLISHED event
+        * Causes the topology service to generate a PUBLISHED event
         * for each port name or port name sequence it finds that overlaps
-        * the specified port name sequence; a TIPC_WITHDRAWN event is issued
+        * the specified port name sequence; a WITHDRAWN event is issued
         * each time a previously reported name becomes unavailable.
         *
         * Allows the topology service to inform the application if there
@@ -209,6 +209,17 @@ struct subscr: tipc_subscr
                        const char* usr_handle = "") throw ();
 };
 
+/// Type of events.
+enum event_t
+{
+       /// The port has been published.
+       PUBLISHED = TIPC_PUBLISHED,
+       /// The port has been withdrawn.
+       WITHDRAWN = TIPC_WITHDRAWN,
+       /// The event has timed out.
+       TIMEOUT = TIPC_SUBSCR_TIMEOUT
+};
+
 /**
  * Event message.
  *
@@ -216,16 +227,6 @@ struct subscr: tipc_subscr
  */
 struct event: tipc_event
 {
-       /// Type of events.
-       enum type_t
-       {
-               /// The port has been published.
-               PUBLISHED = TIPC_PUBLISHED,
-               /// The port has been withdrawn.
-               WITHDRAWN = TIPC_WITHDRAWN,
-               /// The event has timed out.
-               TIMEOUT = TIPC_SUBSCR_TIMEOUT
-       };
 };
 
 /**