# HG changeset patch # User Kirill Andreev # Date 1248263815 -14400 # Node ID b5062e8e0da17a1db6915c9a2cf8b9454b2f3517 # Parent 5688b8da45260811e9c48c11edae47849a87a4ab Fixed coding style diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/airtime-metric.h --- a/src/devices/mesh/dot11s/airtime-metric.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/airtime-metric.h Wed Jul 22 15:56:55 2009 +0400 @@ -45,7 +45,7 @@ { public: static TypeId GetTypeId (); - uint32_t CalculateMetric(Mac48Address peerAddress, Ptr mac); + uint32_t CalculateMetric (Mac48Address peerAddress, Ptr mac); private: //\brief Overhead expressed in nanoseconds:DIFS+ 2* SIFS + 2*PREAMBLE + 2* ACK uint32_t m_overheadNanosec; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-protocol-mac.cc --- a/src/devices/mesh/dot11s/hwmp-protocol-mac.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-protocol-mac.cc Wed Jul 22 15:56:55 2009 +0400 @@ -144,7 +144,9 @@ std::vector destinations = perr.GetAddressUnitVector (); for (std::vector::const_iterator i = destinations.begin (); i != destinations.end (); i++) - failedDestinations.push_back (*i); + { + failedDestinations.push_back (*i); + } } if (failedDestinations.size () > 0) { diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-protocol-mac.h --- a/src/devices/mesh/dot11s/hwmp-protocol-mac.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-protocol-mac.h Wed Jul 22 15:56:55 2009 +0400 @@ -68,7 +68,7 @@ void SendPreq (std::vector preq); void SendPrep (IePrep prep, Mac48Address receiver); //Forward a peth error - void ForwardPerr(std::vector destinations, std::vector receivers); + void ForwardPerr (std::vector destinations, std::vector receivers); // initiate my own path error void InitiatePerr (std::vector destinations, std::vector receivers); /** \brief Request a destination. If can not send preq immediately - diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-protocol.cc --- a/src/devices/mesh/dot11s/hwmp-protocol.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-protocol.cc Wed Jul 22 15:56:55 2009 +0400 @@ -186,7 +186,7 @@ m_rfFlag (false) { - if(m_isRoot) + if (m_isRoot) { SetRoot (); } @@ -199,7 +199,7 @@ void HwmpProtocol::DoDispose () { - for (std::map::iterator i = m_preqTimeouts.begin (); i != m_preqTimeouts.end(); i ++) + for (std::map::iterator i = m_preqTimeouts.begin (); i != m_preqTimeouts.end (); i ++) { i->second.Cancel (); } @@ -225,9 +225,9 @@ Ptr packet = constPacket->Copy (); HwmpTag tag; if (sourceIface == GetMeshPoint ()->GetIfIndex()) - // packet from level 3 { - if (packet->PeekPacketTag(tag)) + // packet from level 3 + if (packet->PeekPacketTag (tag)) { NS_FATAL_ERROR ("HWMP tag has come with a packet from upper layer. This must not occur..."); } @@ -240,7 +240,7 @@ } else { - if (!packet->RemovePacketTag(tag)) + if (!packet->RemovePacketTag (tag)) { NS_FATAL_ERROR ("HWMP tag is supposed to be here at this point."); } @@ -260,7 +260,7 @@ for (HwmpProtocolMacMap::const_iterator plugin = m_interfaces.begin (); plugin != m_interfaces.end (); plugin ++) { bool should_send = true; - for (std::vector::const_iterator chan = channels.begin(); chan != channels.end(); chan ++) + for (std::vector::const_iterator chan = channels.begin (); chan != channels.end (); chan ++) { if ((*chan) == plugin->second->GetChannelId ()) { @@ -271,9 +271,9 @@ { continue; } - channels.push_back(plugin->second->GetChannelId ()); + channels.push_back (plugin->second->GetChannelId ()); std::vector receivers = GetBroadcastReceivers (plugin->first); - for (std::vector::const_iterator i = receivers.begin (); i != receivers.end(); i ++) + for (std::vector::const_iterator i = receivers.begin (); i != receivers.end (); i ++) { Ptr packet_copy = packet->Copy(); tag.SetAddress (*i); @@ -304,7 +304,7 @@ Ptr packet, uint16_t protocolType, RouteReplyCallback routeReply, uint32_t ttl) { NS_ASSERT(destination != Mac48Address::GetBroadcast ()); - HwmpRtable::LookupResult result = m_rtable->LookupReactive(destination); + HwmpRtable::LookupResult result = m_rtable->LookupReactive (destination); NS_LOG_DEBUG("Requested src = "<LookupReactive(prep.GetDestinationAddress ()); + HwmpRtable::LookupResult result = m_rtable->LookupReactive (prep.GetDestinationAddress ()); //Add a reactive path only if it is better than existing: if ( ((m_rtable->LookupReactive (prep.GetOriginatorAddress ())).retransmitter == Mac48Address::GetBroadcast ()) || @@ -605,7 +605,7 @@ prep.GetOriginatorSeqNumber ()); ReactivePathResolved (fromMp); } - if(prep.GetDestinationAddress () == GetAddress ()) + if (prep.GetDestinationAddress () == GetAddress ()) { NS_LOG_DEBUG("I am "< retval; HwmpRtable::LookupResult result; - for(unsigned int i = 0; i < destinations.size (); i ++) + for (unsigned int i = 0; i < destinations.size (); i ++) { result = m_rtable->LookupReactive (destinations[i].destination); if (!( @@ -640,10 +640,10 @@ (result.seqnum > destinations[i].seqnum) )) { - retval.push_back(destinations[i]); + retval.push_back (destinations[i]); } } - if (retval.size() == 0) + if (retval.size () == 0) { return; } @@ -679,7 +679,7 @@ { m_mp = mp; std::vector > interfaces = mp->GetInterfaces (); - for (std::vector >::const_iterator i = interfaces.begin (); i != interfaces.end(); i++) + for (std::vector >::const_iterator i = interfaces.begin (); i != interfaces.end (); i++) { // Checking for compatible net device Ptr wifiNetDev = (*i)->GetObject (); @@ -698,7 +698,7 @@ mac->InstallPlugin (hwmpMac); //Installing airtime link metric: Ptr metric = CreateObject (); - mac->SetLinkMetricCallback (MakeCallback(&AirtimeLinkMetricCalculator::CalculateMetric, metric)); + mac->SetLinkMetricCallback (MakeCallback (&AirtimeLinkMetricCalculator::CalculateMetric, metric)); } mp->SetRoutingProtocol (this); // Mesh point aggregates all installed protocols @@ -717,12 +717,12 @@ InitiatePathError (MakePathError (destinations)); } void -HwmpProtocol::SetNeighboursCallback(Callback, uint32_t> cb) +HwmpProtocol::SetNeighboursCallback (Callback, uint32_t> cb) { m_neighboursCallback = cb; } bool -HwmpProtocol::DropDataFrame(uint32_t seqno, Mac48Address source) +HwmpProtocol::DropDataFrame (uint32_t seqno, Mac48Address source) { if (source == GetAddress ()) { @@ -756,8 +756,8 @@ m_stats.initiatedPerr ++; for (unsigned int i = 0; i < destinations.size (); i ++) { - retval.destinations.push_back(destinations[i]); - m_rtable->DeleteReactivePath(destinations[i].destination); + retval.destinations.push_back (destinations[i]); + m_rtable->DeleteReactivePath (destinations[i].destination); } return retval; } @@ -767,7 +767,7 @@ for (HwmpProtocolMacMap::const_iterator i = m_interfaces.begin (); i != m_interfaces.end (); i ++) { std::vector receivers_for_interface; - for (unsigned int j = 0; j < perr.receivers.size(); j ++) + for (unsigned int j = 0; j < perr.receivers.size (); j ++) { if (i->first == perr.receivers[j].first) { @@ -783,11 +783,11 @@ for (HwmpProtocolMacMap::const_iterator i = m_interfaces.begin (); i != m_interfaces.end (); i ++) { std::vector receivers_for_interface; - for (unsigned int j = 0; j < perr.receivers.size(); j ++) + for (unsigned int j = 0; j < perr.receivers.size (); j ++) { if (i->first == perr.receivers[j].first) { - receivers_for_interface.push_back(perr.receivers[j].second); + receivers_for_interface.push_back (perr.receivers[j].second); } } i->second->ForwardPerr (perr.destinations, receivers_for_interface); @@ -802,10 +802,10 @@ { HwmpRtable::PrecursorList precursors = m_rtable->GetPrecursors (failedDest[i].destination); m_rtable->DeleteReactivePath (failedDest[i].destination); - m_rtable->DeleteProactivePath(failedDest[i].destination); + m_rtable->DeleteProactivePath (failedDest[i].destination); for (unsigned int j = 0; j < precursors.size (); j ++) { - retval.push_back(precursors[j]); + retval.push_back (precursors[j]); } } //Check if we have dublicates in retval and precursors: @@ -815,7 +815,7 @@ { if (retval[i].second == retval[j].second) { - retval.erase(retval.begin() + j); + retval.erase (retval.begin () + j); } } } @@ -829,7 +829,7 @@ { retval = m_neighboursCallback (interface); } - if ((retval.size() >= m_unicastPreqThreshold) || (retval.size () == 0)) + if ((retval.size () >= m_unicastPreqThreshold) || (retval.size () == 0)) { retval.clear (); retval.push_back (Mac48Address::GetBroadcast ()); @@ -844,7 +844,7 @@ { retval = m_neighboursCallback (interface); } - if ((retval.size() >= m_unicastDataThreshold) || (retval.size () == 0)) + if ((retval.size () >= m_unicastDataThreshold) || (retval.size () == 0)) { retval.clear (); retval.push_back (Mac48Address::GetBroadcast ()); @@ -963,7 +963,7 @@ if (result.retransmitter != Mac48Address::GetBroadcast ()) { std::map::iterator i = m_preqTimeouts.find (dst); - NS_ASSERT (i != m_preqTimeouts.end()); + NS_ASSERT (i != m_preqTimeouts.end ()); m_preqTimeouts.erase (i); return; } @@ -991,7 +991,7 @@ } for (HwmpProtocolMacMap::const_iterator i = m_interfaces.begin (); i != m_interfaces.end (); i ++) { - i->second->RequestDestination(dst, originator_seqno, dst_seqno); + i->second->RequestDestination (dst, originator_seqno, dst_seqno); } m_preqTimeouts[dst] = Simulator::Schedule ( MilliSeconds (2*(m_dot11MeshHWMPnetDiameterTraversalTime.GetMilliSeconds())), @@ -1002,7 +1002,7 @@ HwmpProtocol::SetRoot () { UniformVariable coefficient (0.0, m_randomStart.GetSeconds()); - Time randomStart = Seconds (coefficient.GetValue()); + Time randomStart = Seconds (coefficient.GetValue ()); m_proactivePreqTimer = Simulator::Schedule (randomStart, &HwmpProtocol::SendProactivePreq, this); NS_LOG_DEBUG ("ROOT IS: " << m_address); SendProactivePreq (); @@ -1076,7 +1076,7 @@ return m_dot11MeshHWMPactivePathTimeout.GetMicroSeconds () / 1024; } uint8_t -HwmpProtocol::GetUnicastPerrThreshold() +HwmpProtocol::GetUnicastPerrThreshold () { return m_unicastPerrThreshold; } @@ -1149,4 +1149,4 @@ } } //namespace dot11s - } //namespace ns3 +} //namespace ns3 diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-protocol.h --- a/src/devices/mesh/dot11s/hwmp-protocol.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-protocol.h Wed Jul 22 15:56:55 2009 +0400 @@ -67,11 +67,11 @@ * via MeshPointDevice::GetObject(); */ bool Install (Ptr); - void PeerLinkStatus(Mac48Address meshPontAddress, Mac48Address peerAddress, uint32_t interface,bool status); + void PeerLinkStatus (Mac48Address meshPontAddress, Mac48Address peerAddress, uint32_t interface,bool status); ///\brief This callback is used to obtain active neighbours on a //given interface ///\param interface is the interface ID - void SetNeighboursCallback(Callback, uint32_t> cb); + void SetNeighboursCallback (Callback, uint32_t> cb); ///\name Proactive PREQ mechanism: ///\{ void SetRoot (); @@ -89,9 +89,9 @@ ///\name Interaction with HWMP MAC plugin //\{ - void ReceivePreq(IePreq preq, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric); - void ReceivePrep(IePrep prep, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric); - void ReceivePerr(std::vector, Mac48Address from, uint32_t interface, Mac48Address fromMp); + void ReceivePreq (IePreq preq, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric); + void ReceivePrep (IePrep prep, Mac48Address from, uint32_t interface, Mac48Address fromMp, uint32_t metric); + void ReceivePerr (std::vector, Mac48Address from, uint32_t interface, Mac48Address fromMp); void SendPrep ( Mac48Address src, Mac48Address dst, @@ -135,7 +135,7 @@ * \param uint32_t is the seqno * \param Mac48Address is the mesh source addrress of the frame */ - bool DropDataFrame(uint32_t, Mac48Address); + bool DropDataFrame (uint32_t, Mac48Address); //\} private: /// Packet waiting its routing information @@ -147,7 +147,7 @@ uint32_t inInterface; ///< incoming device interface ID. (if packet has come from upper layers, this is Mesh point ID) RouteReplyCallback reply; ///< how to reply - QueuedPacket () : pkt(0), protocol(0), inInterface(0) {} + QueuedPacket () : pkt (0), protocol (0), inInterface (0) {} }; ///\name Methods related to Queue/Dequeue procedures diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-rtable.cc --- a/src/devices/mesh/dot11s/hwmp-rtable.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-rtable.cc Wed Jul 22 15:56:55 2009 +0400 @@ -96,13 +96,15 @@ { bool should_add = true; for (unsigned int j = 0; j < i->second.precursors.size (); j++) - //NB: Only one active route may exist, so do not check - //interface ID, just address - if (i->second.precursors[j].second == precursorAddress) - { - should_add = false; - break; - } + { + //NB: Only one active route may exist, so do not check + //interface ID, just address + if (i->second.precursors[j].second == precursorAddress) + { + should_add = false; + break; + } + } if (should_add) { i->second.precursors.push_back (precursor); @@ -134,7 +136,9 @@ HwmpRtable::DeleteProactivePath (Mac48Address root) { if (m_root.root == root) - DeleteProactivePath (); + { + DeleteProactivePath (); + } } void HwmpRtable::DeleteReactivePath (Mac48Address destination) @@ -193,13 +197,15 @@ IePerr::FailedDestination dst; std::vector retval; for (std::map::iterator i = m_routes.begin (); i != m_routes.end (); i++) - if (i->second.retransmitter == peerAddress) - { - dst.destination = i->first; - i->second.seqnum++; - dst.seqnum = i->second.seqnum; - retval.push_back (dst); - } + { + if (i->second.retransmitter == peerAddress) + { + dst.destination = i->first; + i->second.seqnum++; + dst.seqnum = i->second.seqnum; + retval.push_back (dst); + } + } //Lookup a path to root if (m_root.retransmitter == peerAddress) { @@ -228,13 +234,17 @@ { bool should_add = true; for (unsigned int j = 0; j < retval.size (); j++) - if (retval[j].second == m_root.precursors[i].second) - { - should_add = false; - break; - } + { + if (retval[j].second == m_root.precursors[i].second) + { + should_add = false; + break; + } + } if (should_add) - retval.push_back (m_root.precursors[i]); + { + retval.push_back (m_root.precursors[i]); + } } } return retval; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/hwmp-rtable.h --- a/src/devices/mesh/dot11s/hwmp-rtable.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/hwmp-rtable.h Wed Jul 22 15:56:55 2009 +0400 @@ -51,11 +51,11 @@ uint32_t seqnum; Time lifetime; - LookupResult(Mac48Address r = Mac48Address::GetBroadcast (), + LookupResult (Mac48Address r = Mac48Address::GetBroadcast (), uint32_t i = INTERFACE_ANY, uint32_t m = MAX_METRIC, uint32_t s = 0, - Time l = Seconds(0.0)) + Time l = Seconds (0.0)) : retransmitter (r), ifIndex (i), metric (m), @@ -65,7 +65,7 @@ } /// True for valid route - bool IsValid() const; + bool IsValid () const; /// Compare route lookup results, used by tests bool operator==(const LookupResult & o) const; }; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-beacon-timing.cc --- a/src/devices/mesh/dot11s/ie-dot11s-beacon-timing.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-beacon-timing.cc Wed Jul 22 15:56:55 2009 +0400 @@ -147,7 +147,7 @@ uint8_t IeBeaconTiming::GetInformationSize () const { - return (5* m_numOfUnits ); + return (5 * m_numOfUnits ); } void IeBeaconTiming::PrintInformation (std::ostream& os) const diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-metric-report.cc --- a/src/devices/mesh/dot11s/ie-dot11s-metric-report.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-metric-report.cc Wed Jul 22 15:56:55 2009 +0400 @@ -41,7 +41,7 @@ uint8_t IeLinkMetricReport::GetInformationSize (void) const { - return sizeof(uint32_t); + return sizeof (uint32_t); } uint32_t IeLinkMetricReport::GetMetric () diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-peer-management.h --- a/src/devices/mesh/dot11s/ie-dot11s-peer-management.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-peer-management.h Wed Jul 22 15:56:55 2009 +0400 @@ -71,7 +71,7 @@ bool SubtypeIsOpen () const; bool SubtypeIsClose () const; bool SubtypeIsConfirm () const ; - uint8_t GetSubtype() const { return m_subtype;}; + uint8_t GetSubtype () const { return m_subtype;}; private: WifiElementId ElementId () const; uint8_t GetInformationSize (void) const; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-perr.cc --- a/src/devices/mesh/dot11s/ie-dot11s-perr.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-perr.cc Wed Jul 22 15:56:55 2009 +0400 @@ -71,7 +71,7 @@ Buffer::Iterator i = start; i.Next (1); //Mode flags is not used now uint8_t numOfDest = i.ReadU8 (); - NS_ASSERT ((2 + 10* numOfDest ) == length); + NS_ASSERT ((2 + 10 * numOfDest ) == length); length = 0; //to avoid compiler warning in optimized builds for (unsigned int j = 0; j < numOfDest; j++) { diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-preq.cc --- a/src/devices/mesh/dot11s/ie-dot11s-preq.cc Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-preq.cc Wed Jul 22 15:56:55 2009 +0400 @@ -49,7 +49,9 @@ { m_destSeqNumber = dest_seq_number; if (m_destSeqNumber != 0) - m_usn = true; + { + m_usn = true; + } } void DestinationAddressUnit::SetDestinationAddress (Mac48Address dest_address) @@ -332,7 +334,9 @@ os << " preq ID = " << m_preqId << "\n"; os << " Destinations are:\n"; for (int j = 0; j < m_destCount; j++) - os << " " << m_destinations[j]->GetDestinationAddress () << "\n"; + { + os << " " << m_destinations[j]->GetDestinationAddress () << "\n"; + } } std::vector > IePreq::GetDestinationList () diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/ie-dot11s-preq.h --- a/src/devices/mesh/dot11s/ie-dot11s-preq.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/ie-dot11s-preq.h Wed Jul 22 15:56:55 2009 +0400 @@ -118,7 +118,7 @@ * \brief Checks that preq's originator address equals to originator, and * this preq is not proactive */ - bool MayAddAddress(Mac48Address originator); + bool MayAddAddress (Mac48Address originator); bool IsFull () const; private: WifiElementId ElementId () const; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/peer-link-frame.h --- a/src/devices/mesh/dot11s/peer-link-frame.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/peer-link-frame.h Wed Jul 22 15:56:55 2009 +0400 @@ -60,8 +60,8 @@ }; ///\attention: must be set before deserialize, before only multihop //action header knows about subtype - void SetPlinkFrameSubtype(uint8_t subtype); - void SetPlinkFrameStart(PlinkFrameStartFields); + void SetPlinkFrameSubtype (uint8_t subtype); + void SetPlinkFrameStart (PlinkFrameStartFields); PlinkFrameStartFields GetFields (); /** \name Inherited from header: * \{ diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/peer-link.h --- a/src/devices/mesh/dot11s/peer-link.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/peer-link.h Wed Jul 22 15:56:55 2009 +0400 @@ -44,7 +44,7 @@ public: friend class PeerManagementProtocol; /// Support object system - static TypeId GetTypeId(); + static TypeId GetTypeId (); /// C-tor create empty link PeerLink (); ~PeerLink (); @@ -145,7 +145,7 @@ * Set pointer to MAC-plugin, which is responsible for sending peer * link management frames */ - void SetMacPlugin(Ptr plugin); + void SetMacPlugin (Ptr plugin); /// Peer link states, see 802.11s draft 11B.3.3.1 private: /// Peer link events, see 802.11s draft 11B.3.3.2 diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/peer-management-protocol-mac.h --- a/src/devices/mesh/dot11s/peer-management-protocol-mac.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/peer-management-protocol-mac.h Wed Jul 22 15:56:55 2009 +0400 @@ -68,11 +68,11 @@ ///functionallity ///\param first in retval is TBTT ///\param second in retval is beacon interval - std::pair GetBeaconInfo() const; - void SetBeaconShift(Time shift); + std::pair GetBeaconInfo () const; + void SetBeaconShift (Time shift); ///\} - void SetPeerManagerProtcol(Ptr protocol); - void SendPeerLinkManagementFrame( + void SetPeerManagerProtcol (Ptr protocol); + void SendPeerLinkManagementFrame ( Mac48Address peerAddress, Mac48Address peerMpAddress, uint16_t aid, @@ -90,9 +90,9 @@ ///\} ///\name Create peer link management frames: ///\{ - Ptr CreatePeerLinkOpenFrame(); - Ptr CreatePeerLinkConfirmFrame(); - Ptr CreatePeerLinkCloseFrame(); + Ptr CreatePeerLinkOpenFrame (); + Ptr CreatePeerLinkConfirmFrame (); + Ptr CreatePeerLinkCloseFrame (); ///This structure keeps all fields in peer link management frame, ///which are not subclasses of WifiInformationElement struct PlinkFrameStart { @@ -103,7 +103,7 @@ }; /// \name Parses the start of the frame, where there are no /// WifiInformationElements exist - PlinkFrameStart ParsePlinkFrame(Ptr packet); + PlinkFrameStart ParsePlinkFrame (Ptr packet); ///\} //Keeps statistics struct Statistics { diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/dot11s/peer-management-protocol.h --- a/src/devices/mesh/dot11s/peer-management-protocol.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/dot11s/peer-management-protocol.h Wed Jul 22 15:56:55 2009 +0400 @@ -61,7 +61,7 @@ * Also MP aggregates all installed protocols, PMP protocol can be accessed * via MeshPointDevice::GetObject(); */ - bool Install(Ptr); + bool Install (Ptr); /** * \brief Methods that handle beacon sending/receiving procedure. * @@ -75,7 +75,7 @@ * should be present in beacon * \param interface is a interface sending a beacon */ - Ptr GetBeaconTimingElement(uint32_t interface); + Ptr GetBeaconTimingElement (uint32_t interface); /** * \brief When we receive a beacon from peer-station, we remember * its beacon timing element (needed for peer choosing mechanism), @@ -84,7 +84,7 @@ * \param interface is a interface on which beacon was received * \param timingElement is a timing element of remote beacon */ - void UpdatePeerBeaconTiming( + void UpdatePeerBeaconTiming ( uint32_t interface, bool meshBeacon, IeBeaconTiming timingElement, @@ -113,7 +113,7 @@ * taken from the peer management frame * \param IePeerManagement is peer link management element */ - void ReceivePeerLinkFrame( + void ReceivePeerLinkFrame ( uint32_t interface, Mac48Address peerAddress, Mac48Address peerMeshPointAddress, @@ -132,15 +132,15 @@ bool IsActiveLink (uint32_t interface, Mac48Address peerAddress); //\} ///\brief Needed by external module to do MLME - Ptr FindPeerLink(uint32_t interface, Mac48Address peerAddress); + Ptr FindPeerLink (uint32_t interface, Mac48Address peerAddress); void SetPeerLinkStatusCallback (Callback cb); - std::vector GetActiveLinks(uint32_t interface); + std::vector GetActiveLinks (uint32_t interface); ///\brief needed by plugins to set global source address Mac48Address GetAddress (); ///\Needed to fill mesh configuration uint8_t GetNumberOfLinks (); void SetMeshId (std::string s); - Ptr GetMeshId() const; + Ptr GetMeshId () const; ///\brief: Report statistics void Report (std::ostream &) const; void ResetStats (); @@ -173,7 +173,7 @@ /** * Return a position in beacon-storage for a given remote station */ - void FillBeaconInfo(uint32_t interface, Mac48Address peerAddress, Time receivingTime, Time beaconInterval); + void FillBeaconInfo (uint32_t interface, Mac48Address peerAddress, Time receivingTime, Time beaconInterval); Ptr InitiateLink ( uint32_t interface, Mac48Address peerAddress, diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/flame/flame-rtable.h --- a/src/devices/mesh/flame/flame-rtable.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/flame/flame-rtable.h Wed Jul 22 15:56:55 2009 +0400 @@ -50,7 +50,7 @@ uint32_t ifIndex; uint8_t cost; uint16_t seqnum; - LookupResult(Mac48Address r = Mac48Address::GetBroadcast (), + LookupResult (Mac48Address r = Mac48Address::GetBroadcast (), uint32_t i = INTERFACE_ANY, uint8_t c = MAX_COST, uint16_t s = 0) @@ -61,7 +61,7 @@ { } /// True for valid route - bool IsValid() const; + bool IsValid () const; /// Compare route lookup results, used by tests bool operator==(const LookupResult & o) const; }; diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/mesh-point-device.h --- a/src/devices/mesh/mesh-point-device.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/mesh-point-device.h Wed Jul 22 15:56:55 2009 +0400 @@ -85,7 +85,7 @@ /// Register routing protocol to be used. Protocol must be alredy installed on this mesh point. void SetRoutingProtocol (Ptr protocol); /// Access current routing protocol - Ptr GetRoutingProtocol() const; + Ptr GetRoutingProtocol () const; //\} ///\name NetDevice interface for upper layers diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/mesh-wifi-interface-mac.h --- a/src/devices/mesh/mesh-wifi-interface-mac.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/mesh-wifi-interface-mac.h Wed Jul 22 15:56:55 2009 +0400 @@ -143,15 +143,15 @@ //\} /// To be used by plugins sending management frames. - void SendManagementFrame(Ptr frame, const WifiMacHeader& hdr); + void SendManagementFrame (Ptr frame, const WifiMacHeader& hdr); /// \return true if rates are supported - bool CheckSupportedRates(SupportedRates rates) const; + bool CheckSupportedRates (SupportedRates rates) const; /// \return list of supported bitrates SupportedRates GetSupportedRates () const; ///\ name Metric Calculation routines: ///\{ - void SetLinkMetricCallback(Callback > cb); - uint32_t GetLinkMetric(Mac48Address peerAddress); + void SetLinkMetricCallback (Callback > cb); + uint32_t GetLinkMetric (Mac48Address peerAddress); Ptr GetStationManager (); ///\} ///\brief Statistics: diff -r 5688b8da4526 -r b5062e8e0da1 src/devices/mesh/wifi-information-element.h --- a/src/devices/mesh/wifi-information-element.h Wed Jul 22 14:52:42 2009 +0400 +++ b/src/devices/mesh/wifi-information-element.h Wed Jul 22 15:56:55 2009 +0400 @@ -142,7 +142,7 @@ * This method takes a packet which must be a list of information * elements and looks for an information element of MINE Element ID */ - bool FindFirst(Ptr packet); + bool FindFirst (Ptr packet); //\} protected: @@ -189,7 +189,7 @@ NS_TEST_ASSERT_EQUAL (a, b); packet->AddHeader (a); IE c; - bool ok = c.FindFirst(packet); + bool ok = c.FindFirst (packet); NS_TEST_ASSERT (ok); NS_TEST_ASSERT_EQUAL (a, c);