branch with improvemnts

Fork of M2XStreamClient by AT&T M2X Team

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers NullPrint.h Source File

NullPrint.h

00001 #ifndef NullPrint_h
00002 #define NullPrint_h
00003 
00004 #include "Print.h"
00005 
00006 // Null Print class used to calculate length to print
00007 class NullPrint : public Print {
00008 public:
00009   virtual size_t write(uint8_t b) {
00010     return 1;
00011   }
00012 
00013   virtual size_t write(const uint8_t* buf, size_t size) {
00014     return size;
00015   }
00016 };
00017 
00018 #endif  /* NullPrint_h */