|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Thread | +--simulator.Listener
Listener thread-class of input socket stream. It's execute this two steps:
TextArea
Field Summary | |
protected Client |
applet
Contains the instance to the applet |
protected boolean |
running
This flag indicates if listener is running |
protected java.io.DataInputStream |
sin
This is the input socket stream used to comunicate |
protected java.awt.TextArea |
window
Contains the reference to an TextArea where we write
the message that server send us |
Fields inherited from class java.lang.Thread |
contextClassLoader,
daemon,
eetop,
group,
inheritedAccessControlContext,
MAX_PRIORITY,
MIN_PRIORITY,
name,
NORM_PRIORITY,
priority,
single_step,
stillborn,
stopThreadPermission,
target,
threadInitNumber,
threadQ,
values |
Constructor Summary | |
Listener(java.net.Socket s,
java.awt.TextArea window,
Client applet)
Initialize object and start the thread |
Method Summary | |
void |
run()
Listen the socket and write message line in the TextArea |
Methods inherited from class java.lang.Thread |
|
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
protected java.io.DataInputStream sin
protected java.awt.TextArea window
TextArea
where we write
the message that server send usprotected boolean running
protected Client applet
Constructor Detail |
public Listener(java.net.Socket s, java.awt.TextArea window, Client applet)
s
- the socket to comunicatewindow
- a TextArea
where we write lineapplet
- an applet of the Client
typeMethod Detail |
public void run()
TextArea
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |