Table of Contents

Class: MessageBuffer Collaboratory/Hub.py

This class represents a buffer that will store all the messages that pass through the hub. Thus, when a user signs on to an already-in-progress collaboratory session, these messages can be sent to the user, thus updating their state to that of the other collaboratory users

Methods   
__init__
addMessages
deleteAllMessages
filter
getMessages
getSize
getUserState
hasOpenedMsg
setUserState
  __init__ 
__init__ ( self,  parent )

  addMessages 
addMessages ( self,  messages )

  deleteAllMessages 
deleteAllMessages ( self )

When all users disconnect from the hub, it is assumed that the collab session is over, so delete all the stored messages in the hub

  filter 
filter ( self,  messages )

Possibly could find a more memory-efficient method of filtering, but not sure how that would work using for msg in messages loop and deleting as you go along instead of building new list

  getMessages 
getMessages ( self,  start )

  getSize 
getSize ( self )

  getUserState 
getUserState ( self,  user )

  hasOpenedMsg 
hasOpenedMsg ( self )

  setUserState 
setUserState (
        self,
        user,
        pos,
        )


Table of Contents

This document was automatically generated on Wed Mar 26 19:02:06 2003 by HappyDoc version 2.1