| 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface IServerAdmin
This interface contains all the administrative methods that the proxy provides to control the server.
 Usage:
        IPojoSpace space = (IPojoSpace)SpaceFinder.find(spaceUrl);
        IServerAdmin serverAdmin = space.getServerAdmin();
 
 The code examples on each method assumes the above usage.
 
IPojoSpace.getServerAdmin(), 
IRemoteJSpaceAdmin| Method Summary | |
|---|---|
 void | 
clean()
Cleans this space.  | 
 void | 
dropClass(String className)
Drops all Class's entries and all its templates from the space.  | 
 Object | 
getAdmin()
Returns the admin object to the remote part of this space.  | 
 IJSpaceContainer | 
getContainer()
Returns the container proxy this space resides in.  | 
 String | 
getName()
Returns the name of this space.  | 
 Uuid | 
getReferentUuid()
Returns the unique Uuid of this space instance. | 
 IStubHandler | 
getStubHandler()
Returns the StubHandler of this space.  | 
 SpaceURL | 
getURL()
Returns the SpaceURL instance which was used to initialize the space. | 
 boolean | 
isEmbedded()
Checks whether proxy is connected to embedded or remote space.  | 
 void | 
ping()
Checks whether the space is alive and accessible.  | 
| Method Detail | 
|---|
String getName()
 String name = serverAdmin.getName();
 
IJSpaceContainer.getName()
void clean()
           throws RemoteException
 serverAdmin.clean();
 
RemoteException - if a communication error occurs
void ping()
          throws RemoteException
 try{
    serverAdmin.ping();
    System.out.println("Space alive");
 }
 catch (java.rmi.RemoteException re) {
    System.out.println("Space unreachable");
 }
 
RemoteException - when space was unreachableIJSpaceContainer getContainer()
Object getAdmin()
                throws RemoteException
 // get a list of classes and the number of entries of each class
 IRemoteJSpaceAdmin remoteAdmin = (IRemoteJSpaceAdmin)serverAdmin.getAdmin();
 Object classList[] = remoteAdmin.getRuntimeInfo().m_ClassNames.toArray();
 List numOFEntries = remoteAdmin.getRuntimeInfo().m_NumOFEntries;
 
RemoteException - if a communication error occurs
void dropClass(String className)
               throws RemoteException,
                      DropClassException
 Message message = new Message("Hello");
 Lease lease = space.write(message, null, Lease.FOREVER);
 serverAdmin.dropClass( Message.class.getName());
 
className - name of class to delete.
DropClassException - Failed to drop desired class.
RemoteException - if a communication error occursPojoSpace#clear(Object, Transaction), 
IJSpace.clear(Entry, Transaction)boolean isEmbedded()
true if the proxy embedded, otherwise false.SpaceURL getURL()
SpaceURL instance which was used to initialize the space.
 
 Notice: The SpaceURL object contains information on the space and container
 configuration/setup such as space url used, space/container/cluster schema used
 and other attributes.
 In case of a clustered proxy, the returned SpaceURL object is associated to the space
 which initialized this proxy.
 The IJSpaceContainer keeps also its reference of the SpaceURL which launched the container.
SpaceURL which initialized that specific space instance.IStubHandler getStubHandler()
Uuid getReferentUuid()
Uuid of this space instance.
Uuid of the spaceReferentUuid
  | 
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||