MCPcopy Create free account
hub / github.com/ClickHouse/ClickHouse / dispatchEvent

Method dispatchEvent

base/poco/XML/src/AbstractNode.cpp:248–272  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

246
247
248bool AbstractNode::dispatchEvent(Event* evt)
249{
250 if (eventsSuspended()) return true;
251
252 if (evt->type().empty()) throw EventException(EventException::UNSPECIFIED_EVENT_TYPE_ERR);
253
254 evt->setTarget(this);
255 evt->setCurrentPhase(Event::CAPTURING_PHASE);
256
257 if (_pParent) _pParent->captureEvent(evt);
258
259 if (_pEventDispatcher && !evt->isStopped())
260 {
261 evt->setCurrentPhase(Event::AT_TARGET);
262 evt->setCurrentTarget(this);
263 _pEventDispatcher->dispatchEvent(evt);
264 }
265 if (!evt->isStopped() && evt->bubbles() && _pParent)
266 {
267 evt->setCurrentPhase(Event::BUBBLING_PHASE);
268 _pParent->bubbleEvent(evt);
269 }
270
271 return evt->isCanceled();
272}
273
274
275void AbstractNode::captureEvent(Event* evt)

Callers

nothing calls this directly

Calls 10

setTargetMethod · 0.80
setCurrentPhaseMethod · 0.80
setCurrentTargetMethod · 0.80
bubblesMethod · 0.80
emptyMethod · 0.45
typeMethod · 0.45
captureEventMethod · 0.45
isStoppedMethod · 0.45
bubbleEventMethod · 0.45
isCanceledMethod · 0.45

Tested by

no test coverage detected