#ifndef INCLUDED_BOBCAT_IBASE64BUF_
#define INCLUDED_BOBCAT_IBASE64BUF_

#include <bobcat/base64bufbase>
#include <bobcat/fbb>

namespace FBB
{

template <CryptType>
class IBase64Buf;

template <>
class IBase64Buf<ENCRYPT>: public IUO::Base64BufBase
{
    public:
        IBase64Buf(std::istream &in, size_t bufSize = 1000);  // 1.f
};

template <>
class IBase64Buf<DECRYPT>: public IUO::Base64BufBase
{
    public:
        IBase64Buf(std::istream &in, size_t bufSize = 1000);  // 2.f
};

inline
IBase64Buf<ENCRYPT>::IBase64Buf(std::istream &in, size_t bufSize)
:
    Base64BufBase(in, bufSize)
{
    doEncrypt();
}
inline
IBase64Buf<DECRYPT>::IBase64Buf(std::istream &in, size_t bufSize)
:
    Base64BufBase(in, bufSize)
{
    doDecrypt();
}

} // FBB
#endif
