NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.3: NDN, CCN, CCNx, content centric networks
API Documentation
string-helper.hpp File Reference
#include "../common.hpp"
#include "../encoding/buffer.hpp"
Include dependency graph for string-helper.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  ndn::StringHelperError
 

Namespaces

 ndn
 Copyright (c) 2011-2015 Regents of the University of California.
 

Functions

void ndn::printHex (std::ostream &os, const uint8_t *buffer, size_t length, bool isUpperCase=true)
 Output the hex representation of the bytes in array to the output stream os. More...
 
void ndn::printHex (std::ostream &os, const Buffer &buffer, bool isUpperCase=true)
 Output the hex representation of the bytes in the buffer to the output stream os. More...
 
std::string ndn::toHex (const uint8_t *buffer, size_t length, bool isUpperCase=true)
 Return the hex representation of the bytes in array. More...
 
std::string ndn::toHex (const Buffer &buffer, bool isUpperCase=true)
 Return the hex representation of the bytes in the buffer to the output stream os. More...
 
shared_ptr< const Buffer > ndn::fromHex (const std::string &hexString)
 Convert the hex string to buffer. More...
 
void ndn::trimLeft (std::string &str)
 Modify str in place to erase whitespace on the left. More...
 
void ndn::trimRight (std::string &str)
 Modify str in place to erase whitespace on the right. More...
 
void ndn::trim (std::string &str)
 Modify str in place to erase whitespace on the left and right. More...
 
int ndn::fromHexChar (uint8_t c)
 Convert the hex character to an integer from 0 to 15, or -1 if not a hex character. More...
 
std::string ndn::unescape (const std::string &str)
 Decode a percent-encoded string. More...