sharpster.common
Class KeyManager

java.lang.Object
  |
  +--sharpster.common.KeyManager

public class KeyManager
extends java.lang.Object

Class responsible for supplying unique keys for all users.


Constructor Summary
KeyManager()
          Constructs an instance of the class and initializes the member attributes.
 
Method Summary
 net.jxta.id.ID add(java.lang.String str, net.jxta.id.ID key)
          Adds a key value for the specified user.
 java.lang.String[] getAllValues()
           
 net.jxta.id.ID getKey(java.lang.String str)
          Returns the key value for the specified user.
 java.lang.String getValue(net.jxta.id.ID key)
          Returns the user for the given key value.
 void remove(java.lang.String str)
          Removes the key value for the specified user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KeyManager

public KeyManager()
Constructs an instance of the class and initializes the member attributes.

Method Detail

add

public net.jxta.id.ID add(java.lang.String str,
                          net.jxta.id.ID key)
Adds a key value for the specified user.


remove

public void remove(java.lang.String str)
Removes the key value for the specified user.


getKey

public net.jxta.id.ID getKey(java.lang.String str)
Returns the key value for the specified user.


getValue

public java.lang.String getValue(net.jxta.id.ID key)
Returns the user for the given key value.


getAllValues

public java.lang.String[] getAllValues()