trunk/branch integration: optimalization

This commit is contained in:
Marian Krivos
2011-08-23 06:38:04 +00:00
parent a74e3c6be7
commit 22575c3a90
4 changed files with 156 additions and 71 deletions

View File

@@ -49,24 +49,30 @@ namespace Poco {
class Foundation_API Base64DecoderBuf: public UnbufferedStreamBuf
/// This streambuf base64-decodes all data read
/// from the istream connected to it.
/// This streambuf base64-decodes all data read
/// from the istream connected to it.
///
/// Note: For performance reasons, the characters
/// are read directly from the given istream's
/// underlying streambuf, so the state
/// of the istream will not reflect that of
/// its streambuf.
{
public:
Base64DecoderBuf(std::istream& istr);
Base64DecoderBuf(std::istream& istr);
~Base64DecoderBuf();
private:
int readFromDevice();
int readOne();
unsigned char _group[3];
int _groupLength;
int _groupIndex;
std::istream& _istr;
static unsigned char IN_ENCODING[256];
static bool IN_ENCODING_INIT;
unsigned char _group[3];
int _groupLength;
int _groupIndex;
std::streambuf& _buf;
static unsigned char IN_ENCODING[256];
static bool IN_ENCODING_INIT;
private:
Base64DecoderBuf(const Base64DecoderBuf&);
@@ -95,11 +101,17 @@ private:
class Foundation_API Base64Decoder: public Base64DecoderIOS, public std::istream
/// This istream base64-decodes all data
/// read from the istream connected to it.
/// This istream base64-decodes all data
/// read from the istream connected to it.
///
/// Note: For performance reasons, the characters
/// are read directly from the given istream's
/// underlying streambuf, so the state
/// of the istream will not reflect that of
/// its streambuf.
{
public:
Base64Decoder(std::istream& istr);
Base64Decoder(std::istream& istr);
~Base64Decoder();
private: