EMANE  1.0.1
EMANE::NEMLayerStateRunning Class Reference

Component start complete all transport processing and event actions are now allowed. Allowable transitions are Component::stop(). More...

#include <nemlayerstaterunning.h>

Inheritance diagram for EMANE::NEMLayerStateRunning:
EMANE::NEMLayerState EMANE::Utils::Singleton< NEMLayerStateRunning >

Public Member Functions

 ~NEMLayerStateRunning ()
 
void handlePostStart (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer)
 
void handleStop (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer)
 
virtual void processConfiguration (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, const ConfigurationUpdate &update)
 
void processDownstreamControl (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, const ControlMessages &msgs)
 
void processDownstreamPacket (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, DownstreamPacket &pkt, const ControlMessages &msgs)
 
void processUpstreamPacket (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, UpstreamPacket &pkt, const ControlMessages &msgs)
 
void processUpstreamControl (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, const ControlMessages &msgs)
 
void processEvent (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, const EventId &id, const Serialization &serialization)
 
void processTimedEvent (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, TimerEventId eventId, const TimePoint &expireTime, const TimePoint &scheduleTime, const TimePoint &fireTime, const void *arg)
 
virtual void handleInitialize (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, Registrar &registrar)
 
virtual void handleConfigure (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer, const ConfigurationUpdate &update)
 
virtual void handleStart (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer)
 
virtual void handleDestroy (NEMStatefulLayer *pStatefulLayer, NEMLayer *pLayer) throw ()
 
std::string getStateName () const
 

Static Public Member Functions

static NEMLayerStateRunninginstance ()
 
static void destroy ()
 

Protected Member Functions

 NEMLayerStateRunning ()
 
void changeState (NEMStatefulLayer *pStatefulLayer, NEMLayerState *pState)
 

Protected Attributes

const char * pzStateName_
 

Detailed Description

Component start complete all transport processing and event actions are now allowed. Allowable transitions are Component::stop().

Definition at line 50 of file nemlayerstaterunning.h.

Constructor & Destructor Documentation

◆ ~NEMLayerStateRunning()

EMANE::NEMLayerStateRunning::~NEMLayerStateRunning ( )

Definition at line 41 of file nemlayerstaterunning.cc.

◆ NEMLayerStateRunning()

EMANE::NEMLayerStateRunning::NEMLayerStateRunning ( )
protected

Definition at line 38 of file nemlayerstaterunning.cc.

Member Function Documentation

◆ changeState()

void EMANE::NEMLayerState::changeState ( NEMStatefulLayer pStatefulLayer,
NEMLayerState pState 
)
protectedinherited

Definition at line 192 of file nemlayerstate.cc.

◆ destroy()

static void EMANE::Utils::Singleton< NEMLayerStateRunning >::destroy ( )
inlinestaticinherited

Destroys the single instance of type T. Once destroyed it cannot be used or recreated. This is not a thread-safe method.

Definition at line 67 of file singleton.h.

◆ getStateName()

std::string EMANE::NEMLayerState::getStateName ( ) const
inherited

Get state name

Returns
state Name of current state

Definition at line 198 of file nemlayerstate.cc.

◆ handleConfigure()

void EMANE::NEMLayerState::handleConfigure ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
const ConfigurationUpdate update 
)
virtualinherited

Handle configuration

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
updateConfiguration update
Exceptions
ConfigureException
Note
Default implementation generates a log error

Reimplemented in EMANE::NEMLayerStateConfigured, and EMANE::NEMLayerStateInitialized.

Definition at line 54 of file nemlayerstate.cc.

◆ handleDestroy()

void EMANE::NEMLayerState::handleDestroy ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer 
)
throw (
)
virtualinherited

Handle destroy

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
Note
Default implementation generates a log error

Reimplemented in EMANE::NEMLayerStateStopped.

Definition at line 95 of file nemlayerstate.cc.

◆ handleInitialize()

void EMANE::NEMLayerState::handleInitialize ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
Registrar registrar 
)
virtualinherited

Handle initialize

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
registrarRegistrar reference
Exceptions
InitializeException
Note
Default implementation generates a log error

Reimplemented in EMANE::NEMLayerStateUninitialized.

Definition at line 43 of file nemlayerstate.cc.

◆ handlePostStart()

void EMANE::NEMLayerStateRunning::handlePostStart ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer 
)
virtual

