dermi
Class DHTHandler

java.lang.Object
  extended by dermi.DHTHandler

public class DHTHandler
extends java.lang.Object


Constructor Summary
DHTHandler(java.lang.String bunshinPropsPath, java.lang.String context, java.lang.String path, java.lang.String url, java.net.URL[] URLsList)
           
 
Method Summary
 void addLinks(Id id, java.util.Collection links)
          Puts the outgoing links of a specific identifier in the networks and notifier with a notify message to the id owners.
 java.util.Collection getIncomingLinks(Id key)
          Returns the incoming links of the specific key
 java.util.Collection getOutgoingLinks(Id key)
          Returns the outgoing links of the specific key
 void insert(Id id, java.io.Serializable value)
           
 void insert(java.lang.String str, java.io.Serializable value)
           
 void insert(java.lang.String keywords, java.lang.String key, java.io.Serializable value)
          SEARCH
 boolean insertSecure(Id id, java.io.Serializable value, java.lang.String pass)
          SECURE
 boolean insertSecure(Id id, java.io.Serializable value, java.lang.String pass, boolean getcheck)
          SECURE
 void insertURL(Id id, java.net.URL url)
           
 void leave()
           
 bunshin.util.ResultSortedQueue query(java.lang.String keywords)
           
 void remove(Id id, java.lang.String field)
           
 void remove(java.lang.String keywords, java.lang.String key)
           
 void removeLinkListener(Id id)
          Removes the remote callback which notifies the link updates
 void removeLinks(Id id, java.util.Collection links)
          Removes the outgoing links of a specific identifier in the networks and notifier with a notify message to the id owners.
 void removeURL(Id id)
           
 java.io.Serializable retrieve(Id id)
           
 java.io.Serializable retrieve(Id id, java.lang.String field)
           
 java.io.Serializable retrieve(java.lang.String key)
           
 java.io.Serializable retrieveSecure(Id id, java.lang.String pass)
           
 java.net.URL retrieveURL(Id id)
           
 void setLinkListener(Id id, bunshin.RemoteListener listener)
          Sets a remote callback which notifies the link updates
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DHTHandler

public DHTHandler(java.lang.String bunshinPropsPath,
                  java.lang.String context,
                  java.lang.String path,
                  java.lang.String url,
                  java.net.URL[] URLsList)
           throws RemoteException
Throws:
RemoteException
Method Detail

insert

public void insert(Id id,
                   java.io.Serializable value)
            throws RemoteException
Throws:
RemoteException

insert

public void insert(java.lang.String str,
                   java.io.Serializable value)
            throws RemoteException
Throws:
RemoteException

retrieve

public java.io.Serializable retrieve(Id id)
                              throws RemoteException
Throws:
RemoteException

retrieve

public java.io.Serializable retrieve(Id id,
                                     java.lang.String field)
                              throws RemoteException
Throws:
RemoteException

retrieve

public java.io.Serializable retrieve(java.lang.String key)
                              throws RemoteException
Throws:
RemoteException

remove

public void remove(Id id,
                   java.lang.String field)
            throws RemoteException
Throws:
RemoteException

insertURL

public void insertURL(Id id,
                      java.net.URL url)
               throws RemoteException
Throws:
RemoteException

retrieveURL

public java.net.URL retrieveURL(Id id)
                         throws RemoteException
Throws:
RemoteException

removeURL

public void removeURL(Id id)
               throws RemoteException
Throws:
RemoteException

insertSecure

public boolean insertSecure(Id id,
                            java.io.Serializable value,
                            java.lang.String pass)
                     throws RemoteException
SECURE

Throws:
RemoteException

insertSecure

public boolean insertSecure(Id id,
                            java.io.Serializable value,
                            java.lang.String pass,
                            boolean getcheck)
                     throws RemoteException
SECURE

Throws:
RemoteException

retrieveSecure

public java.io.Serializable retrieveSecure(Id id,
                                           java.lang.String pass)
                                    throws RemoteException
Throws:
RemoteException

insert

public void insert(java.lang.String keywords,
                   java.lang.String key,
                   java.io.Serializable value)
            throws RemoteException
SEARCH

Throws:
RemoteException

query

public bunshin.util.ResultSortedQueue query(java.lang.String keywords)
                                     throws RemoteException
Throws:
RemoteException

remove

public void remove(java.lang.String keywords,
                   java.lang.String key)
            throws RemoteException
Throws:
RemoteException

leave

public void leave()
           throws RemoteException
Throws:
RemoteException

addLinks

public void addLinks(Id id,
                     java.util.Collection links)
              throws RemoteException
Puts the outgoing links of a specific identifier in the networks and notifier with a notify message to the id owners.

Parameters:
Id - of the key
Collection - of the links ids
Throws:
RemoteException

removeLinks

public void removeLinks(Id id,
                        java.util.Collection links)
                 throws RemoteException
Removes the outgoing links of a specific identifier in the networks and notifier with a notify message to the id owners.

Parameters:
Id - of the key
Collection - of the links ids
Throws:
RemoteException

setLinkListener

public void setLinkListener(Id id,
                            bunshin.RemoteListener listener)
                     throws RemoteException
Sets a remote callback which notifies the link updates

Parameters:
Id - of the key
RemoteListener - callback
Throws:
RemoteException

removeLinkListener

public void removeLinkListener(Id id)
                        throws RemoteException
Removes the remote callback which notifies the link updates

Parameters:
Id - of the key
Throws:
RemoteException

getIncomingLinks

public java.util.Collection getIncomingLinks(Id key)
                                      throws RemoteException
Returns the incoming links of the specific key

Parameters:
Id - of the key
Collection - of the links ids
Throws:
RemoteException

getOutgoingLinks

public java.util.Collection getOutgoingLinks(Id key)
                                      throws RemoteException
Returns the outgoing links of the specific key

Parameters:
Id - of the key
Collection - of the links ids
Throws:
RemoteException