Function tor_events::event_has_subscribers
source · [−]pub fn event_has_subscribers(kind: TorEventKind) -> boolExpand description
Returns a boolean indicating whether the event kind has any subscribers (as in,
whether TorEventReceiver::subscribe has been called with that event kind).
This is useful to avoid doing work to generate events that might be computationally expensive to generate.