Class JThread.socket.Server
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class JThread.socket.Server

Object
   |
   +----JThread.socket.Server

public class Server
extends Object
Server implements a simple server to host thread migration. It maintains a local registry for threads to reference local objects.

Author:
Wei Tao

Constructor Index

 o JThread.socket.Server()

Method Index

 o bind(String, Object)
Bind an object with a name in local registry.
 o lookup(String)
Look up a local object with the specified name.
 o main(String[])
Start a new server at a specified port.
 o start(int)
Start a new server socket at the specified port.

Constructors

 o Server
public Server()

Methods

 o bind
public static void bind(String name,
                        Object object)
Bind an object with a name in local registry.

Parameters:
name - - the name to bind with.
object - - the object to register.
 o lookup
public static java.lang.Object lookup(String name)
Look up a local object with the specified name.

Parameters:
name - - the name to look for.
 o main
public static void main(String[] args)
Start a new server at a specified port.

Parameters:
args: - the port number
 o start
public static void start(int port)
Start a new server socket at the specified port.

Parameters:
port: - the port number

All Packages  Class Hierarchy  This Package  Previous  Next  Index