|
WSF
|
#include <WsfCommRouterComponent.hpp>


Public Member Functions | |
| RouterComponent ()=default | |
| ~RouterComponent () override=default | |
| Router * | GetRouter () const |
| WsfSimulation * | GetSimulation () const |
| NetworkManager * | GetNetworkManager () const |
| virtual void | Setup () |
| virtual void | PendingStart () |
| virtual bool | Initialize (double aSimTime) |
| virtual bool | Initialize2 (double aSimTime) |
| virtual bool | PreInitialize (double aSimTime) |
| virtual bool | ProcessInput (UtInput &aInput) |
| Public Member Functions inherited from WsfComponentT< Router > | |
| WsfComponentT () | |
| WsfComponentT & | operator= (const WsfComponentT &) noexcept |
| ~WsfComponentT () override=default | |
| virtual void | ComponentParentChanged (ParentType *aParentPtr) |
| ParentType * | GetComponentParent () const |
| void | SetComponentParent (ParentType *aParentPtr) |
| Public Member Functions inherited from WsfComponent | |
| virtual | ~WsfComponent ()=default |
| virtual WsfComponent * | CloneComponent () const =0 |
| virtual WsfStringId | GetComponentName () const =0 |
| virtual const int * | GetComponentRoles () const =0 |
| virtual void * | QueryInterface (int aRole)=0 |
| virtual int | GetComponentInitializationOrder () const |
| template<typename T> | |
| bool | QueryInterfaceT (T *&aRolePtr) |
| bool | ComponentHasRole (int aRole) |
| Returns true if the component has the specified role. | |
| virtual void | PreInput () |
Additional Inherited Members | |
| Public Types inherited from WsfComponentT< Router > | |
| typedef Router | ParentType |
| This is needed to support the WsfComponentList template. | |
This is an abstract base class for router components. Users wishing to add components to enhance or extend routing capabilities by adding components can use this interface.
|
default |
|
overridedefault |
| NetworkManager * wsf::comm::router::RouterComponent::GetNetworkManager | ( | ) | const |
References GetRouter().
|
inline |
References WsfComponentT< Router >::GetComponentParent().
Referenced by wsf::comm::router::ProtocolAdHoc::ExecuteOnCommAdded(), wsf::comm::router::ProtocolAdHoc::ExecuteOnCommRemoved(), wsf::comm::router::ProtocolAdHoc::ExecuteOnConnectionAdded(), wsf::comm::router::ProtocolAdHoc::ExecuteOnConnectionRemoved(), wsf::comm::router::ProtocolAdHoc::ExecuteOnMessageRouting(), wsf::comm::router::ProtocolOSPF::GetAllOSPF(), GetNetworkManager(), wsf::comm::router::ProtocolOSPF::GetPriorityInterface(), wsf::comm::router::ProtocolAdHoc::Initialize(), wsf::comm::router::ProtocolOSPF::Initialize(), wsf::comm::router::ProtocolAdHoc::InitializeState(), wsf::comm::router::ProtocolMulticast::Receive(), wsf::comm::router::ProtocolAdHoc::Routing(), wsf::comm::router::ProtocolLegacy::Routing(), wsf::comm::router::ProtocolMulticast::Routing(), wsf::comm::router::ProtocolOSPF::Routing(), wsf::comm::router::rip::RIPv2::Routing(), wsf::comm::router::ProtocolMulticast::Send(), wsf::comm::router::ProtocolOSPF::SendHello(), wsf::comm::router::ProtocolOSPF::SetRouterRoleType(), wsf::comm::router::rip::RIPv2::TurnOn(), and wsf::comm::router::ProtocolAdHoc::ValidNetwork().
| WsfSimulation * wsf::comm::router::RouterComponent::GetSimulation | ( | ) | const |
References WsfComponentT< Router >::GetComponentParent(), and WsfPlatformPart::GetSimulation().
Referenced by wsf::comm::router::ProtocolOSPF::DR_GraphDrop(), wsf::comm::router::OSPF_Area::ElectionDR(), wsf::comm::router::ProtocolOSPF::GetGraph(), wsf::comm::router::ProtocolAdHoc::Initialize(), wsf::comm::router::ProtocolLegacy::Initialize(), wsf::comm::router::ProtocolMulticast::Initialize(), wsf::comm::router::ProtocolOSPF::Initialize(), wsf::comm::router::rip::RIPv2::Initialize(), wsf::comm::router::ProtocolAdHoc::InitializeState(), wsf::comm::router::ProtocolAdHoc::PerfectCommAdded(), wsf::comm::router::ProtocolAdHoc::PerfectCommRemoved(), wsf::comm::router::ProtocolAdHoc::PerfectConnectionAdded(), wsf::comm::router::ProtocolAdHoc::PerfectConnectionRemoved(), wsf::comm::router::ProtocolOSPF::PlatformInitialized(), wsf::comm::router::ProtocolOSPF::ReceiveDR_GraphAdd(), wsf::comm::router::ProtocolOSPF::ReceiveDR_GraphDrop(), wsf::comm::router::ProtocolOSPF::ReceiveHello(), wsf::comm::router::ProtocolOSPF::RouteExternallyASBR(), wsf::comm::router::ProtocolOSPF::RouteFromBackbone(), wsf::comm::router::ProtocolOSPF::RouteToBackbone(), wsf::comm::router::ProtocolOSPF::Routing(), wsf::comm::router::ProtocolOSPF::ScheduleEvent(), wsf::comm::router::ProtocolOSPF::SendDR_GraphAdd(), wsf::comm::router::ProtocolOSPF::SendDR_GraphDrop(), wsf::comm::router::ProtocolOSPF::SendHello(), wsf::comm::router::ProtocolLegacy::Setup(), wsf::comm::router::ProtocolMulticast::Setup(), wsf::comm::router::ProtocolOSPF::Setup(), and wsf::comm::router::ProtocolAdHoc::ValidNetwork().
|
virtual |
Perform phase 1 initialization. This is called by WsfPlatform::Initialize() during phase 1 initialization of the platform. The component should complete validation of input data that could not be done by ProcessInput, as well as any other functions to prepare for simulation use (subject to the next paragraph).
The order in which components are initialized is defined by GetComponentInitializationOrder. In general a component implementation of this method should not be dependent on the state of another component, i.e.: it should not assume that the other components Initialize() method has been called. If such a dependency exists one should use Initialize2() if possible, or specify a value GetComponentInitializationOrder to force things to initialize in a particular order.
| aSimTime | The current simulation time. |
Reimplemented from WsfComponent.
|
virtual |
Perform phase 2 initialization. This is called by WsfPlatform::Initialize() during phase 2 of platform initialization. This method is typically used when a component may have some dependency on another component having completed its phase 1 initialization. The component should be ready for use in the simulation upon completion of this method.
The order in which components are initialized is defined by GetComponentInitializationOrder.
| aSimTime | The current simulation time. |
Reimplemented from WsfComponent.
|
inlinevirtual |
|
virtual |
Perform pre-initializion function. This is called by WsfPlatform::Initialize prior to actually initializing the components on a platform (i.e.: calling Initialize and Initialize2 for each component). The primary reason for this method is to allow components to add other components that will then be subsequently initialized. The component may examine the component list and add components, but it must not assume ANYTHING about the actual state of the component.
| aSimTime | The current simulation time. |
Reimplemented from WsfComponent.
|
virtual |
Evaluate the current input command and determine if it is one processed by the component. The component should get the current command from the input stream and determine if it is one that it recognizes. If it does not recognize the command then it should leave the command in the input stream and return false. If it does recognize the command then it should process the command and return true. If invalid arguments are encountered then it should throw an exception.
| aInput | The input stream. |
| UtInput::ExceptionBase | if an invalid input was encountered. |
Reimplemented from WsfComponent.
|
inlinevirtual |