All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.ibm.aglet.system.AgletRuntime

java.lang.Object
   |
   +----com.ibm.aglet.system.AgletRuntime

public abstract class AgletRuntime
extends Object
AgletRuntime class provides the way to access the information of the local or remote context. Neither of an application nor aglet can create its own instance of this runtime class.

See Also:
getAgletRuntime

Constructor Index

 o AgletRuntime()

Method Index

 o createAgletContext(String)
Creates an DefaultAgletContext object given by the Framework implementation with specified name.
 o getAgletContext(String)
Returns the AgletContext which has the specified name.
 o getAgletContexts()
Gets the contexts in the environment.
 o getAgletRuntime()
Gets the AgletRuntime object associated with the current Java application.
 o getServerURL()
Gets an address of the server in URL.
 o init(String[])
Create and initialize a runtime environment with a string array.
 o killAglet(AgletProxy)
Kill the specified aglet.
 o removeAgletContext(AgletContext)
Removes the specified aglet context from the runtime environment.
 o shutdown()
Shutdown all contexts in the runtime.
 o shutdown(Message)
Shutdown all contexts in the current runtime with the specific message object.

Constructors

 o AgletRuntime
 public AgletRuntime()

Methods

 o init
 public static synchronized AgletRuntime init(String args[])
Create and initialize a runtime environment with a string array.

Parameters:
a - string array which is typically given as a argument to main(String args[]) function.
 o getAgletRuntime
 public static synchronized AgletRuntime getAgletRuntime()
Gets the AgletRuntime object associated with the current Java application.

 o createAgletContext
 public abstract AgletContext createAgletContext(String name)
Creates an DefaultAgletContext object given by the Framework implementation with specified name.

Throws: SecurityException
if the current execution is not allowed to create an AgletContext.
 o getAgletContext
 public abstract AgletContext getAgletContext(String name)
Returns the AgletContext which has the specified name.

Parameters:
name - the name of the context
Throws: SecurityException
if the current execution is not allowed to acccess the AgletContext.
 o removeAgletContext
 public abstract void removeAgletContext(AgletContext cxt)
Removes the specified aglet context from the runtime environment. It is also removed from export list if it's exported.

Parameters:
cxt - the context to be removed.
 o getAgletContexts
 public abstract AgletContext[] getAgletContexts()
Gets the contexts in the environment.

 o getServerURL
 public abstract URL getServerURL()
Gets an address of the server in URL.

Returns:
an URL represents the address of the server.
 o shutdown
 public abstract void shutdown()
Shutdown all contexts in the runtime.

 o shutdown
 public abstract void shutdown(Message msg)
Shutdown all contexts in the current runtime with the specific message object. This messag object is delivered to all aglets in all contexts before all aglets are killed.

 o killAglet
 public abstract void killAglet(AgletProxy proxy) throws InvalidAgletException
Kill the specified aglet. This aglet have to be a local aglet in this runtime.

Parameters:
proxy - the aglet proxy object to kill.

All Packages  Class Hierarchy  This Package  Previous  Next  Index