An abstract engine to transform a sequences of bytes in a specific charset into a LogString.
More...
#include <charsetdecoder.h>
|
static CharsetDecoderPtr | getDefaultDecoder () |
| Get decoder for default charset.
|
|
static CharsetDecoderPtr | getDecoder (const LogString &charset) |
| Get decoder for specified character set.
|
|
static CharsetDecoderPtr | getUTF8Decoder () |
| Get decoder for UTF-8.
|
|
static CharsetDecoderPtr | getISOLatinDecoder () |
| Get decoder for ISO-8859-1.
|
|
static bool | isError (log4cxx_status_t stat) |
| Determins if status value indicates an invalid byte sequence.
|
|
An abstract engine to transform a sequences of bytes in a specific charset into a LogString.
◆ CharsetDecoder()
log4cxx::helpers::CharsetDecoder::CharsetDecoder |
( |
| ) |
|
|
protected |
◆ ~CharsetDecoder()
virtual log4cxx::helpers::CharsetDecoder::~CharsetDecoder |
( |
| ) |
|
|
virtual |
◆ decode()
virtual log4cxx_status_t log4cxx::helpers::CharsetDecoder::decode |
( |
ByteBuffer & |
in, |
|
|
LogString & |
out |
|
) |
| |
|
pure virtual |
Decodes as many bytes as possible from the given input buffer, writing the results to the given output string.
- Parameters
-
in | input buffer. |
out | output string. |
- Returns
- APR_SUCCESS if not encoding errors were found.
◆ getDecoder()
static CharsetDecoderPtr log4cxx::helpers::CharsetDecoder::getDecoder |
( |
const LogString & |
charset | ) |
|
|
static |
Get decoder for specified character set.
- Parameters
-
charset | the following values should be recognized: "US-ASCII", "ISO-8859-1", "UTF-8", "UTF-16BE", "UTF-16LE". |
- Returns
- decoder
- Exceptions
-
◆ getDefaultDecoder()
static CharsetDecoderPtr log4cxx::helpers::CharsetDecoder::getDefaultDecoder |
( |
| ) |
|
|
static |
Get decoder for default charset.
◆ getISOLatinDecoder()
static CharsetDecoderPtr log4cxx::helpers::CharsetDecoder::getISOLatinDecoder |
( |
| ) |
|
|
static |
Get decoder for ISO-8859-1.
◆ getUTF8Decoder()
static CharsetDecoderPtr log4cxx::helpers::CharsetDecoder::getUTF8Decoder |
( |
| ) |
|
|
static |
◆ isError()
static bool log4cxx::helpers::CharsetDecoder::isError |
( |
log4cxx_status_t |
stat | ) |
|
|
inlinestatic |
Determins if status value indicates an invalid byte sequence.
The documentation for this class was generated from the following file: