Package muntjac :: Package data :: Package util :: Module abstract_container :: Class AbstractContainer
[hide private]
[frames] | no frames]

Class AbstractContainer

source code

          object --+    
                   |    
container.IContainer --+
                       |
                      AbstractContainer
Known Subclasses:

Abstract container class that manages event listeners and sending events to them (PropertySetChangeNotifier, ItemSetChangeNotifier).

Note that this class provides the internal implementations for both types of events and notifiers as protected methods, but does not implement the IPropertySetChangeNotifier and ItemSetChangeNotifier interfaces directly. This way, subclasses can choose not to implement them. Subclasses implementing those interfaces should also override the corresponding addListener and removeListener methods to make them public.

Instance Methods [hide private]
 
__init__(self)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
addListener(self, listener, iface=None)
Implementation of the corresponding method in IPropertySetChangeNotifier and ItemSetChangeNotifier, override and implement the interface to use this.
source code
 
addCallback(self, callback, eventType=None, *args) source code
 
removeListener(self, listener, iface=None)
Implementation of the corresponding method in IPropertySetChangeNotifier and ItemSetChangeNotifier, override and implement the interface to use this.
source code
 
removeCallback(self, callback, eventType=None) source code
 
fireContainerPropertySetChange(self, event=None)
Sends a simple Property set change event to all interested listeners.
source code
 
fireItemSetChange(self, event=None)
Sends a simple Item set change event to all interested listeners, indicating that anything in the contents may have changed (items added, removed etc.).
source code
 
setPropertySetChangeListeners(self, propertySetChangeListeners)
Sets the property set change listener collection.
source code
 
getPropertySetChangeListeners(self)
Returns the property set change listener collection.
source code
 
setItemSetChangeListeners(self, itemSetChangeListeners)
Sets the item set change listener collection.
source code
 
getItemSetChangeListeners(self)
Returns the item set change listener collection.
source code
 
getListeners(self, eventType) source code
 
getCallbacks(self, eventType) source code

Inherited from container.IContainer: addContainerProperty, addItem, containsId, getContainerProperty, getContainerPropertyIds, getItem, getItemIds, getType, removeAllItems, removeContainerProperty, removeItem, size

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

addListener(self, listener, iface=None)

source code 

Implementation of the corresponding method in IPropertySetChangeNotifier and ItemSetChangeNotifier, override and implement the interface to use this.

See Also:
IPropertySetChangeNotifier.addListener, IItemSetChangeNotifier.addListener

removeListener(self, listener, iface=None)

source code 

Implementation of the corresponding method in IPropertySetChangeNotifier and ItemSetChangeNotifier, override and implement the interface to use this.

See Also:
IPropertySetChangeNotifier.removeListener, ItemSetChangeNotifier.removeListener

fireContainerPropertySetChange(self, event=None)

source code 

Sends a simple Property set change event to all interested listeners.

Use fireContainerPropertySetChange instead of this method unless additional information about the exact changes is available and should be included in the event.

Parameters:
  • event - the property change event to send, optionally with additional information

fireItemSetChange(self, event=None)

source code 

Sends a simple Item set change event to all interested listeners, indicating that anything in the contents may have changed (items added, removed etc.).

Parameters:
  • event - the item set change event to send, optionally with additional information

setPropertySetChangeListeners(self, propertySetChangeListeners)

source code 

Sets the property set change listener collection. For internal use only.

getPropertySetChangeListeners(self)

source code 

Returns the property set change listener collection. For internal use only.

setItemSetChangeListeners(self, itemSetChangeListeners)

source code 

Sets the item set change listener collection. For internal use only.

getItemSetChangeListeners(self)

source code 

Returns the item set change listener collection. For internal use only.