Package flumotion :: Package component :: Package bouncers :: Module bouncer :: Class Bouncer
[hide private]

Class Bouncer

source code

             object --+        
common.common.InitMixin --+    
    common.log.Loggable --+    
             object --+   |    
                      |   |    
        gobject.GObject --+    
    component.BaseComponent --+
Known Subclasses:

I am the base class for all bouncers.

Nested Classes [hide private]
child class of BaseComponentMedium componentMediumClass
the medium class to use for this component
Instance Methods [hide private]
A subclass should do as little as possible in its init method.
source code
setDomain(self, name) source code
getDomain(self) source code
typeAllowed(self, keycard)
Verify if the keycard is an instance of a Keycard class specified in the bouncer's keycardClasses variable.
source code
setEnabled(self, enabled) source code
authenticate(self, keycard) source code
do_authenticate(self, keycard)
Must be overridden by subclasses.
source code
hasKeycard(self, keycard) source code
addKeycard(self, keycard) source code
removeKeycard(self, keycard) source code
removeKeycardId(self, id) source code
expireAllKeycards(self) source code
expireKeycardId(self, id) source code

Inherited from component.BaseComponent: __init__, addMessage, adminCallRemote, do_check, do_setup, do_start, do_stop, emit, fixRenamedProperties, getMood, getName, getWorkerName, setMedium, setMood, setShutdownHook, setWorkerName, setup, start, stop

Inherited from common.log.Loggable: __providedBy__, debug, doLog, error, info, log, logFunction, logObjectName, warning, warningFailure

Inherited from gobject.GObject: __cmp__, __delattr__, __gdoc__, __gobject_init__, __hash__, __new__, __repr__, __setattr__, chain, connect, connect_after, connect_object, connect_object_after, disconnect, disconnect_by_func, emit_stop_by_name, freeze_notify, get_data, get_properties, get_property, handler_block, handler_block_by_func, handler_disconnect, handler_is_connected, handler_unblock, handler_unblock_by_func, notify, props, set_data, set_properties, set_property, stop_emission, thaw_notify, weak_ref

Inherited from object: __getattribute__, __reduce__, __reduce_ex__, __str__

Class Variables [hide private]
tuple of flumotion.common.keycards.Keycard class objects keycardClasses = ()
tuple of all classes of keycards this bouncer can authenticate, in order of preference
  logCategory = 'bouncer'
Implementors can provide a category to log their messages under.

Inherited from component.BaseComponent: __gtype__

Inherited from common.log.Loggable: __implemented__, __provides__

Instance Variables [hide private]

Inherited from component.BaseComponent: medium, name

Properties [hide private]

Inherited from gobject.GObject: __grefcount__

Inherited from object: __class__

Method Details [hide private]


source code 

A subclass should do as little as possible in its init method. In particular, it should not try to access resources.

Failures during init are marshalled back to the manager through the worker's remote_create method, since there is no component state proxied to the manager yet at the time of init.

Overrides: component.BaseComponent.init
(inherited documentation)

do_authenticate(self, keycard)

source code 

Must be overridden by subclasses.

Authenticate the given keycard. Return the keycard with state AUTHENTICATED to authenticate, with state REQUESTING to continue the authentication process, or None to deny the keycard, or a deferred which should have the same eventual value.