esp8266ndn
NDN Arduino library for ESP8266 and more
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
logging.hpp
Go to the documentation of this file.
1 #ifndef ESP8266NDN_LOGGING_HPP
2 #define ESP8266NDN_LOGGING_HPP
3 
4 #include <Print.h>
5 
6 namespace esp8266ndn {
7 
8 Print&
10 
11 void
13 
15 class PrintHex : public Printable {
16 public:
17  explicit PrintHex(const uint8_t* buf, size_t len);
18 
19  size_t printTo(Print& p) const override;
20 
21 private:
22  const uint8_t* m_buf;
23  size_t m_len;
24 };
25 
26 } // namespace esp8266ndn
27 
28 #endif // ESP8266NDN_LOGGING_HPP
Print a buffer in hexadecimal.
Definition: logging.hpp:15
size_t printTo(Print &p) const override
PrintHex(const uint8_t *buf, size_t len)
Definition: autoconfig.hpp:24
Print & getLogOutput()
void setLogOutput(Print &output)
void output(const Encodable &packet, std::ostream &os=std::cout)
Write an Encodable to output stream.
Definition: io.hpp:33