|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
@Deprecated public interface IJSpaceContainer
IJSpace
,
SpaceFinder
Method Summary | |
---|---|
IJSpace |
createSpace(String spaceName,
com.j_spaces.core.JSpaceAttributes spaceAttr)
Deprecated. |
void |
destroySpace(String spaceName)
Deprecated. |
IJSpace |
getClusteredSpace(String spaceName)
Deprecated. |
String |
getName()
Deprecated. Returns the name of this container. |
IJSpace |
getSpace(String spaceName)
Deprecated. |
com.j_spaces.core.JSpaceAttributes |
getSpaceAttributes(String spaceName)
Deprecated. |
String[] |
getSpaceNames()
Deprecated. |
SpaceURL |
getURL()
Deprecated. Returns the SpaceURL instance which was used to initialize the space. |
boolean |
isEmbedded()
Deprecated. Checks if the container is embedded. |
void |
ping()
Deprecated. Checks whether the container is alive and accessible. |
void |
shutdown()
Deprecated. |
Methods inherited from interface com.sun.jini.start.ServiceProxyAccessor |
---|
getServiceProxy |
Method Detail |
---|
@Deprecated IJSpace createSpace(String spaceName, com.j_spaces.core.JSpaceAttributes spaceAttr) throws CreateException, RemoteException
CreateException
will be thrown. The created space will be registered with all discovered Lookup Services
in the network.
// get proxy of container
// containerUrl of the form: protocol://host:port/container-name
IJSpaceContainer containerProxy = (IJSpaceContainer)SpaceFinder.find(containerUrl);
containerProxy.createSpace( spaceName, new JSpaceAttributes( null, null, false ) );
spaceName
- the name of the space, which must be unique in this containerspaceAttr
- Space attributes
CreateException
- This exception may be thrown if container failed to create space.
RemoteException
- if a communication error occurs@Deprecated void destroySpace(String spaceName) throws DestroyedFailedException, RemoteException
// ...after obtaining a containerProxy, either by createSpace(...)
// or by IJSpace.getContainer()
containerProxy.destroySpace( spaceName );
spaceName
- the name of the space.
DestroyedFailedException
- This exception may be thrown if container failed to destroy space.
RemoteException
- if a communication error occurs@Deprecated com.j_spaces.core.JSpaceAttributes getSpaceAttributes(String spaceName) throws NoSuchNameException, RemoteException
JSpaceAttributes
object of the specified space,
through which you may access different space attributes.
JSpaceAttributes spaceAttr = containerProxy.getSpaceAttributes( spaceName );
System.out.println("Space is private?: " + spaceAttr.m_isPrivate );
System.out.println("Space is clustered?: " + spaceAttr.m_isClustered );
spaceName
- the name of the space.
JSpaceAttributes
object associated with the specified space.
NoSuchNameException
- if the specified space doesn't exist in this container.
RemoteException
- if a communication error occurs@Deprecated String[] getSpaceNames() throws RemoteException
// get all space names from container
String[] names = containerProxy.getSpaceNames();
for ( int i = 0; i < names.length; i++ )
System.out.println( names[i] );
RemoteException
- if a communication error occursString getName() throws RemoteException
RemoteException
- if a communication error occurs@Deprecated IJSpace getSpace(String spaceName) throws NoSuchNameException, RemoteException
spaceName
- the name of the space.
NoSuchNameException
- if the specified space does not exist in this container.
RemoteException
- if a communication error occurs@Deprecated IJSpace getClusteredSpace(String spaceName) throws NoSuchNameException, RemoteException
spaceName
- the name of the space.
NoSuchNameException
- if the specified space does not exist in this container.
RemoteException
- if a communication error occurs@Deprecated void shutdown() throws RemoteException
RemoteException
- if a communication error occursboolean isEmbedded() throws RemoteException
true
if the container is embedded
RemoteException
- if a communication error occursSpaceURL getURL() throws RemoteException
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.
The IJSpace
keeps also its reference of the SpaceURL which launched the container.
SpaceURL
which initialized that specific space instance.
RemoteException
void ping() throws RemoteException
IJSpaceContainer aContainer = (IJSpaceContainer)SpaceFinder.find("jini://lookup-host/container-name")
;
try{
aContainer.ping();
System.out.println("Container alive");
}
catch (java.rmi.RemoteException re) {
System.out.println("Container unreachable");
}
RemoteException
- when container was unreachable
|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |