本文整理汇总了C++中Packet::GetNullTerminated方法的典型用法代码示例。如果您正苦于以下问题:C++ Packet::GetNullTerminated方法的具体用法?C++ Packet::GetNullTerminated怎么用?C++ Packet::GetNullTerminated使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Packet
的用法示例。
在下文中一共展示了Packet::GetNullTerminated方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SetInternalIP
/**
* @brief Changes the internal IP of the port map.
*
* @param internalIP New internal IP.
* @param portMapID Ignored.
*/
void UpnpNatPortMapAction::SetInternalIP(const Packet & internalIP, size_t portMapID)
{
ComString comInternalIP(internalIP.GetNullTerminated());
HRESULT hResult = ptrPortMap->EditInternalClient(comInternalIP.GetBSTR());
_ErrorException((hResult != S_OK), "setting the internal IP of a port map", hResult, __LINE__,__FILE__);
this->internalIP = internalIP;
}
示例2: SetDescription
/**
* @brief Changes the description of the port map.
*
* @param description New Description. Must be NULL terminated.
* @param portMapID Ignored.
*/
void UpnpNatPortMapAction::SetDescription(const Packet & description, size_t portMapID)
{
ComString comDescription(description.GetNullTerminated());
HRESULT hResult = ptrPortMap->EditDescription(comDescription.GetBSTR());
_ErrorException((hResult != S_OK), "setting the description of a port map", hResult, __LINE__,__FILE__);
this->description = description;
}