OpenDDS
Snapshot(2023/04/07-19:43)
|
#include <PerConnectionSynch.h>
Public Member Functions | |
PerConnectionSynch (ThreadSynchResource *synch_resource, long priority, long scheduler) | |
virtual | ~PerConnectionSynch () |
virtual void | work_available () |
virtual int | open (void *) |
virtual int | svc () |
virtual int | close (u_long) |
![]() | |
ACE_Task_Base (ACE_Thread_Manager *=0) | |
virtual | ~ACE_Task_Base (void) |
virtual int | module_closed (void) |
virtual int | put (ACE_Message_Block *, ACE_Time_Value *=0) |
virtual int | activate (long flags=THR_NEW_LWP|THR_JOINABLE|THR_INHERIT_SCHED, int n_threads=1, int force_active=0, long priority=ACE_DEFAULT_THREAD_PRIORITY, int grp_id=-1, ACE_Task_Base *task=0, ACE_hthread_t thread_handles[]=0, void *stack[]=0, size_t stack_size[]=0, ACE_thread_t thread_ids[]=0, const char *thr_name[]=0) |
virtual int | wait (void) |
virtual int | suspend (void) |
virtual int | resume (void) |
int | grp_id (void) const |
void | grp_id (int) |
ACE_Thread_Manager * | thr_mgr (void) const |
void | thr_mgr (ACE_Thread_Manager *) |
int | is_reader (void) const |
int | is_writer (void) const |
size_t | thr_count (void) const |
ACE_thread_t | last_thread (void) const |
![]() | |
ACE_Service_Object (ACE_Reactor *=0) | |
virtual | ~ACE_Service_Object (void) |
![]() | |
virtual | ~ACE_Event_Handler (void) |
virtual ACE_HANDLE | get_handle (void) const |
virtual void | set_handle (ACE_HANDLE) |
virtual int | priority (void) const |
virtual void | priority (int priority) |
virtual int | handle_input (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
virtual int | handle_output (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
virtual int | handle_exception (ACE_HANDLE fd=ACE_INVALID_HANDLE) |
virtual int | handle_timeout (const ACE_Time_Value ¤t_time, const void *act=0) |
virtual int | handle_exit (ACE_Process *) |
virtual int | handle_close (ACE_HANDLE handle, ACE_Reactor_Mask close_mask) |
virtual int | handle_signal (int signum, siginfo_t *=0, ucontext_t *=0) |
virtual int | resume_handler (void) |
virtual int | handle_qos (ACE_HANDLE=ACE_INVALID_HANDLE) |
virtual int | handle_group_qos (ACE_HANDLE=ACE_INVALID_HANDLE) |
virtual void | reactor (ACE_Reactor *reactor) |
virtual ACE_Reactor * | reactor (void) const |
virtual ACE_Reactor_Timer_Interface * | reactor_timer_interface (void) const |
virtual Reference_Count | add_reference (void) |
virtual Reference_Count | remove_reference (void) |
Reference_Counting_Policy & | reference_counting_policy (void) |
![]() | |
ACE_Shared_Object (void) | |
virtual | ~ACE_Shared_Object (void) |
virtual int | init (int argc, ACE_TCHAR *argv[]) |
virtual int | fini (void) |
virtual int | info (ACE_TCHAR **info_string, size_t length=0) const |
![]() | |
virtual | ~ThreadSynch () |
int | register_worker (ThreadSynchWorker &worker) |
void | unregister_worker () |
Our owner, the worker_, is breaking our relationship. More... | |
Protected Member Functions | |
virtual int | register_worker_i () |
virtual void | unregister_worker_i () |
![]() | |
ACE_Event_Handler (ACE_Reactor *=0, int priority=ACE_Event_Handler::LO_PRIORITY) | |
![]() | |
ThreadSynch (ThreadSynchResource *resource) | |
int | wait_on_clogged_resource () |
WeakRcHandle< ThreadSynchWorker > | worker () |
Access the worker implementation directly. More... | |
Private Types | |
typedef ACE_SYNCH_MUTEX | LockType |
typedef ACE_Guard< LockType > | GuardType |
typedef ConditionVariable< LockType > | ConditionVariableType |
Private Attributes | |
LockType | lock_ |
ConditionVariableType | condition_ |
int | work_available_ |
int | shutdown_ |
long | dds_priority_ |
long | scheduler_ |
Definition at line 23 of file PerConnectionSynch.h.
|
private |
Definition at line 47 of file PerConnectionSynch.h.
|
private |
Definition at line 46 of file PerConnectionSynch.h.
|
private |
Definition at line 45 of file PerConnectionSynch.h.
ACE_INLINE OpenDDS::DCPS::PerConnectionSynch::PerConnectionSynch | ( | ThreadSynchResource * | synch_resource, |
long | priority, | ||
long | scheduler | ||
) |
Definition at line 11 of file PerConnectionSynch.inl.
References DBG_ENTRY_LVL.
|
virtual |
|
virtual |
Reimplemented from ACE_Task_Base.
Definition at line 170 of file PerConnectionSynch.cpp.
References DBG_ENTRY_LVL.
|
virtual |
Reimplemented from ACE_Task_Base.
Definition at line 34 of file PerConnectionSynch.cpp.
References ACE_DEBUG, ACE_TEXT(), ACE_Task_Base::activate(), DBG_ENTRY_LVL, OpenDDS::DCPS::DCPS_debug_level, dds_priority_, LM_DEBUG, scheduler_, and shutdown_.
Referenced by register_worker_i().
|
protectedvirtual |
The default implementation is to do nothing here. The subclass may override the implementation in order to do something when the worker registers. Returns 0 for success, -1 for failure.
Reimplemented from OpenDDS::DCPS::ThreadSynch.
Definition at line 177 of file PerConnectionSynch.cpp.
References DBG_ENTRY_LVL, and open().
|
virtual |
Reimplemented from ACE_Task_Base.
Definition at line 64 of file PerConnectionSynch.cpp.
References condition_, DBG_ENTRY_LVL, LM_DEBUG, lock_, shutdown_, SIG_SETMASK, ACE_OS::sigfillset(), TheServiceParticipant, ACE_OS::thr_sigsetmask(), VDBG, VDBG_LVL, OpenDDS::DCPS::ConditionVariable< Mutex >::wait(), OpenDDS::DCPS::ThreadSynch::wait_on_clogged_resource(), work_available_, OpenDDS::DCPS::ThreadSynchWorker::WORK_OUTCOME_BROKEN_RESOURCE, OpenDDS::DCPS::ThreadSynchWorker::WORK_OUTCOME_CLOGGED_RESOURCE, OpenDDS::DCPS::ThreadSynchWorker::WORK_OUTCOME_NO_MORE_TO_DO, and OpenDDS::DCPS::ThreadSynch::worker().
|
protectedvirtual |
The default implementation is to do nothing here. The subclass may override the implementation in order to do something when the worker unregisters.
Reimplemented from OpenDDS::DCPS::ThreadSynch.
Definition at line 184 of file PerConnectionSynch.cpp.
References condition_, DBG_ENTRY_LVL, lock_, OpenDDS::DCPS::ConditionVariable< Mutex >::notify_one(), shutdown_, TheServiceParticipant, and ACE_Task_Base::wait().
|
virtual |
The ThreadSynchWorker would like to have its perform_work() called from the appropriate thread once the ThreadSynchResource claims that it is_ready_for_work().
Implements OpenDDS::DCPS::ThreadSynch.
Definition at line 25 of file PerConnectionSynch.cpp.
References condition_, DBG_ENTRY_LVL, lock_, OpenDDS::DCPS::ConditionVariable< Mutex >::notify_one(), and work_available_.
|
private |
Definition at line 50 of file PerConnectionSynch.h.
Referenced by svc(), unregister_worker_i(), and work_available().
|
private |
Definition at line 53 of file PerConnectionSynch.h.
Referenced by open().
|
private |
Definition at line 49 of file PerConnectionSynch.h.
Referenced by svc(), unregister_worker_i(), and work_available().
|
private |
Definition at line 54 of file PerConnectionSynch.h.
Referenced by open().
|
private |
Definition at line 52 of file PerConnectionSynch.h.
Referenced by open(), svc(), and unregister_worker_i().
|
private |
Definition at line 51 of file PerConnectionSynch.h.
Referenced by svc(), and work_available().