com.sun.jini.example.hello
Class ActivatableServer
java.lang.Object
com.sun.jini.example.hello.Server
com.sun.jini.example.hello.ActivatableServer
- All Implemented Interfaces:
- Hello, Remote, net.jini.export.ProxyAccessor, net.jini.security.proxytrust.ServerProxyTrust
public class ActivatableServer
- extends Server
Defines an activatable application server that provides an implementation of
the Hello interface.
The application uses the following arguments:
[all] - All arguments are used as options when getting the configuration
The application uses the following configuration entries, with component
com.sun.jini.example.hello.Server:
activationIdPreparer
type: ProxyPreparer
default: new BasicProxyPreparer()
Proxy preparer for the service proxy's activation ID
activationSystemPreparer
type: ProxyPreparer
default: new BasicProxyPreparer()
Proxy preparer for the activation system proxy
configOptions
type: String[]
default: none
The options for the configuration used to configure the server
discoveryManager
type: DiscoveryManagement
default: new LookupDiscovery(new String[] { "" }, config)
Object used to discover lookup services to join.
exporter
type: Exporter
default: none
The object to use for exporting the server
loginContext
type: LoginContext
default: null
If non-null, specifies the JAAS login context to use for performing a JAAS
login and supplying the Subject to use when starting the service. If null,
no JAAS login is performed.
javaOptions
type: String[]
default: new String[0]
Command line options for the activation group executable
javaProgram
type: String
default: null
The executable for the activation group, or the default executable if null
javaProperties
type: String[]
default: new String[0]
System properties for the activation group executable, specified as pairs
of keys and values
- Author:
- Sun Microsystems, Inc.
Method Summary |
protected net.jini.export.Exporter |
getExporter()
Returns the exporter for exporting the server. |
protected net.jini.core.lookup.ServiceID |
getServiceID()
Returns the service ID for this server. |
static void |
main(String[] args)
Starts and registers an activatable server that implements the Hello
interface. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ActivatableServer
public ActivatableServer(ActivationID aid,
MarshalledObject data)
throws Exception
- Creates the server
- Parameters:
aid
- the activation ID for the serverdata
- the data for the activatable server, which should be the
options to use when getting the Configuration
- Throws:
Exception
- if a problem occurs
main
public static void main(String[] args)
throws Exception
- Starts and registers an activatable server that implements the Hello
interface.
- Throws:
Exception
getExporter
protected net.jini.export.Exporter getExporter()
throws net.jini.config.ConfigurationException,
RemoteException
- Returns the exporter for exporting the server. Prepares the activation
ID and makes it available to the exporter through the getActivationID
method.
- Overrides:
getExporter
in class Server
- Throws:
net.jini.config.ConfigurationException
- if a problem occurs getting the exporter
from the configuration
RemoteException
- if a remote communication problem occurs
getServiceID
protected net.jini.core.lookup.ServiceID getServiceID()
- Returns the service ID for this server.
- Overrides:
getServiceID
in class Server
Copyright 2007, multiple authors.
Licensed under the Apache License, Version 2.0, see the NOTICE file for attributions.