sixlowpan: fix doxygen warnings

This commit is contained in:
Tommaso Pecorella
2021-05-01 04:36:19 +02:00
parent 21fb224e8a
commit 6b0a9f4af7
3 changed files with 41 additions and 16 deletions

View File

@@ -87,8 +87,8 @@ public:
* The context is used only in IPHC compression and decompression.
*
* \param [in] c The NetDevice container.
* \param [in] id The context id (must be less than 16).
* \param [in] prefix The context prefix.
* \param [in] contextId The context id (must be less than 16).
* \param [in] context The context prefix.
* \param [in] validity the context validity time (relative to the actual time).
*/
void AddContext (NetDeviceContainer c, uint8_t contextId, Ipv6Prefix context, Time validity);
@@ -99,7 +99,7 @@ public:
* The context will have its lifetime extended and its validity for compression re-enabled.
*
* \param [in] c The NetDevice container.
* \param [in] id The context id (must be less than 16).
* \param [in] contextId The context id (must be less than 16).
* \param [in] validity the context validity time (relative to the actual time).
*/
void RenewContext (NetDeviceContainer c, uint8_t contextId, Time validity);
@@ -114,7 +114,7 @@ public:
* can not be used for decompression whie packets are traveling the network.
*
* \param [in] c The NetDevice container.
* \param [in] id The context id (must be less than 16).
* \param [in] contextId The context id (must be less than 16).
*/
void InvalidateContext (NetDeviceContainer c, uint8_t contextId);
@@ -124,7 +124,7 @@ public:
* The context is removed immediately from the contexts in the devices.
*
* \param [in] c The NetDevice container.
* \param [in] id The context id (must be less than 16).
* \param [in] contextId The context id (must be less than 16).
*/
void RemoveContext (NetDeviceContainer c, uint8_t contextId);

View File

@@ -255,7 +255,6 @@ private:
* \param [in] source The source address.
* \param [in] destination The destination address.
* \param [in] packetType The packet kind (e.g., HOST, BROADCAST, etc.).
* \return The IPv6 link-local address.
*/
void ReceiveFromDevice (Ptr<NetDevice> device, Ptr<const Packet> packet, uint16_t protocol,
Address const &source, Address const &destination, PacketType packetType);
@@ -621,7 +620,7 @@ private:
* \brief Finds if the given unicast address matches a context for compression
*
* \param[in] address the address to check
* \param[out] the context found
* \param[out] contextId the context found
* \return true if a valid context has been found
*/
bool FindUnicastCompressionContext (Ipv6Address address, uint8_t& contextId);
@@ -630,7 +629,7 @@ private:
* \brief Finds if the given multicast address matches a context for compression
*
* \param[in] address the address to check
* \param[out] the context found
* \param[out] contextId the context found
* \return true if a valid context has been found
*/
bool FindMulticastCompressionContext (Ipv6Address address, uint8_t& contextId);
@@ -642,7 +641,7 @@ private:
* Only the pefix length is used - the address prefix is assumed to be matching the prefix.
*
* \param address the address to be cleaned
* \param the prefix to remove
* \param prefix the prefix to remove
* \return An address with the prefix zeroed.
*/
Ipv6Address CleanPrefix (Ipv6Address address, Ipv6Prefix prefix);

View File

@@ -70,13 +70,39 @@ class SixlowpanIphcStatefulImplTest : public TestCase
std::vector<Data> m_txPackets; //!< Transmitted packets
std::vector<Data> m_rxPackets; //!< Received packets
/**
* Receive from a MockDevice.
* \param device a pointer to the net device which is calling this function
* \param packet the packet received
* \param protocol the 16 bit protocol number associated with this packet.
* \param source the address of the sender
* \param destination the address of the receiver
* \param packetType type of packet received (broadcast/multicast/unicast/otherhost)
* \returns true.
*/
bool ReceiveFromMockDevice (Ptr<NetDevice> device, Ptr<const Packet> packet, uint16_t protocol,
Address const &source, Address const &destination, NetDevice::PacketType packetType);
/**
* Promiscuous receive from a SixLowPanNetDevice.
* \param device a pointer to the net device which is calling this function
* \param packet the packet received
* \param protocol the 16 bit protocol number associated with this packet.
* \param source the address of the sender
* \param destination the address of the receiver
* \param packetType type of packet received (broadcast/multicast/unicast/otherhost)
* \returns true.
*/
bool PromiscReceiveFromSixLowPanDevice (Ptr<NetDevice> device, Ptr<const Packet> packet, uint16_t protocol,
Address const &source, Address const &destination, NetDevice::PacketType packetType);
void SendOnePacket (NetDeviceContainer devices, Ipv6Address from, Ipv6Address to);
/**
* Send one packet.
* \param device the device to send from
* \param from sender address
* \param to destination address
*/
void SendOnePacket (Ptr<NetDevice> device, Ipv6Address from, Ipv6Address to);
NetDeviceContainer m_mockDevices; //!< MockNetDevice container
NetDeviceContainer m_sixDevices; //!< SixLowPanNetDevice container
@@ -124,7 +150,7 @@ SixlowpanIphcStatefulImplTest::PromiscReceiveFromSixLowPanDevice (Ptr<NetDevice>
}
void
SixlowpanIphcStatefulImplTest::SendOnePacket (NetDeviceContainer devices, Ipv6Address from, Ipv6Address to)
SixlowpanIphcStatefulImplTest::SendOnePacket (Ptr<NetDevice> device, Ipv6Address from, Ipv6Address to)
{
Ptr<Packet> pkt = Create<Packet> (10);
Ipv6Header ipHdr;
@@ -135,7 +161,7 @@ SixlowpanIphcStatefulImplTest::SendOnePacket (NetDeviceContainer devices, Ipv6Ad
ipHdr.SetNextHeader (0xff);
pkt->AddHeader (ipHdr);
devices.Get (0)->Send (pkt, Mac48Address ("00:00:00:00:00:02"), 0);
device->Send (pkt, Mac48Address ("00:00:00:00:00:02"), 0);
}
void
@@ -196,19 +222,19 @@ SixlowpanIphcStatefulImplTest::DoRun (void)
Ipv6Address srcElided = deviceInterfaces.GetAddress (0, 1);
Ipv6Address dstElided = Ipv6Address::MakeAutoconfiguredAddress (Mac48Address ("00:00:00:00:00:02"), Ipv6Prefix ("2001:2::", 64));
Simulator::Schedule (Seconds (1), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices,
Simulator::Schedule (Seconds (1), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices.Get (0),
Ipv6Address::GetAny (),
dstElided);
Simulator::Schedule (Seconds (2), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices,
Simulator::Schedule (Seconds (2), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices.Get (0),
Ipv6Address ("2001:2::f00d:f00d:cafe:cafe"),
Ipv6Address ("2001:1::0000:00ff:fe00:cafe"));
Simulator::Schedule (Seconds (3), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices,
Simulator::Schedule (Seconds (3), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices.Get (0),
Ipv6Address ("2001:1::0000:00ff:fe00:cafe"),
Ipv6Address ("2001:1::f00d:f00d:cafe:cafe"));
Simulator::Schedule (Seconds (4), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices,
Simulator::Schedule (Seconds (4), &SixlowpanIphcStatefulImplTest::SendOnePacket, this, m_sixDevices.Get (0),
srcElided,
Ipv6Address ("2001:1::f00d:f00d:cafe:cafe"));