RMI Templates
The IDE provides you with the following RMI data object templates
available from the New Wizard:
- Activatable. Creates an implementation of a remote object
based on java.rmi.activation.Activatable. The main
method contains code that registers the object into activation systems
and registers it into an RMI registry. A new registry is created if
one does not exist.
- ClearImplementation. Creates an implementation of a remote
object. Use this kind of implementation for adding
callbacks. ClearImplmentation is usually exported by
UnicastRemoteObject.exportObject().
- Hello. Creates a remote interface containing code using the
Hello example.
- RMIClient. Creates a simple RMI client file.
- RMI_IIOP. Creates an implementation of a remote object
based on javax.rmi.ProtableRemoteObject. IIOP is used for
communication between objects. The implamentation can also be used for
communicating with CORBA applications.
- Remote. Creates an empty remote interface. You can complete
the file by editing it in the Source Editor.
- UnicastRemoteObject. Creates an implementation based on
java.rmi.server.UnicastRemoteObject. The main method
of the class creates an instance of the class and registers the
instance in an RMI registry. A new registry is created if
one does not exist.
RMI Socket Templates
The IDE provides you with the following RMI socket templates available
from the New Wizard:
-
ClientSocket (group). Creates a group of files that contains
files that are necessary for client-side custom sockets. The files
created are: ClientSocketFactory, InputStream, OutputStream and
Socket.
-
ClientSocketFactory. Creates a class that implements
java.rmi.server.ClientSocketFactory, which serves as a
factory for creating sockets on the client side.
-
CustomSocket (group). Creates a group that contains both
client-side files and server-files.
-
InputStream. Creates a class that can be used for implementing
a custom InputStream.
-
OutputStream. Creates a class that can be used for implementing
a custom OutputStream.
-
ServerSocket. Creates a template that can be used for
subclasssing java.net.ServerSocket.
-
ServerSocket (group). Creates a group of files that makes it
possible to create the entire implementation of a custom
ServerSocket. For example, it can create a ServerSocket whose
accept method returns a custom socket that uses custom
InputStream and OutputStream. The files creates are: SocketInputStream,
SocketOutputStream, SocketServerSocket,
SocketServerSocketfactory, and SocketSocket.
-
ServerSocketFactory. Creates a template that can be used for
creating your own implementation of
java.rmi.server.SocketFactory.
-
Socket. Creates a template that can be used for creating a
custom implementation of java.net.Socket.
Legal
Notices