28 #ifndef _ID3LIB_WRITERS_H_
29 #define _ID3LIB_WRITERS_H_
33 #include "id3/id3lib_streams.h"
46 virtual void flush() { _stream.flush(); }
59 _stream.write(buf, len);
64 _stream.write(reinterpret_cast<const char*>(buf), len);
96 virtual void flush() { _stream.flush(); }
109 _stream.write(buf, len);
114 _stream.write(reinterpret_cast<const char*>(buf), len);
118 virtual pos_type
getBeg() {
return _beg; }
119 virtual pos_type
getCur() {
return _stream.tellp(); }
137 const char_type* _beg;
139 const char_type* _end;
141 void setBuffer(char_type* buf,
size_t size)
150 this->setBuffer(
NULL, 0);
154 this->setBuffer(buf, size);
165 return this->
writeChars(reinterpret_cast<const char_type *>(buf), len);
170 size_type size = (remaining > len) ? len : remaining;
171 ::memcpy(_cur, buf, size);