net.jini.lookup
Interface DiscoveryAdmin


public abstract interface DiscoveryAdmin

Methods for controlling which groups a lookup service is a member of, and for controlling which TCP port a lookup service uses for its lookup locator. Lookup services that implement the Administrable interface should return an admin object that implements this interface.


Method Summary
 void addMemberGroups(java.lang.String[] groups)
          Add new groups for the lookup service to be a member of.
 java.lang.String[] getMemberGroups()
          Get the list of groups that the lookup service is a member of.
 int getUnicastPort()
          Get the port number on which the lookup service listens for unicast discovery queries.
 void removeMemberGroups(java.lang.String[] groups)
          Remove groups from list that the lookup service is a member of.
 void setMemberGroups(java.lang.String[] groups)
          Replace the list of groups to be a member of with a new list.
 void setUnicastPort(int port)
          Set the port number on which the lookup service listens for unicast discovery queries.
 

Method Detail

getMemberGroups

public java.lang.String[] getMemberGroups()
                                   throws java.rmi.RemoteException
Get the list of groups that the lookup service is a member of. An empty array means the lookup service is a member of no groups (as opposed to "all" groups).
Returns:
a String array of groups that the lookup service is a member of.
Throws:
java.rmi.RemoteException -  

addMemberGroups

public void addMemberGroups(java.lang.String[] groups)
                     throws java.rmi.RemoteException
Add new groups for the lookup service to be a member of.
Parameters:
groups - groups to be a member of
Throws:
java.rmi.RemoteException -  

removeMemberGroups

public void removeMemberGroups(java.lang.String[] groups)
                        throws java.rmi.RemoteException
Remove groups from list that the lookup service is a member of.
Parameters:
groups - groups to stop being a member of
Throws:
java.rmi.RemoteException -  

setMemberGroups

public void setMemberGroups(java.lang.String[] groups)
                     throws java.rmi.RemoteException
Replace the list of groups to be a member of with a new list.
Parameters:
groups - groups to be a member of
Throws:
java.rmi.RemoteException -  

getUnicastPort

public int getUnicastPort()
                   throws java.rmi.RemoteException
Get the port number on which the lookup service listens for unicast discovery queries.
Returns:
an int representing the port number on which the lookup service listens for unicast discovery queries.
Throws:
java.rmi.RemoteException -  

setUnicastPort

public void setUnicastPort(int port)
                    throws java.io.IOException,
                           java.rmi.RemoteException
Set the port number on which the lookup service listens for unicast discovery queries. A port of zero means the lookup service should first try to listen on the standard unicast discovery port, but if that fails, then it should listen on an arbitrary port.
Parameters:
port - the port number
Throws:
java.io.IOException -  
java.rmi.RemoteException -  


Copyright © 1999 Sun Microsystems, Inc. All rights reserved