parameters: (self, username)
docstring: Check if the database contains the specified username.
  
          @type username: str
          @param username: The username to check for.
  
          @rtype: bool
          @return: True if the database contains the username, False
          otherwise.
docstring_summary: Check if the database contains the specified username.
docstring_tokens: Check if the database contains the specified username .
function: def __contains__(self, username):
          """Check if the database contains the specified username.
  
          @type username: str
          @param username: The username to check for.
  
          @rtype: bool
          @return: True if the database contains the username, False
          otherwise.
  
          """
          if self.db == None:
              raise AssertionError("DB not open")
  
          self.lock.acquire()
          try:
              return self.db.has_key(username)
          finally:
              self.lock.release()
function_tokens: def __contains__ ( self , username ) : if self . db == None : raise AssertionError ( "DB not open" ) self . lock . acquire ( ) try : return self . db . has_key ( username ) finally : self . lock . release ( )