Handle post start

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer

Layer post start hook

Reimplemented from EMANE::NEMLayerState.

Definition at line 43 of file nemlayerstaterunning.cc.

◆ handleStart()

void EMANE::NEMLayerState::handleStart ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer 
)
virtualinherited

Handle start

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
Exceptions
StartException
Note
Default implementation generates a log error

Reimplemented in EMANE::NEMLayerStateConfigured.

Definition at line 65 of file nemlayerstate.cc.

◆ handleStop()

void EMANE::NEMLayerStateRunning::handleStop ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer 
)
virtual

Handle stop

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
Exceptions
StopException
Note
A successful stop will result in a transition to the NEMLayerStateStopped state.

Reimplemented from EMANE::NEMLayerState.

Definition at line 49 of file nemlayerstaterunning.cc.

◆ instance()

static NEMLayerStateRunning * EMANE::Utils::Singleton< NEMLayerStateRunning >::instance ( )
inlinestaticinherited

Provides thread-safe access to a single instance of type T. It does not provide thread-safety for T methods.

Returns
A pointer to T

Definition at line 56 of file singleton.h.

◆ processConfiguration()

void EMANE::NEMLayerStateRunning::processConfiguration ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
const ConfigurationUpdate update 
)
virtual

Process configuration update

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
updateReference to the configuration update

Reimplemented from EMANE::NEMLayerState.

Definition at line 56 of file nemlayerstaterunning.cc.

◆ processDownstreamControl()

void EMANE::NEMLayerStateRunning::processDownstreamControl ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
const ControlMessages msgs 
)
virtual

Process downstream control

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
msgsControl message

Layer processing of downstream control

Reimplemented from EMANE::NEMLayerState.

Definition at line 64 of file nemlayerstaterunning.cc.

◆ processDownstreamPacket()

void EMANE::NEMLayerStateRunning::processDownstreamPacket ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
DownstreamPacket pkt,
const ControlMessages msgs 
)
virtual

Process downstream packet

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
pktReference to the Downstream packet
msgsReference to the ControlMessage

Layer processing of downstream packet

Reimplemented from EMANE::NEMLayerState.

Definition at line 71 of file nemlayerstaterunning.cc.

◆ processEvent()

void EMANE::NEMLayerStateRunning::processEvent ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
const EventId id,
const Serialization serialization 
)
virtual

Process event

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
idEvent Id
serializationEvent object serialization

Layer processing of event

Reimplemented from EMANE::NEMLayerState.

Definition at line 94 of file nemlayerstaterunning.cc.

◆ processTimedEvent()

void EMANE::NEMLayerStateRunning::processTimedEvent ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
TimerEventId  eventId,
const TimePoint expireTime,
const TimePoint scheduleTime,
const TimePoint fireTime,
const void *  arg 
)
virtual

Process timed event

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
eventIdIdentifier corresponding to the timer being processed
expireTimeThe time the timer was scheduled to expire
scheduleTimeThe Time the timer was scheduled
fireTimeTime time The time the timer actually fired
argOpaque timed event data

Layer processing of timed event

Reimplemented from EMANE::NEMLayerState.

Definition at line 103 of file nemlayerstaterunning.cc.

◆ processUpstreamControl()

void EMANE::NEMLayerStateRunning::processUpstreamControl ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
const ControlMessages msgs 
)
virtual

Process upstream control

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
msgsReference to the Control message

Layer processing of upstream control

Reimplemented from EMANE::NEMLayerState.

Definition at line 87 of file nemlayerstaterunning.cc.

◆ processUpstreamPacket()

void EMANE::NEMLayerStateRunning::processUpstreamPacket ( NEMStatefulLayer pStatefulLayer,
NEMLayer pLayer,
UpstreamPacket pkt,
const ControlMessages msgs 
)
virtual

Process downstream packet

Parameters
pStatefulLayerReference to the stateful layer
pLayerReference to the wrapped layer
pktReference to the Upstream packet
msgsReference to the ControlMessage

Layer processing of upstream packet

Reimplemented from EMANE::NEMLayerState.

Definition at line 79 of file nemlayerstaterunning.cc.

Member Data Documentation

◆ pzStateName_

const char* EMANE::NEMLayerState::pzStateName_
protectedinherited

Definition at line 252 of file nemlayerstate.h.


The documentation for this class was generated from the following files: