LLDB mainline
|
#include <Broadcaster.h>
Public Member Functions | |
~BroadcasterManager ()=default | |
lldb::ListenerSP | GetListenerForEventSpec (const BroadcastEventSpec &event_spec) const |
void | SignUpListenersForBroadcaster (Broadcaster &broadcaster) |
void | RemoveListener (const lldb::ListenerSP &listener_sp) |
void | RemoveListener (Listener *listener) |
void | Clear () |
Static Public Member Functions | |
static lldb::BroadcasterManagerSP | MakeBroadcasterManager () |
Listeners hold onto weak pointers to their broadcaster managers. | |
Protected Member Functions | |
BroadcasterManager () | |
Private Types | |
typedef std::pair< BroadcastEventSpec, lldb::ListenerSP > | event_listener_key |
typedef std::map< BroadcastEventSpec, lldb::ListenerSP > | collection |
typedef std::set< lldb::ListenerSP > | listener_collection |
Private Member Functions | |
uint32_t | RegisterListenerForEventsNoLock (const lldb::ListenerSP &listener_sp, const BroadcastEventSpec &event_spec) |
bool | UnregisterListenerForEventsNoLock (const lldb::ListenerSP &listener_sp, const BroadcastEventSpec &event_spec) |
Private Attributes | |
collection | m_event_map |
listener_collection | m_listeners |
std::mutex | m_manager_mutex |
Friends | |
class | Listener |
Definition at line 74 of file Broadcaster.h.
|
private |
Definition at line 110 of file Broadcaster.h.
|
private |
Definition at line 109 of file Broadcaster.h.
|
private |
Definition at line 111 of file Broadcaster.h.
|
protected |
Definition at line 388 of file Broadcaster.cpp.
Referenced by MakeBroadcasterManager().
|
default |
void BroadcasterManager::Clear | ( | ) |
Definition at line 543 of file Broadcaster.cpp.
References m_event_map, m_listeners, and m_manager_mutex.
ListenerSP BroadcasterManager::GetListenerForEventSpec | ( | const BroadcastEventSpec & | event_spec | ) | const |
Definition at line 462 of file Broadcaster.cpp.
References m_event_map, and m_manager_mutex.
|
static |
Listeners hold onto weak pointers to their broadcaster managers.
So they must be made into shared pointers, which you do with MakeBroadcasterManager.
Definition at line 390 of file Broadcaster.cpp.
References BroadcasterManager().
|
private |
Definition at line 394 of file Broadcaster.cpp.
References lldb_private::BroadcastEventSpec::GetBroadcasterClass(), lldb_private::BroadcastEventSpec::GetEventBits(), m_event_map, and m_listeners.
void BroadcasterManager::RemoveListener | ( | const lldb::ListenerSP & | listener_sp | ) |
Definition at line 503 of file Broadcaster.cpp.
References m_event_map, m_listeners, and m_manager_mutex.
void BroadcasterManager::RemoveListener | ( | Listener * | listener | ) |
Definition at line 478 of file Broadcaster.cpp.
References m_event_map, m_listeners, and m_manager_mutex.
void BroadcasterManager::SignUpListenersForBroadcaster | ( | Broadcaster & | broadcaster | ) |
Definition at line 524 of file Broadcaster.cpp.
References lldb_private::Broadcaster::GetBroadcasterClass(), m_event_map, and m_manager_mutex.
|
private |
Definition at line 420 of file Broadcaster.cpp.
References lldb_private::BroadcastEventSpec::GetBroadcasterClass(), lldb_private::BroadcastEventSpec::GetEventBits(), m_event_map, and m_listeners.
|
friend |
Definition at line 77 of file Broadcaster.h.
|
private |
Definition at line 112 of file Broadcaster.h.
Referenced by Clear(), GetListenerForEventSpec(), RegisterListenerForEventsNoLock(), RemoveListener(), SignUpListenersForBroadcaster(), and UnregisterListenerForEventsNoLock().
|
private |
Definition at line 113 of file Broadcaster.h.
Referenced by Clear(), RegisterListenerForEventsNoLock(), RemoveListener(), and UnregisterListenerForEventsNoLock().
|
mutableprivate |
Definition at line 115 of file Broadcaster.h.
Referenced by Clear(), GetListenerForEventSpec(), RemoveListener(), and SignUpListenersForBroadcaster().