Package AccessGrid :: Module SharedApplication :: Class SharedApplication
[show private | hide private]
[frames | no frames]

Class SharedApplication


SharedApplication is the implementation class for an application

Method Summary
  __init__(self, name, description, mimeType, eventService, id)
An application object.
  AsApplicationDescription(self)
Return an application description, used in the rollup of venue state for the return from the Venue.Enter call.
  AsINIBlock(self)
  Awaken(self, eventService)
  GetComponents(self, private_token)
  GetData(self, private_token, key)
  GetDataChannel(self, private_token)
Return the channel id and location of the...
  GetDataKeys(self, private_token)
Access method for retreiving all keys for application data.
  GetEventServiceLocation(self)
  GetHandle(self)
  GetId(self)
  GetParticipants(self, private_token)
Returns a list of AppParticipantDescriptions that have client profile set.
  GetState(self, private_token)
Return the state of this application, used in the rollup of venue state for the return from the Venue.Enter call.
  GetVenueURL(self, private_token)
Return the url of the venue this app object is in.
  Join(self, clientProfile)
  Leave(self, private_token)
  SetData(self, private_token, key, value)
  SetHandle(self, handle)
Sets the web service handle that this app is listening on.
  SetParticipantProfile(self, private_token, profile)
Sets profile of participant associated with private_token **Arguments** *profile* New client profile.
  SetParticipantStatus(self, private_token, status)
Sets status of participant associated with private_token **Arguments** *status* New status value.
  SetVenueURL(self, url)
  Shutdown(self)
Shut down the applications before it is destroyed.

Method Details

__init__(self, name, description, mimeType, eventService, id=None)
(Constructor)

An application object.

Member variables:
    name - The name of this application.

    description - Description of the application. Format chosen by the app.

    eventService - Handle to the local event service object

    components - Dictionary of application components. key is the private
    id of the component. Value is the profile for the component.

    channels - List of channels that have been created for this app.

    app_data - Dictionary containing application's internal data.

    id - Unique identifier for this application.

Persistence policy.

We do not keep the list of components in persistent
storage. However, we do keep the set of channel names. When
the app object is reawakened, it will recreate event channels
for each of the channels that were registered.

AsApplicationDescription(self)

Return an application description, used in the rollup of
venue state for the return from the Venue.Enter call.

GetDataChannel(self, private_token)

Return the channel id and location of the
application object's data channel

GetDataKeys(self, private_token)

Access method for retreiving all keys for application data.

**Returns**

*[key]* List of all keys for application data

GetParticipants(self, private_token)

Returns a list of AppParticipantDescriptions that have client profile set.

GetState(self, private_token)

Return the state of this application, used in the rollup of
venue state for the return from the Venue.Enter call.

The state is a dictionary with the following keys defined:

   name - name of the application
   description - an application-defined description of the application
   id - the unique identifier for this application instance
   mimeType - description of data type handled by this application
   url - the web service endpoint for this application object
   data - the application's data storage, itself a dictionary.

GetVenueURL(self, private_token)

Return the url of the venue this app object is in.

SetHandle(self, handle)

Sets the web service handle that this app is listening on.

SetParticipantProfile(self, private_token, profile)

Sets profile of participant associated with private_token

**Arguments**

*profile* New client profile.

SetParticipantStatus(self, private_token, status)

Sets status of participant associated with private_token

**Arguments**

*status* New status value.

Shutdown(self)

Shut down the applications before it is destroyed.

Generated by Epydoc 2.1 on Mon Jan 09 13:23:46 2006 http://epydoc.sf.net