Axon.AdaptiveCommsComponent.py

Version: Axon 1.0

Pydoc Style Documentation

class AdaptiveCommsComponent(Axon.Component.component)

Method resolution order:

  • AdaptiveCommsComponent
  • Axon.Component.component
  • Axon.Microprocess.microprocess
  • Axon.Axon.AxonObject
  • __builtin__.object

Data and other attributes inherited from Axon.Component.component:

  • Inboxes = ['inbox', 'control']
  • Outboxes = ['outbox', 'signal']
  • Usescomponents = []

Methods defined here:

__init__(self)

  • # Public Methods

addInbox(self, *args)

  • Adds a custom inbox with the name requested - or the closest name possible. (appends an integer) Returns the name of the inbox added.

addOutbox(self, *args)

  • Adds a custom outbox with the name requested - or the closest name possible. (appends an integer) Returns the name of the outbox added.

trackResource(self, resource, inbox)

  • Tracks a _single_ resource associated with the inbox

trackResourceInformation(self, resource, inboxes, outboxes, information)

  • Provides a lookup service associating inboxes/outboxes & user information with a resource. Uses GIGO principle.

retrieveTrackedResource(self, inbox)

  • Retrieves a single resource associated with the inbox

retrieveTrackedResourceInformation(self, resource)

  • retrieveTrackedResourceInformation(self, resource) -> informationBundle ( {inboxes, outboxes,otherdata} ) (Uses GIGO principle.)

ceaseTrackingResource(self, resource)

  • Stop tracking a resource and release references to it

deleteInbox(self, name)

  • Deletes the named inbox

deleteOutbox(self, name)

  • Deletes the named outbox

Testdoc Documentation

__init__

  • Called with no arguments is expected, results in component superconstructor being called. performs no local initialisation
  • Called with with arguments causes TypeError exception

addInbox

  • adding an inbox with a completely new name results in that inbox being created/added
  • adding an inbox with an existing name results in an inbox being created/added with a similar name - same name with a suffix

addOutbox

  • adding an outbox with a completely new name results in that outbox being created/added
  • adding an outbox with an existing name results in an outbox being created/added with a similar name - same name with a suffix

deleteInbox

  • Deletes the named inbox
  • KeyError exception raised if you try to delete an inbox that does not exist - this includes the case of an already deleted Inbox

deleteOutbox

  • Deletes the named outbox
  • KeyError exception raised if you try to delete an outbox that does not exist - this includes the case of an already deleted Outbox

trackResource,retrieveTrackedResource

  • Adds to & retrieves from the mapping of inbox -> resource to a local store. This allows retrieval of the resource based on which inbox messages arrive on. Whilst designed for custom inboxes, it should work with the 'default' inboxes for a component
  • Tracking resources using a custom dynamic inbox name should work.
  • Tracking resources using an invalid inbox name should fail.

trackResourceInformation, retrieveTrackedResourceInformation

  • Associates communication & user aspects related to a resource. Associating default in/out boxes with a resource is valid
  • Associates communication & user aspects related to a resource. Associating dynamically created in/out boxes with a resource is the default
  • Tracking invalid inboxes using a resource fails.
  • Tracking invalid outboxes using a resource fails.

Michael, December 2004

 

Kamaelia is an open source project originated from and guided by BBC Research. For more information browse the site or get in contact.

This is an ongoing community based development site. As a result the contents of this page is the opinions of the contributors of the pages involved not the organisations involved. Specificially, this page may contain personal views which are not the views of the BBC. (the site is powered by a wiki engine)

(C) Copyright 2008 Kamaelia Contributors, including the British Broadcasting Corporation, All Rights Reserved

This web site is powered by the same code created for the bicker manor project. For more details, contact Michael Sparks at BBC Research directly (cf contact)