public class ProtocolView extends java.lang.Object implements ProtocolObserver
Constructor and Description |
---|
ProtocolView(Protocol p,
javax.swing.table.DefaultTableModel model,
int my_index) |
ProtocolView(Protocol p,
javax.swing.table.DefaultTableModel model,
int my_index,
boolean cummulative) |
Modifier and Type | Method and Description |
---|---|
boolean |
down(Event evt,
int num_evts)
Called when an event is about to be dispatched to the protocol (before it is dispatched).
|
boolean |
passDown(Event evt)
Called when an event is about to be passed down to the next lower protocol.
|
boolean |
passUp(Event evt)
Called when an event is about to be passed up to the next higher protocol.
|
void |
setProtocol(Protocol prot)
Called when a ProtocolObserver is attached to a protcol.
|
java.lang.String |
toString() |
boolean |
up(Event evt,
int num_evts)
Called when an event is about to be dispatched to the protocol (before it is dispatched).
|
public ProtocolView(Protocol p, javax.swing.table.DefaultTableModel model, int my_index)
public ProtocolView(Protocol p, javax.swing.table.DefaultTableModel model, int my_index, boolean cummulative)
public void setProtocol(Protocol prot)
ProtocolObserver
setProtocol
in interface ProtocolObserver
public boolean up(Event evt, int num_evts)
ProtocolObserver
up
in interface ProtocolObserver
evt
- The event to be processed by the protocol. This is not a copy, so changes
to the event will be seen by the protocol !num_evts
- The number of events currently in the up-queue (including this event).
This number may increase while we're in the callback as the up-handler thread in the
upper protocol layer puts new events into the up queue.public boolean passUp(Event evt)
ProtocolObserver
passUp
in interface ProtocolObserver
evt
- The event to be processed by the protocol. This is not a copy, so changes
to the event will be seen by the protocol !public boolean down(Event evt, int num_evts)
ProtocolObserver
down
in interface ProtocolObserver
evt
- The event to be processed by the protocol. This is not a copy, so changes
to the event will be seen by the protocol !num_evts
- The number of events currently in the down-queue (including this event).
This number may increase while we're in the callback as the down-handler thread in the
upper protocol layer puts new events into the down queue.public boolean passDown(Event evt)
ProtocolObserver
passDown
in interface ProtocolObserver
evt
- The event to be processed by the protocol. This is not a copy, so changes
to the event will be seen by the protocol !public java.lang.String toString()
toString
in class java.lang.Object
Copyright ? 1998-2006 Bela Ban. All Rights Reserved.