3 //=============================================================================
5 * @file LF_Invocation_Event.h
7 * @author Carlos O'Ryan <coryan@uci.edu>
9 //=============================================================================
11 #ifndef TAO_LF_INVOCATION_EVENT_H
12 #define TAO_LF_INVOCATION_EVENT_H
14 #include /**/ "ace/pre.h"
16 #include "tao/LF_Event.h"
18 #if !defined (ACE_LACKS_PRAGMA_ONCE)
20 #endif /* ACE_LACKS_PRAGMA_ONCE */
22 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
25 * @class TAO_LF_Invocation_Event
27 * @brief Use the Leader/Follower loop to wait for one specific event
28 * in the invocation path.
30 * Concrete event types and manipulation class through which the
31 * invocation data path would flow. Typically state changes of
32 * interest include whether a message has arrived, or timedout waiting
33 * for a message or if the connection is closed waiting for a
34 * message. Details of the states are documented within the class.
36 class TAO_Export TAO_LF_Invocation_Event
: public TAO_LF_Event
40 TAO_LF_Invocation_Event (void);
43 virtual ~TAO_LF_Invocation_Event (void);
46 /// Validate and perform the state change
48 * This concrete class uses the following states declared in the
51 * LFS_IDLE - The event is created, and is in initial state.
52 * LFS_ACTIVE - The event is active and it can transition to any of
53 * the following states, all the states are final.
54 * LFS_SUCCESS - The event has completed successfully.
55 * LFS_FAILURE - A failure has been detected while the event was
57 * LFS_TIMEOUT - The event has timed out.
58 * LFS_CONNECTION_CLOSED - The connection was closed when the state
61 virtual void state_changed_i (LFS_STATE new_state
);
63 /// Return true if the condition was satisfied successfully, false if it
65 virtual bool successful_i (void) const;
67 /// Return true if an error was detected while waiting for the
69 virtual bool error_detected_i (void) const;
72 /// Check whether we have reached the final state..
73 bool is_state_final (void) const;
76 TAO_END_VERSIONED_NAMESPACE_DECL
78 #include /**/ "ace/post.h"
80 #endif /* TAO_LF_INVOCATION_EVENT_H */