ACE_Task_Ex<, ACE_MESSAGE_TYPE > Class Template ReferencePrimary interface for application message processing, as well as input and output message queueing. More...
Inheritance diagram for ACE_Task_Ex<, ACE_MESSAGE_TYPE >:
![]()
Collaboration diagram for ACE_Task_Ex<, ACE_MESSAGE_TYPE >:
![]()
Detailed Descriptiontemplate<ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE>
Primary interface for application message processing, as well as input and output message queueing.
|
typedef ACE_Message_Queue_Ex<ACE_MESSAGE_TYPE, ACE_SYNCH_USE> ACE_Task_Ex<, ACE_MESSAGE_TYPE >::MESSAGE_QUEUE_EX |
ACE_Task_Ex<, ACE_MESSAGE_TYPE >::ACE_Task_Ex | ( | ACE_Thread_Manager * | thr_mgr = 0 , |
|
MESSAGE_QUEUE_EX * | mq = 0 | |||
) | [inline] |
Initialize a Task, supplying a thread manager and a message queue. If the user doesn't supply a ACE_Message_Queue pointer then we'll allocate one dynamically. Otherwise, we'll use the one passed as a parameter.
ACE_Task_Ex<, ACE_MESSAGE_TYPE >::~ACE_Task_Ex | ( | void | ) | [inline, virtual] |
Destructor.
ACE_Task_Ex<, ACE_MESSAGE_TYPE >::ACE_Task_Ex | ( | const ACE_Task_Ex< _ACE_SYNCH, ACE_MESSAGE_TYPE > & | ) | [private] |
ACE_Message_Queue_Ex< ACE_MESSAGE_TYPE, ACE_SYNCH_USE > * ACE_Task_Ex<, ACE_MESSAGE_TYPE >::msg_queue | ( | void | ) | [inline] |
Gets the message queue associated with this task.
ACE_INLINE void ACE_Task_Ex<, ACE_MESSAGE_TYPE >::msg_queue | ( | MESSAGE_QUEUE_EX * | mq | ) | [inline] |
Sets the message queue associated with this task.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::putq | ( | ACE_MESSAGE_TYPE * | mb, | |
ACE_Time_Value * | timeout = 0 | |||
) | [inline] |
Insert message into the message queue. Note that timeout uses <{absolute}> time rather than <{relative}> time.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::getq | ( | ACE_MESSAGE_TYPE *& | mb, | |
ACE_Time_Value * | timeout = 0 | |||
) | [inline] |
Extract the first message from the queue (blocking). Note that timeout uses <{absolute}> time rather than <{relative}> time. Returns number of items in queue if the call succeeds or -1 otherwise.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::ungetq | ( | ACE_MESSAGE_TYPE * | mb, | |
ACE_Time_Value * | timeout = 0 | |||
) | [inline] |
Return a message to the queue. Note that timeout uses <{absolute}> time rather than <{relative}> time.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::reply | ( | ACE_MESSAGE_TYPE * | mb, | |
ACE_Time_Value * | timeout = 0 | |||
) | [inline] |
Turn the message around and send it back down the Stream. Note that timeout uses <{absolute}> time rather than <{relative}> time.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::put_next | ( | ACE_MESSAGE_TYPE * | msg, | |
ACE_Time_Value * | timeout = 0 | |||
) | [inline] |
Transfer message to the adjacent ACE_Task_Ex in a ACE_Stream. Note that timeout uses <{absolute}> time rather than <{relative}> time.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::can_put | ( | ACE_MESSAGE_TYPE * | ) | [inline] |
Tests whether we can enqueue a message without blocking.
const ACE_TCHAR * ACE_Task_Ex<, ACE_MESSAGE_TYPE >::name | ( | void | ) | const [inline] |
Return the name of the enclosing Module if there's one associated with the Task, else returns 0.
ACE_INLINE ACE_Task< ACE_SYNCH_USE > * ACE_Task_Ex<, ACE_MESSAGE_TYPE >::next | ( | void | ) | [inline] |
Get next Task pointer.
ACE_INLINE void ACE_Task_Ex<, ACE_MESSAGE_TYPE >::next | ( | ACE_Task< ACE_SYNCH_USE > * | q | ) | [inline] |
Set next Task pointer.
ACE_Task< ACE_SYNCH_USE > * ACE_Task_Ex<, ACE_MESSAGE_TYPE >::sibling | ( | void | ) | [inline] |
ACE_Module< ACE_SYNCH_USE > * ACE_Task_Ex<, ACE_MESSAGE_TYPE >::module | ( | void | ) | const [inline] |
Return the Task's Module if there is one, else returns 0.
ACE_INLINE int ACE_Task_Ex<, ACE_MESSAGE_TYPE >::flush | ( | u_long | flag = ACE_Task_Flags::ACE_FLUSHALL |
) | [inline] |
Flush the task's queue, i.e., free all of the enqueued message blocks and releases any threads blocked on the queue. Note that if this conflicts with the C++ iostream <flush> function, just rewrite the iostream function as ::<flush>.
ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE void ACE_Task_Ex<, ACE_MESSAGE_TYPE >::water_marks | ( | ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds | cmd, | |
size_t | wm_size | |||
) | [inline] |
Manipulate watermarks.
ACE_BEGIN_VERSIONED_NAMESPACE_DECL void ACE_Task_Ex<, ACE_MESSAGE_TYPE >::dump | ( | void | ) | const [inline] |
Dump the state of an object.
void ACE_Task_Ex<, ACE_MESSAGE_TYPE >::operator= | ( | const ACE_Task_Ex< _ACE_SYNCH, ACE_MESSAGE_TYPE > & | ) | [private] |
friend class ACE_Module< ACE_SYNCH_USE > [friend] |
friend class ACE_Module_Type [friend] |
MESSAGE_QUEUE_EX* ACE_Task_Ex<, ACE_MESSAGE_TYPE >::msg_queue_ |
Queue of messages on the ACE_Task..
bool ACE_Task_Ex<, ACE_MESSAGE_TYPE >::delete_msg_queue_ |
true if should delete Message_Queue, false otherwise.
ACE_Module<ACE_SYNCH_USE>* ACE_Task_Ex<, ACE_MESSAGE_TYPE >::mod_ |
Back-pointer to the enclosing module.
ACE_Task<ACE_SYNCH_USE>* ACE_Task_Ex<, ACE_MESSAGE_TYPE >::next_ |
Pointer to adjacent ACE_Task.
ACE_Task_Ex<, ACE_MESSAGE_TYPE >::ACE_ALLOC_HOOK_DECLARE |
Declare the dynamic allocation hooks.