- A Lightweight Java Middleware


OCSelot is easy to learn and master, and the best way to get a grip of it is to study some examples.
Employing a few simple participating classes, the examples demonstrate typical client/server scenarios:

Example 1

only sets the scene. It introduces the participants and shows them collaborating locally. Comparing this example with the subsequent C/S examples points out how little it takes to turn a local application into a client/server app.
Open example 1

Example 2

shows how objects can be deployed and run on a remote server, using a proxy that automatically creates a remote subject and delegates requests to it.
Open example 2

Example 3a

is similar to example 2, but distributes the objects over two processes: an object run in the local process cooperates with a remote object through a proxy that routes requests to a remote server.
Open example 3a

Example 3b

demonstrates the same scenario as the previous example (local object cooperates with remote object through proxy) using an alternative implementation, however: Whereas 3a employs a "class proxy" to create and talk to the remote object, here the remote object is transmitted in another way to the server and an "interface proxy" is used to talk to it.
Open example 3b

Example 4a

demonstrates two-way communication: Initiated by a proxy in the local process, a subject in a remote process is executed, which by similar but independent means talks back to a subject hosted in the local process.
Open example 4a

Example 4b

has the same scenario as example 4a, but implements it using an interface proxy.
Open example 4b

Note, how little code is needed in each case and how the application logic, including the creation of the participating objects, is completely under control of the client.

All the classes used in the examples are provided in the JAR-file "ocs-examples.jar", ready for use. See the individual example pages for instructions on how to run the examples.

To learn more about OCSelot see the manual and the API.

Last modified Jan 17, 2006