Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    1. COThe shortcoming I see with Deffered in this scenario is it that it by design is fired only once, and is no replacement for permanent or semi permanent event subscription. Also I know of that EventDispatcher; however I would suspect that something so trivial as EventDispatcher should be more of a core package rather than a part of a specific funcionality set. This is what raised my doubts if EventDispatchers are needed in twisted at all or is there a more elegant solution to this.
      singulars
    2. COThe abstract use case to better illustrate the sample would be: say I am developing a network monitoring app, where every monitored element is an actual Instance in twisted. Now every Instance should be aware of the devices it depends upon, and should be able a) upon the start of observation be able to place event listeners against events triggered by other Instances, and b) upon the end of observation to remove those listeners. This means that event wise we will have multiple-2-multiple type relationships, relationships will change in runtime and events are recurring.
      singulars
    3. COIMHO, you can collect all the events to a dispather, and dispatch the events to any instance subcribe for it . There are already many dispatchers in python world, e.g. http://pubsub.sourceforge.net. In other words, event-in-function of the dipatcher is a callback of twisted mechanism. And to make things safter, you may do "dispatching" work in the end of event-in-function.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload