Commit 4d83e8f2 authored by Marcin Siodelski's avatar Marcin Siodelski
Browse files

[3231] Added notes explaining why new DHCPv4 server methods are static.

parent 756857b0
...@@ -400,6 +400,7 @@ protected: ...@@ -400,6 +400,7 @@ protected:
/// the Server Identifier option as this option must be added using /// the Server Identifier option as this option must be added using
/// @c Dhcpv4Srv::appendServerID. /// @c Dhcpv4Srv::appendServerID.
/// ///
///
/// @param msg message object (options will be added to it) /// @param msg message object (options will be added to it)
/// @param msg_type specifies message type /// @param msg_type specifies message type
void appendDefaultOptions(Pkt4Ptr& msg, uint8_t msg_type); void appendDefaultOptions(Pkt4Ptr& msg, uint8_t msg_type);
...@@ -418,6 +419,9 @@ protected: ...@@ -418,6 +419,9 @@ protected:
/// check the specified message is that it is meant to be called internally /// check the specified message is that it is meant to be called internally
/// by the @c Dhcpv4Srv class. /// by the @c Dhcpv4Srv class.
/// ///
/// @note This method is static because it is not dependent on the class
/// state.
///
/// @param [out] response DHCPv4 message to which the server identifier /// @param [out] response DHCPv4 message to which the server identifier
/// option should be added. /// option should be added.
static void appendServerID(const Pkt4Ptr& response); static void appendServerID(const Pkt4Ptr& response);
...@@ -449,6 +453,9 @@ protected: ...@@ -449,6 +453,9 @@ protected:
/// the interface being used to send the response. This function uses /// the interface being used to send the response. This function uses
/// @c IfaceMgr to get the socket bound to the IPv4 address on the /// @c IfaceMgr to get the socket bound to the IPv4 address on the
/// particular interface. /// particular interface.
///
/// @note This method is static because it is not dependent on the class
/// state.
static void adjustIfaceData(const Pkt4Ptr& query, const Pkt4Ptr& response); static void adjustIfaceData(const Pkt4Ptr& query, const Pkt4Ptr& response);
/// @brief Sets remote addresses for outgoing packet. /// @brief Sets remote addresses for outgoing packet.
...@@ -464,9 +471,14 @@ protected: ...@@ -464,9 +471,14 @@ protected:
/// are valid. Make sure that pointers are correct before calling this /// are valid. Make sure that pointers are correct before calling this
/// function. /// function.
/// ///
/// @note This method is static because it is not dependent on the class
/// state.
///
/// @param question instance of a packet received by a server. /// @param question instance of a packet received by a server.
/// @param [out] response response packet which addresses are to be adjusted. /// @param [out] response response packet which addresses are to be
static void adjustRemoteAddr(const Pkt4Ptr& question, const Pkt4Ptr& response); /// adjusted.
static void adjustRemoteAddr(const Pkt4Ptr& question,
const Pkt4Ptr& response);
/// @brief converts server-id to text /// @brief converts server-id to text
/// Converts content of server-id option to a text representation, e.g. /// Converts content of server-id option to a text representation, e.g.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment