Class aglet.system.AgletRuntime
All Packages Class Hierarchy This Package Previous Next Index
Class aglet.system.AgletRuntime
java.lang.Object
|
+----aglet.system.AgletRuntime
- public 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
-
AgletRuntime()
-
-
createAglet(String, URL, String, Object)
- Creates an aglet remotely within the specified context.
-
createAgletContext(String)
- Creates an DefaultAgletContext object given by the Framework
implementation with specified name.
-
getAgletContext(String)
- Returns the AgletContext which has the specified name.
-
getAgletContexts()
- Gets the contexts in the environment.
-
getAgletProxies(String)
- Returns the proxies in the context specified by the contextAddress.
-
getAgletProxy(String, AgletID)
- Obtains the remote proxy for the aglet specified by the context and
id.
-
getAgletRuntime()
- Gets the AgletRuntime object associated with the current
Java application.
-
getServerURL()
- Gets an address of the server in URL.
-
removeAgletContext(AgletContext)
- Removes the specified aglet context from the runtime environment.
-
shutdown()
- Shutdown all contexts in the runtime
-
shutdown(Message)
- Shutdown all contexts in the current runtime with the specific message
object.
AgletRuntime
public AgletRuntime()
getAgletRuntime
public static synchronized AgletRuntime getAgletRuntime()
- Gets the AgletRuntime object associated with the current
Java application.
createAgletContext
public abstract AgletContext createAgletContext(String name)
- Creates an DefaultAgletContext object given by the Framework
implementation with specified name. Hosting multiple contexts
is not supported in alpha5 release.
- Throws: SecurityException
- if the current execution is not allowed
to create an AgletContext.
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.
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 remove
getAgletContexts
public abstract AgletContext[] getAgletContexts()
- Gets the contexts in the environment.
createAglet
public abstract AgletProxy createAglet(String contextAddress,
URL codebase,
String name,
Object init)
- Creates an aglet remotely within the specified context.
- Parameters:
- contextAddress - an address of context.
- codebase - an codebase for the aglet.
- name - name of aglets' class.
- init - an object passed as an initialize argument.
- See Also:
- onCreation, createAglet
getAgletProxy
public abstract AgletProxy getAgletProxy(String contextAddress,
AgletID id)
- Obtains the remote proxy for the aglet specified by the context and
id.
getAgletProxies
public abstract AgletProxy[] getAgletProxies(String contextAddress)
- Returns the proxies in the context specified by the contextAddress.
getServerURL
public abstract URL getServerURL()
- Gets an address of the server in URL.
- Returns:
- an URL represents the address of the server
shutdown
public abstract void shutdown()
- Shutdown all contexts in the runtime
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.
All Packages Class Hierarchy This Package Previous Next Index