Rudiments: /home/dmuse/temp/rudiments/include/rudiments/wstringbuffer.h Source File

Rudiments

wstringbuffer.h
1 // Copyright (c) 1999-2018 David Muse
2 // See the COPYING file for more information.
3
4 #ifndef RUDIMENTS_WSTRINGBUFFER_H
5 #define RUDIMENTS_WSTRINGBUFFER_H
6
7 #include <rudiments/private/wstringbufferincludes.h>
8
14 class RUDIMENTS_DLLSPEC wstringbuffer : public bytebuffer {
15 public:
16
19 wstringbuffer();
20
23 wstringbuffer(size_t initialsize);
24
30 wstringbuffer(wchar_t *initialcontents, size_t initialsize);
31
34 wstringbuffer(const wstringbuffer &s);
35
38 wstringbuffer &operator=(const wstringbuffer &s);
39
41 ~wstringbuffer();
42
48 void setPosition(size_t pos);
49
52 size_t getPosition();
53
61 ssize_t write(const wchar_t *string);
62
71 ssize_t write(const wchar_t *string, size_t length);
72
80 ssize_t write(wchar_t character);
81
90 ssize_t write(int16_t number);
91
100 ssize_t write(int32_t number);
101
110 ssize_t write(int64_t number);
111
120 ssize_t write(uint16_t number);
121
130 ssize_t write(uint32_t number);
131
140 ssize_t write(uint64_t number);
141
150 ssize_t write(float number);
151
160 ssize_t write(float number, uint16_t scale);
161
171 ssize_t write(float number, uint16_t precision,
172 uint16_t scale);
173
182 ssize_t write(double number);
183
192 ssize_t write(double number, uint16_t scale);
193
203 ssize_t write(double number, uint16_t precision,
204 uint16_t scale);
205
206
212 wstringbuffer *append(const wchar_t *string);
213
220 wstringbuffer *append(const wchar_t *string, size_t length);
221
227 wstringbuffer *append(wchar_t character);
228
235 wstringbuffer *append(int16_t number);
236
243 wstringbuffer *append(int32_t number);
244
251 wstringbuffer *append(int64_t number);
252
259 wstringbuffer *append(uint16_t number);
260
267 wstringbuffer *append(uint32_t number);
268
275 wstringbuffer *append(uint64_t number);
276
283 wstringbuffer *append(int16_t number, uint16_t zeropadding);
284
291 wstringbuffer *append(int32_t number, uint16_t zeropadding);
292
299 wstringbuffer *append(int64_t number, uint16_t zeropadding);
300
307 wstringbuffer *append(uint16_t number, uint16_t zeropadding);
308
315 wstringbuffer *append(uint32_t number, uint16_t zeropadding);
316
323 wstringbuffer *append(uint64_t number, uint16_t zeropadding);
324
331 wstringbuffer *append(float number);
332
339 wstringbuffer *append(float number, uint16_t scale);
340
348 wstringbuffer *append(float number, uint16_t precision,
349 uint16_t scale);
350
357 wstringbuffer *append(double number);
358
365 wstringbuffer *append(double number, uint16_t scale);
366
374 wstringbuffer *append(double number, uint16_t precision,
375 uint16_t scale);
376
378 void truncate(size_t pos);
379
381 void truncate();
382
384 void clear();
385
388 void clear(size_t initialsize);
389
394 void clear(wchar_t *initialcontents, size_t initialsize);
395
397 const wchar_t *getString();
398
405 wchar_t *detachString();
406
409 size_t getStringLength();
410 };
411
412 #include <rudiments/private/wstringbufferinlines.h>
413
414 #endif
bytebuffer
Definition: bytebuffer.h:13
bytebuffer::append
bytebuffer * append(const unsigned char *data, size_t size)
bytebuffer::setPosition
void setPosition(size_t pos)
bytebuffer::clear
void clear()
bytebuffer::truncate
virtual void truncate()
bytebuffer::write
ssize_t write(const unsigned char *data, size_t size)
bytebuffer::operator=
bytebuffer & operator=(const bytebuffer &v)
bytebuffer::getPosition
size_t getPosition()
character
Definition: character.h:11
wstringbuffer
Definition: wstringbuffer.h:14