|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--simulator.GenericSendVRML
This is an abstract class created to be extended for making the
SendVRML
class able to operate with your simulation
ambient and your client send VRML protocol.
The derived class must be like this:
class MySendVRML extend GenericSendVRML{ // this is the list of your variable ... public void runTask() { //this is the procedure called with late-bilding method //that you must use to your simulation strategy } public void sendVRML() { //this is the procedure called with late-bilding method //that you must use to your send VRML } }
Field Summary | |
protected java.util.Hashtable |
connectedUsers
This contains the list of connected user and will be always used for a simulation strategy in runTask . |
protected Server |
server
Contains the instance to the Server class |
protected java.util.Hashtable |
state
This contains the list of the state of simulation and will be always used for a simulation strategy in runTask . |
Constructor Summary | |
(package private) |
GenericSendVRML()
|
Method Summary | |
void |
broadcast(java.lang.String s)
Broadcasting a string to all the connected clients |
void |
init(Server server)
This initialize the internal variable |
abstract void |
runTask()
This is the procedure called by SendVRML thread when
we must updating the simulator state.
|
abstract void |
sendVRML()
This is the procedure called by sendVRML thread when
we send the VRML view to the connected clients.
|
Methods inherited from class java.lang.Object |
|
Field Detail |
protected java.util.Hashtable connectedUsers
runTask
. It's the same that you
can extract from server
variable.protected java.util.Hashtable state
runTask
. It's the same
that you can extract from server
variable.protected Server server
Server
classConstructor Detail |
GenericSendVRML()
Method Detail |
public void init(Server server)
server
- the instance to Server
public abstract void runTask()
SendVRML
thread when
we must updating the simulator state.
It's abstract so you must implements it.
This method should use like this:
state
list for the objects that are present in
the simulator
state
public abstract void sendVRML()
sendVRML
thread when
we send the VRML view to the connected clients.
It's abstract so you must implements it.
This method shuld use like this:
state
list for the object that are present in
the simulator
broadcast
routine. The string must respect the sintax
of runCommand
of Client
class
Client.runCommand(java.lang.String)
public void broadcast(java.lang.String s)
s
- the string to broadcasting
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |