at.jku.fim.datalinksimulation.layer2.devices
Class CRCGuard

java.lang.Object
  extended by at.jku.fim.datalinksimulation.genericdevices.HardwareComponent
      extended by at.jku.fim.datalinksimulation.genericdevices.InterlinkingDevice
          extended by at.jku.fim.datalinksimulation.layer1.devices.Hub
              extended by at.jku.fim.datalinksimulation.layer2.devices.CRCGuard
All Implemented Interfaces:
WireConnector

public class CRCGuard
extends Hub

Title: OSI Simulation Framework

This class represents a version of an "intelligent hub", which checks, if frames on layer 2 are corrupt or not; in case of an invalid frame the frame is simply dropped and not forwarded. Because this device knows things about facts in layer 2, but it doesn't do switching, it can be regarded as a "switch in flooding mode".

Copyright: (c) 2004-05

Company: FIM@JKU, www.fim.uni-linz.ac.at

Version:
$Id: CRCGuard.java,v 1.1 2005/10/27 13:10:11 aputzinger Exp $
Author:
Andreas Putzinger

Field Summary
 
Fields inherited from class at.jku.fim.datalinksimulation.genericdevices.InterlinkingDevice
logger, networkStack, numberOfPorts
 
Fields inherited from class at.jku.fim.datalinksimulation.genericdevices.HardwareComponent
networkComponentId
 
Constructor Summary
CRCGuard(java.lang.String identifier, int numberOfPorts)
          Constructor
 
Method Summary
protected  IncomingNetworkStackConfiguration getIncomingNetworkStackConfiguration()
          This method must be overriden in subclasses.
protected  OutgoingNetworkStackConfiguration getOutgoingNetworkStackConfiguration()
          This method must be overriden in subclasses.
 
Methods inherited from class at.jku.fim.datalinksimulation.genericdevices.InterlinkingDevice
bePlugged, beUnplugged, getConnectedWires, getNextFreePort, getNumberOfFreePorts, getNumberOfTotalPorts, getPortOfWire, getWireInPort, informAboutDataOnWire, isPortFree, isWireConnected, toString
 
Methods inherited from class at.jku.fim.datalinksimulation.genericdevices.HardwareComponent
getNetworkComponentId
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CRCGuard

public CRCGuard(java.lang.String identifier,
                int numberOfPorts)
Constructor

Parameters:
identifier - Identifier for logs
numberOfPorts - Number of available ports
Method Detail

getIncomingNetworkStackConfiguration

protected IncomingNetworkStackConfiguration getIncomingNetworkStackConfiguration()
Description copied from class: InterlinkingDevice
This method must be overriden in subclasses. The configuration for the incoming network stack must be returned.

Overrides:
getIncomingNetworkStackConfiguration in class Hub
Returns:
The incoming network stack configuration

getOutgoingNetworkStackConfiguration

protected OutgoingNetworkStackConfiguration getOutgoingNetworkStackConfiguration()
Description copied from class: InterlinkingDevice
This method must be overriden in subclasses. The configuration for the outgoing network stack must be returned.

Overrides:
getOutgoingNetworkStackConfiguration in class Hub
Returns:
The outgoing network stack configuration