|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectist.palcom.base.Object
ist.palcom.base.Channel
ist.palcom.device.EventChannel
public class EventChannel
EventChannel is a Channel that can be used from Java
threads for sending PalcomEvents to PalcomThreads in a safe way (doing
operations such as putEvent directly on a PalcomThread from a Java thread is
not safe, because the PalComScheduler is not aware of the Java threads).
A EventChannelThread has to be scheduled for the EventChannel for the
event passing to work. Java threads may call the thread safe method
safePutEvent on the channel, and
events will be delivered to PalcomThreads, given that an EventChannelThread
runs.
When finished using the EventChannel, the method close must
be called. Otherwise, running EventChannelThreads will not stop.
| Constructor Summary | |
|---|---|
EventChannel()
|
|
| Method Summary | |
|---|---|
void |
close()
Close the channel. |
boolean |
dataAvailable()
This method should only be called by the System class. |
void |
safePutEvent(Event event,
PalcomThread target)
Put an event in the mailbox of a PalcomThread in a way that does not interfere with the PalcomScheduler. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EventChannel()
| Method Detail |
|---|
public void safePutEvent(Event event,
PalcomThread target)
public void close()
public boolean dataAvailable()
ist.palcom.base.Channel#dataAvailable()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||