20 #include "Device_IP_Diagnostics_IPPing.h"
21 #include "hostIf_utils.h"
25 const char* hostIf_IP_Diagnostics_IPPing::PROFILE_NAME =
"Device.IP.Diagnostics.IPPing.";
27 hostIf_IP_Diagnostics_IPPing::hostIf_IP_Diagnostics_IPPing ()
30 filename.append (
"/opt/tr-181/").append (PROFILE_NAME).append (
"dat");
33 if (!store.load (filename))
35 std::ofstream output_stream (filename.c_str());
50 std::string ipping_parameter_name (stMsgData->
paramName + strlen (PROFILE_NAME));
52 if (ipping_parameter_name.compare (
"Host") &&
53 ipping_parameter_name.compare (
"NumberOfRepetitions") &&
54 ipping_parameter_name.compare (
"DataBlockSize"))
56 RDK_LOG (RDK_LOG_ERROR, LOG_TR69HOSTIF,
"[%s] Unsupported parameter '%s'\n", __FUNCTION__, stMsgData->
paramName);
57 stMsgData->
faultCode = fcInvalidParameterName;
61 std::string value = store.value (stMsgData->
paramName,
"");
64 stMsgData->
paramLen = value.length ();
78 std::string ipping_parameter_name (stMsgData->
paramName + strlen (PROFILE_NAME));
80 if (ipping_parameter_name.compare (
"Host") &&
81 ipping_parameter_name.compare (
"NumberOfRepetitions") &&
82 ipping_parameter_name.compare (
"DataBlockSize"))
84 RDK_LOG (RDK_LOG_ERROR, LOG_TR69HOSTIF,
"[%s] Unsupported parameter '%s'\n", __FUNCTION__, stMsgData->
paramName);
85 stMsgData->
faultCode = fcInvalidParameterName;