a few edits on the doxygen

This commit is contained in:
Tom Henderson
2007-07-23 20:06:00 -07:00
parent bdf28a79fc
commit b16efc8c0b
5 changed files with 38 additions and 24 deletions

View File

@@ -72,7 +72,8 @@ Therefore, we think that enabling these other link types will be more
straightforward now that the underlying OSPF SPF framework is in place.
Presently, we can handle IPv4 point-to-point, numbered links, and we do
not do equal-cost multipath.
not do equal-cost multipath. We also do not allow for non-unit-cost
links, although it should be trivially extensible to do so.
The support for this relies on the node object supporting a StaticRouter
interface. This can be manually added to each node, or alternatively,
@@ -124,3 +125,9 @@ router component into the node such as Gustavo's OLSR code does
the StaticRouteManager. One possibility I would be fine with is to call
it GlobalRouteManager (although I would still argue it adds static routes
into the nodes in any case).
- this method probably belongs in the Ipv4 (find InterfaceId corresponding
to the provided address)
uint32_t
StaticRouteManagerImpl::FindOutgoingInterfaceId (Ipv4Address a)

View File

@@ -23,8 +23,17 @@
namespace ns3 {
namespace RoutingEnvironment {
/**
* @brief This function tests the value of the global default value
* "DoStaticRouting". This approach puts everything in one compilation
* unit, as opposed to explicitly testing the value of the underlying
* static variable.
*/
bool StaticRoutingEnabled(void);
/**
* @brief Allocate a 32-bit router ID from monotonically increasing counter.
*/
uint32_t AllocateRouterId(void);
} // namespace RoutingEnvironment

View File

@@ -505,7 +505,7 @@ StaticRouteManagerImpl::SPFNext (SPFVertex* v, CandidateQueue& candidate)
StaticRouterLSA::LSA_SPF_NOT_EXPLORED)
{
//
// If we havent yet considered the link represented by <w> we have to create
// If we haven't yet considered the link represented by <w> we have to create
// a new SPFVertex to represent it.
//
w = new SPFVertex (w_lsa);
@@ -710,9 +710,6 @@ StaticRouteManagerImpl::SPFNexthopCalculation (
// Router Link Record we find that describes a point-to-point link from <v>
// to <w>. If prev_link is not NULL, we return a Static Router Link Record
// representing a possible *second* link from <v> to <w>.
//
// BUGBUG FIXME: This seems to be a bug. Shouldn't this function look for
// any link records after pre_link and not just after the first?
//
StaticRouterLinkRecord*
StaticRouteManagerImpl::SPFGetNextLink (
@@ -928,7 +925,7 @@ StaticRouteManagerImpl::SPFCalculate (Ipv4Address root)
}
//
// BUGBUG FIXME: This should probably be a method on Ipv4
// XXX This should probably be a method on Ipv4
//
// Return the interface index corresponding to a given IP address
//
@@ -1360,12 +1357,14 @@ StaticRouteManagerImplTest::RunTests (void)
srmlsdb->Insert (lsa3->GetLinkStateId (), lsa3);
NS_ASSERT (lsa2 == srmlsdb->GetLSA (lsa2->GetLinkStateId ()));
// XXX next, calculate routes based on the manually created LSDB
// next, calculate routes based on the manually created LSDB
StaticRouteManagerImpl* srm = new StaticRouteManagerImpl ();
srm->DebugUseLsdb (srmlsdb); // manually add in an LSDB
// Note-- this will succeed without any nodes in the topology
// because the NodeList is empty
srm->DebugSPFCalculate (lsa0->GetLinkStateId ()); // node n0
// XXX here we should do some verification of the routes built
// This delete clears the srm, which deletes the LSDB, which clears
// all of the LSAs, which each destroys the attached LinkRecords.

View File

@@ -136,7 +136,7 @@ public:
* representing routers, and comes from the Link State Advertisement of a
* router aggregated to a node in the simulation. These IDs are allocated
* automatically by the routing environment and look like IP addresses
* beginning at 0.0.0.0 and monotonically increasing as new routers are
* beginning at 0.0.0.0 and monotonically increase as new routers are
* instantiated.
*
* @returns The Ipv4Address Vertex ID of the current SPFVertex object.
@@ -150,8 +150,9 @@ public:
* representing routers, and comes from the Link State Advertisement of a
* router aggregated to a node in the simulation. These IDs are allocated
* automatically by the routing environment and look like IP addresses
* beginning at 0.0.0.0 and monotonically increasing as new routers are
* instantiated.
* beginning at 0.0.0.0 and monotonically increase as new routers are
* instantiated. This method is an explicit override of the automatically
* generated value.
*
* @param id The new Ipv4Address Vertex ID for the current SPFVertex object.
*/
@@ -520,7 +521,7 @@ private:
};
/**
* @brief The Link State DataBase (LSDB) of the Static Route Manager.
* @brief The Link State DataBase (LSDB) of the StaticRouteManager.
*
* Each node in the simulation participating in static routing has a
* StaticRouter interface. The primary job of this interface is to export
@@ -536,14 +537,14 @@ class StaticRouteManagerLSDB
{
public:
/**
* @brief Construct an empty Static Router Manager Link State Database.
* @brief Construct an empty StaticRoutingManager Link State Database.
*
* The database map composing the Link State Database is initialized in
* this constructor.
*/
StaticRouteManagerLSDB ();
/**
* @brief Destroy an empty Static Router Manager Link State Database.
* @brief Destroy an empty StaticRoutingManager Link State Database.
*
* The database map is walked and all of the Link State Advertisements stored
* in the database are freed; then the database map itself is clear ()ed to
@@ -599,7 +600,7 @@ private:
LSDBMap_t m_database;
/**
* @brief StaticRouteManagerLSDB copy construction is disallowed. There's no
* need for it and a compiler provided shallow copy would be hopelessly wrong.
* need for it and a compiler provided shallow copy would be wrong.
*/
StaticRouteManagerLSDB (StaticRouteManagerLSDB& lsdb);
/**
@@ -646,15 +647,15 @@ public:
void DebugSPFCalculate (Ipv4Address root);
private:
/**
* @brief Static Route Manager Implementation copy construction is disallowed.
* @brief StaticRouteManager Implementation copy construction is disallowed.
* There's no need for it and a compiler provided shallow copy would be
* hopelessly wrong.
* wrong.
*/
StaticRouteManagerImpl (StaticRouteManagerImpl& srmi);
/**
* @brief Static Route Manager Implementation assignment operator is
* @brief StaticRouteManager Implementation assignment operator is
* disallowed. There's no need for it and a compiler provided shallow copy
* would be hopelessly wrong.
* would be wrong.
*/
StaticRouteManagerImpl& operator= (StaticRouteManagerImpl& srmi);

View File

@@ -38,9 +38,7 @@ public:
* the nodes in the simulation.
*
* All this function does is call BuildStaticRoutingDatabase () and
* InitializeRoutes (). There's no reason to export the two-step process
* since a high-level caller has no need to know how we're implementing the
* process.
* InitializeRoutes ().
*
* @see BuildStaticRoutingDatabase ();
* @see InitializeRoutes ();
@@ -60,13 +58,13 @@ private:
static void InitializeRoutes ();
/**
* @brief Static Route Manager copy construction is disallowed. There's no
* need for it and a compiler provided shallow copy would be hopelessly wrong.
* need for it and a compiler provided shallow copy would be wrong.
*
*/
StaticRouteManager (StaticRouteManager& srm);
/**
* @brief Static Router copy assignment operator is disallowed. There's no
* need for it and a compiler provided shallow copy would be hopelessly wrong.
* need for it and a compiler provided shallow copy would be wrong.
*/
StaticRouteManager& operator= (StaticRouteManager& srm);
};