User Manual, Developers Guide and API Documentation

wimac::service::ConnectionManager Class Reference

Manager to manage connections. More...

#include <services/ConnectionManager.hpp>

Inheritance diagram for wimac::service::ConnectionManager:

Inheritance graph
[legend]
Collaboration diagram for wimac::service::ConnectionManager:

Collaboration graph
[legend]

List of all members.

Public Member Functions

ConnectionIdentifier appendConnection (const ConnectionIdentifier &connection)
 Register a new connection. Return ConnectionIdentifier with new CID from AP().
void changeConnection (const ConnectionIdentifier &connection)
 Changes values but not the primary keys of the connection.
void changeConnections (ConnectionIdentifiers &connections)
 Changes values but not the primary keys of the connections.
 ConnectionManager (const ConnectionManager &other)
 ConnectionManager (const wns::pyconfig::View &config)
 ConnectionManager (wns::ldk::ManagementServiceRegistry *msr, const wns::pyconfig::View &config)
void decreaseCINotListening ()
 Decrease all ConnectionIdentifiers who are not listening.
void deleteAllConnections ()
 Delete all connections.
void deleteCI (ConnectionIdentifier::CID cid)
 Delete connection with given CID.
void deleteConnectionsForBS (ConnectionIdentifier::StationID baseStation)
 Delete connections with given ID for departure and destination.
void deleteConnectionsForSS (ConnectionIdentifier::StationID subscriberStation)
 Delete connections with given ID for departure and destination.
ConnectionIdentifierPtr findConnection (const wns::ldk::CompoundPtr &compound) const
 Find a registered connection for the given Compound.
ConnectionIdentifiers getAllBasicConnections () const
 Find all basic connection.
ConnectionIdentifiers getAllCIForBS (ConnectionIdentifier::StationID baseStation)
 Get a list of all ConnectionIdentifiers which belong to this base station.
ConnectionIdentifiers getAllCIForSS (ConnectionIdentifier::StationID subscriberStation) const
 Get a list of all ConnectionIdentifiers which belong to this subscriber station.
ConnectionIdentifiers getAllConnections ()
 Get a list of ConnectionIdentifiers for all connections stored in the Connection Manager.
ConnectionIdentifiers getAllDataConnections (int direction)
ConnectionIdentifiers getAllDataConnections (int direction, ConnectionIdentifier::QoSCategory)
 Get all data connections with the specified direction.
ConnectionIdentifier::CID getAndIncreaseHighestCellCID ()
ConnectionIdentifierPtr getBasicConnectionFor (const StationID subscriberStation) const
 Return the basic connection that belongs to the given subscriberStation.
ConnectionIdentifierPtr getBasicConnectionFor (const ConnectionIdentifier::CID cid)
 Return the basic connection that belongs to the given connection.
ConnectionIdentifierPtr getConnection (const wns::ldk::CompoundPtr &compound) const
 Get ConnectionIdentifier for that compound by using CID from the wimac::Classifier.
ConnectionIdentifierPtr getConnectionWithID (ConnectionIdentifier::CID cid) const
 Find the connection with the specified CID.
ConnectionIdentifiers getIncomingConnections (ConnectionIdentifier::StationID from)
 Get a list of ConnectionIdentifiers for incoming connections from a specified departure.
ConnectionIdentifiers getIncomingDataConnections (ConnectionIdentifier::StationID from, ConnectionIdentifier::QoSCategory)
 Get a list of ConnectionIdentifiers for incoming data connections from a specified departure.
ConnectionIdentifiers getOutgoingConnections (ConnectionIdentifier::StationID to)
 Get a list of ConnectionIdentifiers for outgoing connections to a specified destination.
ConnectionIdentifiers getOutgoingDataConnections (ConnectionIdentifier::StationID to, ConnectionIdentifier::QoSCategory)
 Get a list of ConnectionIdentifiers for outgoin data connections to a specified destination.
ConnectionIdentifierPtr getPrimaryConnectionFor (ConnectionIdentifier::StationID stationID) const
 Return the primary management connection that belongs to the given connection.
ConnectionIdentifierPtr getSpecialConnection (ConnectionIdentifier::ConnectionType connectionType, ConnectionIdentifier::StationID baseStation, ConnectionIdentifier::StationID subscriber)
 Get a special connection of type connectionType.
void onMSRCreated ()

Private Types

typedef wns::Subject
< ConnectionDeletedNotification
Subject

Private Member Functions

void doubleBasicCIDeleteAllOtherCI (const ConnectionIdentifierPtr ci)
 On a double basic ConnectionIdentifier all other ConnectionIdentifier for peer station will be deleted.
void singularityDelete (const ConnectionIdentifierPtr ci)
 Delete ConnectionIdentifier from ConnectionManager if they exist.

Private Attributes

wns::pyconfig::View config_
ConnectionIdentifiers connectionIdentifiers_
ConnectionIdentifier::CID highestCID_
Componentlayer_
 Station this ConnectionManager belongs to.


Detailed Description

The ConnectionManager holds a database for registered connections. Each connection is associated with a connection rule. The ConnectionManager also acts like a Classifier. Compounds may be classified by the findConnection() method.

Todo:
The ConnectionManager needs refactoring of the interface. I suppose there are some redundant methods.

Definition at line 106 of file ConnectionManager.hpp.


Member Typedef Documentation

Definition at line 112 of file ConnectionManager.hpp.


Constructor & Destructor Documentation

ConnectionManager::ConnectionManager ( wns::ldk::ManagementServiceRegistry msr,
const wns::pyconfig::View config 
)

Definition at line 59 of file ConnectionManager.cpp.

wimac::service::ConnectionManager::ConnectionManager ( const wns::pyconfig::View config  )  [explicit]

ConnectionManager::ConnectionManager ( const ConnectionManager other  ) 

Definition at line 70 of file ConnectionManager.cpp.


Member Function Documentation

ConnectionIdentifier ConnectionManager::appendConnection ( const ConnectionIdentifier connection  ) 

Definition at line 83 of file ConnectionManager.cpp.

void ConnectionManager::changeConnection ( const ConnectionIdentifier connection  ) 

Definition at line 235 of file ConnectionManager.cpp.

void ConnectionManager::changeConnections ( ConnectionIdentifiers connections  ) 

Definition at line 261 of file ConnectionManager.cpp.

void ConnectionManager::decreaseCINotListening (  ) 

Definition at line 795 of file ConnectionManager.cpp.

void ConnectionManager::deleteAllConnections (  ) 

Definition at line 132 of file ConnectionManager.cpp.

void ConnectionManager::deleteCI ( ConnectionIdentifier::CID  cid  ) 

Definition at line 196 of file ConnectionManager.cpp.

void ConnectionManager::deleteConnectionsForBS ( ConnectionIdentifier::StationID  baseStation  ) 

Definition at line 149 of file ConnectionManager.cpp.

void ConnectionManager::deleteConnectionsForSS ( ConnectionIdentifier::StationID  subscriberStation  ) 

Definition at line 173 of file ConnectionManager.cpp.

void ConnectionManager::doubleBasicCIDeleteAllOtherCI ( const ConnectionIdentifierPtr  ci  )  [private]

Definition at line 894 of file ConnectionManager.cpp.

ConnectionIdentifierPtr wimac::service::ConnectionManager::findConnection ( const wns::ldk::CompoundPtr compound  )  const

The compound does not need to be classified before. The connection manager looks after a match in the registered connection rules. This method is usually only used by the ConnectionClassifier. To look for connections for a already classified compound use getConnectionWithID().

Returns:
pointer to the registered connection or an empty pointer

ConnectionIdentifiers ConnectionManager::getAllBasicConnections (  )  const

Definition at line 743 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getAllCIForBS ( ConnectionIdentifier::StationID  baseStation  ) 

Definition at line 334 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getAllCIForSS ( ConnectionIdentifier::StationID  subscriberStation  )  const

Definition at line 313 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getAllConnections (  ) 

Definition at line 297 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getAllDataConnections ( int  direction  ) 

Definition at line 597 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getAllDataConnections ( int  direction,
ConnectionIdentifier::QoSCategory  qos 
)

See also:
ConnectionIdentifier::Direction

Definition at line 577 of file ConnectionManager.cpp.

ConnectionIdentifier::CID ConnectionManager::getAndIncreaseHighestCellCID (  ) 

Definition at line 938 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getBasicConnectionFor ( const StationID  subscriberStation  )  const

This is used by the Handover.

Definition at line 724 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getBasicConnectionFor ( const ConnectionIdentifier::CID  cid  )  [virtual]

This is used by the ACKSwitch to switch the connection of an ACK that needs to be transmitted via the basic connection.

Implements wimac::service::ConnectionManagerInterface.

Definition at line 700 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getConnection ( const wns::ldk::CompoundPtr compound  )  const

Definition at line 816 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getConnectionWithID ( ConnectionIdentifier::CID  cid  )  const

Definition at line 681 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getIncomingConnections ( ConnectionIdentifier::StationID  from  ) 

Definition at line 529 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getIncomingDataConnections ( ConnectionIdentifier::StationID  from,
ConnectionIdentifier::QoSCategory  qos 
)

Definition at line 355 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getOutgoingConnections ( ConnectionIdentifier::StationID  to  ) 

Definition at line 481 of file ConnectionManager.cpp.

ConnectionIdentifiers ConnectionManager::getOutgoingDataConnections ( ConnectionIdentifier::StationID  to,
ConnectionIdentifier::QoSCategory  qos 
)

Definition at line 418 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getPrimaryConnectionFor ( ConnectionIdentifier::StationID  stationID  )  const

Definition at line 759 of file ConnectionManager.cpp.

ConnectionIdentifierPtr ConnectionManager::getSpecialConnection ( ConnectionIdentifier::ConnectionType  connectionType,
ConnectionIdentifier::StationID  baseStation,
ConnectionIdentifier::StationID  subscriber 
)

Find a special connection between the baseStation and the subscriber of type connectionType.

See also:
ConnectionIdentifier::ConnectionType

Definition at line 646 of file ConnectionManager.cpp.

void ConnectionManager::onMSRCreated (  )  [virtual]

Reimplemented from wns::ldk::ManagementService.

Definition at line 791 of file ConnectionManager.cpp.

void ConnectionManager::singularityDelete ( const ConnectionIdentifierPtr  ci  )  [private]

Definition at line 846 of file ConnectionManager.cpp.


Member Data Documentation

Todo:
Remove the pyconfig view from here.

Definition at line 349 of file ConnectionManager.hpp.

Definition at line 337 of file ConnectionManager.hpp.

Definition at line 339 of file ConnectionManager.hpp.

Definition at line 344 of file ConnectionManager.hpp.


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

Generated on Sat May 26 03:32:46 2012 for openWNS by  doxygen 1.5.5