Text and encoding related functions.
More...
#include <text.h>
|
void | replaceAll (string &, const string &, const string &) |
| Replace all characters from a string. More...
|
|
void | create (int, string, string, string) |
| Set the Text object parameters. More...
|
|
string | print (int) |
| Print a human friendly Text object. More...
|
|
string | encodeB26 (unsigned char *, long) |
| Returns the text encoded in Base26. More...
|
|
void | decodeB26 (unsigned char *, string) |
| Returns the text decoded in Base26. More...
|
|
void | parse (string) |
| Parse and set the Text object with a formatted (headed) message. More...
|
|
Text and encoding related functions.
void Text::create |
( |
int |
page, |
|
|
string |
book, |
|
|
string |
from, |
|
|
string |
msg |
|
) |
| |
Set the Text object parameters.
- Parameters
-
page | Page num |
book | Book ID |
from | A sender id for identification |
msg | The cleartext message |
void Text::decodeB26 |
( |
unsigned char * |
output, |
|
|
string |
text |
|
) |
| |
Returns the text decoded in Base26.
- Parameters
-
output | Text decoded |
text | Encoded text |
string Text::encodeB26 |
( |
unsigned char * |
text, |
|
|
long |
len |
|
) |
| |
Returns the text encoded in Base26.
- Parameters
-
- Returns
- Encoded text (string)
void Text::parse |
( |
string |
text | ) |
|
Parse and set the Text object with a formatted (headed) message.
- Parameters
-
text | The formatted message string |
string Text::print |
( |
int |
spa | ) |
|
Print a human friendly Text object.
- Parameters
-
- Returns
- sout.str()
void Text::replaceAll |
( |
string & |
, |
|
|
const string & |
, |
|
|
const string & |
|
|
) |
| |
Replace all characters from a string.
replaceAll( str, from, to )
- Parameters
-
str | The string pointer |
from | Character to be replaced |
to | Replace character |
Sender identificative string (3 letters, for example: AVD)
The documentation for this class was generated from the following files: