|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.clackrouter.component.base.ClackComponent net.clackrouter.component.simplerouter.Level2Demux
public class Level2Demux
Demultiplexes Level 2 packets, sending ARP packets to one output port and IP packets to another.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class net.clackrouter.component.base.ClackComponent |
---|
ClackComponent.Waiter |
Field Summary | |
---|---|
static int |
FROM_IFACE
|
static int |
NUM_PORTS
|
static int |
TO_ARP
|
static int |
TO_IP
|
Fields inherited from class net.clackrouter.component.base.ClackComponent |
---|
componentCell, m_has_error, m_log, m_name, m_num_ports, m_packetcount_in, m_packetcount_out, m_ports, mListeners, mRouter, pendingError, SIGNAL_ERROR_LEN_MSEC, UNIQUE_COUNT, view |
Constructor Summary | |
---|---|
Level2Demux(Router router,
java.lang.String name)
|
Method Summary | |
---|---|
void |
acceptPacket(VNSPacket packet,
int port_number)
The starting point for packet-processing when packets are "pushed" to this component. |
int |
getARPCount()
|
java.awt.Color |
getColor()
The color this component should be rendered in, assuming a standard component rendering by the ComponentView.ComponentRenderer class. |
int |
getIPCount()
|
int |
getOtherCount()
|
javax.swing.JPanel |
getPropertiesView()
Method for getting the properties view associated with this component Property views are used to display more detailed information about internal component state. |
protected void |
setupPorts(int numports)
Allocates an array of ClackPort objects to be used by this component |
Methods inherited from class net.clackrouter.component.base.ClackComponent |
---|
createCopy, createInputPullPort, createInputPushPort, createOutputPullPort, createOutputPushPort, error, fireListeners, getComponentCell, getHierarchicalView, getLog, getName, getNumPorts, getPacketCountIn, getPacketCountOut, getPendingError, getPort, getRouter, getSerializableProperties, getTime, getTypeName, getUniqueCount, getView, handlePullRequest, hasError, initializeProperties, isHierarchical, isModifying, log, notifyAlarm, poll, registerListener, sendOutPort, setAlarm, setComponentCell, setName, setPendingError, setView, showErrorDialog, signalError, try_repaint, unregisterListener |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static int FROM_IFACE
public static int TO_ARP
public static int TO_IP
public static int NUM_PORTS
Constructor Detail |
---|
public Level2Demux(Router router, java.lang.String name)
Method Detail |
---|
protected void setupPorts(int numports)
ClackComponent
setupPorts
in class ClackComponent
numports
- the number of ports to createpublic void acceptPacket(VNSPacket packet, int port_number)
ClackComponent
The starting point for packet-processing when packets are "pushed" to this component.
The default implementation warns that the packet is being ignored.
acceptPacket
in class ClackComponent
packet
- The pushed packetport_number
- The number of the port that this packet is arriving onpublic javax.swing.JPanel getPropertiesView()
ClackComponent
getPropertiesView
in class ClackComponent
public java.awt.Color getColor()
ClackComponent
The color this component should be rendered in, assuming a standard component rendering by the
ComponentView.ComponentRenderer
class.
Other renderers may ignore this value.
getColor
in class ClackComponent
public int getARPCount()
public int getIPCount()
public int getOtherCount()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |