|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Thread | +--loader.ClassServer
This class together with WorkerClassLoader is the server part of NetworkClassLoader.
This class, which executes in a Thread uses java.net.ServerSocket.
It listens on a port (default 5050) for incoming connections.
For every connection a new thread (a WorkerClassLoader) is generated
with the following parameters:
clientSocket - socket for the brand new connection.
classCache - a cache, which is global in the server of classes which have already been loaded.
Thread
Fields inherited from class java.lang.Thread |
MAX_PRIORITY,
MIN_PRIORITY,
NORM_PRIORITY |
Constructor Summary | |
ClassServer(int port)
Costruttore. |
Method Summary | |
protected void |
finalize()
Empty cache. |
void |
run()
An infinite loop for listening for incoming connections. For every new accepted connection a new thread is created for communicating with the client. |
Methods inherited from class java.lang.Thread |
activeCount,
checkAccess,
countStackFrames,
currentThread,
destroy,
dumpStack,
enumerate,
getContextClassLoader,
getName,
getPriority,
getThreadGroup,
interrupt,
interrupted,
isAlive,
isDaemon,
isInterrupted,
join,
join,
join,
resume,
setContextClassLoader,
setDaemon,
setName,
setPriority,
sleep,
sleep,
start,
stop,
stop,
suspend,
toString,
yield |
Methods inherited from class java.lang.Object |
clone,
equals,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Constructor Detail |
public ClassServer(int port) throws java.net.UnknownHostException, java.io.IOException
port
- port for serverSocket, if port = 0
default (5050) is considered.Method Detail |
public void run()
protected void finalize()
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |