NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.5: NDN, CCN, CCNx, content centric networks
API Documentation
ndn::detail::cfstring Namespace Reference

Functions

CFReleaser< CFStringRef > fromBuffer (const uint8_t *buf, size_t buflen)
 Create a CFString by copying bytes from a raw buffer. More...
 
CFReleaser< CFStringRef > fromStdString (const std::string &str)
 Create a CFString by copying characters from a std::string. More...
 
std::string toStdString (CFStringRef cfStr)
 Convert a CFString to a std::string. More...
 

Function Documentation

◆ fromBuffer()

CFReleaser< CFStringRef > ndn::detail::cfstring::fromBuffer ( const uint8_t *  buf,
size_t  buflen 
)

Create a CFString by copying bytes from a raw buffer.

Exceptions
std::runtime_errorcreation failed

Definition at line 29 of file cf-string-osx.cpp.

References buf, and NDN_THROW.

Referenced by ndn::security::tpm::exportItem().

◆ fromStdString()

CFReleaser< CFStringRef > ndn::detail::cfstring::fromStdString ( const std::string &  str)

Create a CFString by copying characters from a std::string.

Exceptions
std::runtime_errorcreation failed

Definition at line 39 of file cf-string-osx.cpp.

References NDN_THROW.

Referenced by ndn::security::tpm::getKeyRef().

◆ toStdString()

std::string ndn::detail::cfstring::toStdString ( CFStringRef  cfStr)

Convert a CFString to a std::string.

Exceptions
std::runtime_errorconversion failed

Definition at line 49 of file cf-string-osx.cpp.

References NDN_THROW.

Referenced by ndn::security::tpm::getErrorMessage(), and ndn::security::tpm::getFailureReason().