Java Reference
In-Depth Information
The above command starts up the Java IDL Transient Nameservice as an object
server that assumes a default port of 900. To use a different port (which would nor-
mally be necessary under Sun's Solaris operating system for ports below 1024), use
the ORBInitialPort option to specify the port number. For example:
tnameserv -ORBInitialPort 1234
(ii) Start the server in a new command window .
For our example program, the command will be:
java HelloServer
(Since there is no screen output from the server, no screenshot is shown here.)
Again, a port other than the default one can be specifi ed. For example:
java HelloServer -ORBInitialPort 1234
(iii) Start the client in a third command window .
For our example program, the command will be:
java HelloClient
(As above, a non-default port can be specifi ed.)
The expected output should appear in the client window, as shown in Fig. 6.4 .
Fig. 6.4 Output from the HelloClient CORBA program
The above example was deliberately chosen to be as simple as possible, since the
central objective was to familiarise the reader with the basic required process, rather
than to introduce the complexities of a realistic application. Now that this process
has been covered, we can apply it to a more realistic scenario. This will be done in
the next section.
Search WWH ::




Custom Search