#include <bs-service-flow-manager.h>
Public Types | |
enum | ConfirmationCode { CONFIRMATION_CODE_SUCCESS, CONFIRMATION_CODE_REJECT } |
![]() | |
enum | ConfirmationCode { CONFIRMATION_CODE_SUCCESS, CONFIRMATION_CODE_REJECT } |
Public Member Functions | |
BsServiceFlowManager (Ptr< BaseStationNetDevice > device) | |
~BsServiceFlowManager (void) | |
void | AddMulticastServiceFlow (ServiceFlow sf, enum WimaxPhy::ModulationType modulation) |
add a multicast service flow | |
void | AddServiceFlow (ServiceFlow *serviceFlow) |
Add a new service flow. | |
void | AllocateServiceFlows (const DsaReq &dsaReq, Cid cid) |
void | DoDispose (void) |
EventId | GetDsaAckTimeoutEvent (void) const |
ServiceFlow * | GetServiceFlow (uint32_t sfid) const |
ServiceFlow * | GetServiceFlow (Cid cid) const |
std::vector< ServiceFlow * > | GetServiceFlows (ServiceFlow::SchedulingType schedulingType) const |
void | ProcessDsaAck (const DsaAck &dsaAck, Cid cid) |
process a DSA-ACK message | |
ServiceFlow * | ProcessDsaReq (const DsaReq &dsaReq, Cid cid) |
process a DSA-Req message | |
void | SetMaxDsaRspRetries (uint8_t maxDsaRspRetries) |
set the maximum Dynamic ServiceFlow Add (DSA) retries | |
![]() | |
ServiceFlowManager () | |
~ServiceFlowManager (void) | |
bool | AreServiceFlowsAllocated () |
bool | AreServiceFlowsAllocated (std::vector< ServiceFlow * > *serviceFlows) |
bool | AreServiceFlowsAllocated (std::vector< ServiceFlow * > serviceFlows) |
ServiceFlow * | DoClassify (Ipv4Address SrcAddress, Ipv4Address DstAddress, uint16_t SrcPort, uint16_t DstPort, uint8_t Proto, ServiceFlow::Direction dir) const |
ServiceFlow * | GetNextServiceFlowToAllocate () |
uint32_t | GetNrServiceFlows (void) const |
![]() | |
Object () | |
virtual | ~Object () |
void | AggregateObject (Ptr< Object > other) |
void | Dispose (void) |
AggregateIterator | GetAggregateIterator (void) const |
virtual TypeId | GetInstanceTypeId (void) const |
template<typename T > | |
Ptr< T > | GetObject (void) const |
template<typename T > | |
Ptr< T > | GetObject (TypeId tid) const |
void | Start (void) |
![]() | |
SimpleRefCount () | |
SimpleRefCount (const SimpleRefCount &o) | |
uint32_t | GetReferenceCount (void) const |
SimpleRefCount & | operator= (const SimpleRefCount &o) |
void | Ref (void) const |
void | Unref (void) const |
![]() | |
virtual | ~ObjectBase () |
void | GetAttribute (std::string name, AttributeValue &value) const |
bool | GetAttributeFailSafe (std::string name, AttributeValue &attribute) const |
void | SetAttribute (std::string name, const AttributeValue &value) |
bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
Private Member Functions | |
DsaRsp | CreateDsaRsp (const ServiceFlow *serviceFlow, uint16_t transactionId) |
uint8_t | GetMaxDsaRspRetries (void) const |
void | ScheduleDsaRsp (ServiceFlow *serviceFlow, Cid cid) |
Private Attributes | |
Ptr< WimaxNetDevice > | m_device |
EventId | m_dsaAckTimeoutEvent |
Cid | m_inuseScheduleDsaRspCid |
uint8_t | m_maxDsaRspRetries |
uint32_t | m_sfidIndex |
Additional Inherited Members | |
![]() | |
static TypeId | GetTypeId (void) |
This method returns the TypeId associated to ns3::ServiceFlowManager. | |
![]() | |
Object (const Object &o) | |
virtual void | DoStart (void) |
virtual void | NotifyNewAggregate (void) |
Definition at line 43 of file bs-service-flow-manager.h.
Definition at line 46 of file bs-service-flow-manager.h.
ns3::BsServiceFlowManager::BsServiceFlowManager | ( | Ptr< BaseStationNetDevice > | device | ) |
Definition at line 44 of file bs-service-flow-manager.cc.
References ns3::Cid::InitialRanging(), and m_inuseScheduleDsaRspCid.
ns3::BsServiceFlowManager::~BsServiceFlowManager | ( | void | ) |
Definition at line 52 of file bs-service-flow-manager.cc.
void ns3::BsServiceFlowManager::AddMulticastServiceFlow | ( | ServiceFlow | sf, |
enum WimaxPhy::ModulationType | modulation | ||
) |
add a multicast service flow
Definition at line 210 of file bs-service-flow-manager.cc.
References AddServiceFlow(), ns3::ServiceFlow::CopyParametersFrom(), ns3::ConnectionManager::CreateConnection(), ns3::WimaxNetDevice::GetConnectionManager(), ns3::Object::GetObject(), ns3::BaseStationNetDevice::GetUplinkScheduler(), m_device, ns3::Cid::MULTICAST, ns3::ServiceFlow::SetConnection(), ns3::ServiceFlow::SetIsEnabled(), ns3::ServiceFlow::SetIsMulticast(), ns3::ServiceFlow::SetModulation(), ns3::ServiceFlow::SetType(), ns3::UplinkScheduler::SetupServiceFlow(), and ns3::ServiceFlow::SF_TYPE_ACTIVE.
Referenced by main().
void ns3::BsServiceFlowManager::AddServiceFlow | ( | ServiceFlow * | serviceFlow | ) |
Add a new service flow.
serviceFlow | the service flow to add |
Reimplemented from ns3::ServiceFlowManager.
Definition at line 81 of file bs-service-flow-manager.cc.
Referenced by AddMulticastServiceFlow(), and ProcessDsaReq().
Definition at line 226 of file bs-service-flow-manager.cc.
References NS_LOG_INFO, ProcessDsaReq(), and ScheduleDsaRsp().
Referenced by ns3::BaseStationNetDevice::DoReceive().
|
private |
Definition at line 105 of file bs-service-flow-manager.cc.
References CONFIRMATION_CODE_SUCCESS, ns3::DsaRsp::SetConfirmationCode(), ns3::DsaRsp::SetServiceFlow(), and ns3::DsaRsp::SetTransactionId().
Referenced by ScheduleDsaRsp().
|
virtual |
This method is called by Object::Dispose or by the object's destructor, whichever comes first.
Subclasses are expected to implement their real destruction code in an overriden version of this method and chain up to their parent's implementation once they are done. i.e., for simplicity, the destructor of every subclass should be empty and its content should be moved to the associated DoDispose method.
It is safe to call GetObject from within this method.
Reimplemented from ns3::ServiceFlowManager.
Definition at line 57 of file bs-service-flow-manager.cc.
EventId ns3::BsServiceFlowManager::GetDsaAckTimeoutEvent | ( | void | ) | const |
Definition at line 75 of file bs-service-flow-manager.cc.
References m_dsaAckTimeoutEvent.
|
private |
Definition at line 69 of file bs-service-flow-manager.cc.
References m_maxDsaRspRetries.
ServiceFlow * ns3::BsServiceFlowManager::GetServiceFlow | ( | uint32_t | sfid | ) | const |
Reimplemented from ns3::ServiceFlowManager.
Definition at line 87 of file bs-service-flow-manager.cc.
Referenced by GetServiceFlow(), ProcessDsaReq(), and ns3::BaseStationNetDevice::SendBursts().
ServiceFlow * ns3::BsServiceFlowManager::GetServiceFlow | ( | Cid | cid | ) | const |
Reimplemented from ns3::ServiceFlowManager.
Definition at line 93 of file bs-service-flow-manager.cc.
References GetServiceFlow().
std::vector< ServiceFlow * > ns3::BsServiceFlowManager::GetServiceFlows | ( | ServiceFlow::SchedulingType | schedulingType | ) | const |
Reimplemented from ns3::ServiceFlowManager.
Definition at line 99 of file bs-service-flow-manager.cc.
Referenced by ns3::BSSchedulerRtps::BSSchedulerBEConnection(), ns3::BSSchedulerRtps::BSSchedulerNRTPSConnection(), ns3::BSSchedulerRtps::BSSchedulerRTPSConnection(), ns3::BSSchedulerRtps::BSSchedulerUGSConnection(), ns3::BaseStationNetDevice::DoSend(), and ns3::BSSchedulerSimple::SelectConnection().
process a DSA-ACK message
dsaAck | the message to process |
cid | the identifier of the connection on which the message was received |
Definition at line 237 of file bs-service-flow-manager.cc.
References ns3::ServiceFlowManager::AreServiceFlowsAllocated(), ns3::Object::GetObject(), ns3::BaseStationNetDevice::GetSSManager(), ns3::SSManager::GetSSRecord(), ns3::DsaAck::GetTransactionId(), m_device, ns3::SSRecord::SetDsaRspRetries(), and ns3::ServiceFlow::SF_TYPE_ALL.
Referenced by ns3::BaseStationNetDevice::DoReceive().
ServiceFlow * ns3::BsServiceFlowManager::ProcessDsaReq | ( | const DsaReq & | dsaReq, |
Cid | cid | ||
) |
process a DSA-Req message
dsaReq | the message to process |
cid | the identifier of the connection on which the message was received |
Definition at line 175 of file bs-service-flow-manager.cc.
References AddServiceFlow(), ns3::ServiceFlow::CopyParametersFrom(), ns3::ConnectionManager::CreateConnection(), ns3::ServiceFlow::GetCid(), ns3::WimaxNetDevice::GetConnectionManager(), ns3::ServiceFlow::GetConvergenceSublayerParam(), ns3::ServiceFlow::GetDirection(), ns3::Object::GetObject(), GetServiceFlow(), ns3::DsaReq::GetServiceFlow(), ns3::ServiceFlow::GetSfid(), ns3::BaseStationNetDevice::GetSSManager(), ns3::SSManager::GetSSRecord(), ns3::DsaReq::GetTransactionId(), m_device, m_sfidIndex, NS_ASSERT_MSG, NS_LOG_INFO, ns3::ServiceFlow::SetConvergenceSublayerParam(), ns3::WimaxConnection::SetServiceFlow(), ns3::ServiceFlow::SetUnsolicitedGrantInterval(), ns3::ServiceFlow::SetUnsolicitedPollingInterval(), and ns3::Cid::TRANSPORT.
Referenced by AllocateServiceFlows().
|
private |
Definition at line 117 of file bs-service-flow-manager.cc.
References ns3::Packet::AddHeader(), ns3::Simulator::Cancel(), CreateDsaRsp(), ns3::WimaxNetDevice::Enqueue(), ns3::BaseStationNetDevice::GetConnection(), ns3::BaseStationNetDevice::GetIntervalT8(), ns3::Object::GetObject(), ns3::BaseStationNetDevice::GetSSManager(), ns3::SSManager::GetSSRecord(), ns3::BaseStationNetDevice::GetUplinkScheduler(), ns3::EventId::IsRunning(), m_device, m_dsaAckTimeoutEvent, m_inuseScheduleDsaRspCid, m_maxDsaRspRetries, ns3::ManagementMessageType::MESSAGE_TYPE_DSA_RSP, NS_LOG_DEBUG, NS_LOG_INFO, ns3::Simulator::Schedule(), ns3::ServiceFlow::SetIsEnabled(), ns3::ServiceFlow::SetType(), ns3::UplinkScheduler::SetupServiceFlow(), and ns3::ServiceFlow::SF_TYPE_ACTIVE.
Referenced by AllocateServiceFlows().
void ns3::BsServiceFlowManager::SetMaxDsaRspRetries | ( | uint8_t | maxDsaRspRetries | ) |
set the maximum Dynamic ServiceFlow Add (DSA) retries
Definition at line 63 of file bs-service-flow-manager.cc.
References m_maxDsaRspRetries.
|
private |
Definition at line 101 of file bs-service-flow-manager.h.
Referenced by AddMulticastServiceFlow(), ProcessDsaAck(), ProcessDsaReq(), and ScheduleDsaRsp().
|
private |
Definition at line 104 of file bs-service-flow-manager.h.
Referenced by GetDsaAckTimeoutEvent(), and ScheduleDsaRsp().
|
private |
Definition at line 105 of file bs-service-flow-manager.h.
Referenced by BsServiceFlowManager(), and ScheduleDsaRsp().
|
private |
Definition at line 103 of file bs-service-flow-manager.h.
Referenced by GetMaxDsaRspRetries(), ScheduleDsaRsp(), and SetMaxDsaRspRetries().
|
private |
Definition at line 102 of file bs-service-flow-manager.h.
Referenced by ProcessDsaReq().