Public Member Functions

ns3::CidFactory Class Reference

#include <cid-factory.h>

List of all members.

Public Member Functions

 CidFactory (void)
Cid AllocateBasic (void)
 This function returns the next basic CID.
Cid AllocatePrimary (void)
 This function returns the next primary basic CID.
Cid AllocateTransportOrSecondary (void)
 This function returns the next Transport (or Secondary) CID.
Cid AllocateMulticast (void)
 This function returns the next Multicast CID.
Cid Allocate (enum Cid::Type type)
bool IsTransport (Cid cid) const
bool IsPrimary (Cid cid) const
bool IsBasic (Cid cid) const
void FreeCid (Cid cid)

Detailed Description

This class is used exclusively by the BS to allocate CIDs to new connections. This class uses the definitions from Table 345 in ieee-802.16-2004 to allocate cids in different integer ranges according to their type. The relative allocation of the ranges is controlled by the parameter 'm' introduced in the above-mentionned table.

Note: The current implementation merely allocates cids sequentially from the start of the allowed range. A proper implementation would be able to recycle cids from previous dead connections and should instead look at a bitmap of free cids. Some other day :)


Constructor & Destructor Documentation

ns3::CidFactory::CidFactory ( void   ) 

Create a cid factory with a default value for m of 0x5500.


Member Function Documentation

Cid ns3::CidFactory::AllocateBasic ( void   ) 

This function returns the next basic CID.

Returns:
the next basic CID.
Cid ns3::CidFactory::AllocateMulticast ( void   ) 

This function returns the next Multicast CID.

Returns:
the next Multicast CID.
Cid ns3::CidFactory::AllocatePrimary ( void   ) 

This function returns the next primary basic CID.

Returns:
the next primary CID.
Cid ns3::CidFactory::AllocateTransportOrSecondary ( void   ) 

This function returns the next Transport (or Secondary) CID.

Returns:
the next Transport (or Secondary) CID.
void ns3::CidFactory::FreeCid ( Cid  cid  ) 

Notify the factory that the connection associated to this cid has been killed and that this cid can be reused.


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