#include "core/fxcrt/cfx_seekablestreamproxy.h"
#include <stdint.h>
#include <algorithm>
#include <limits>
#include <utility>
#include "build/build_config.h"
#include "core/fxcrt/check.h"
#include "core/fxcrt/check_op.h"
#include "core/fxcrt/data_vector.h"
#include "core/fxcrt/fx_extension.h"
#include "core/fxcrt/fx_safe_types.h"
#include "core/fxcrt/span.h"
#include "core/fxcrt/span_util.h"
namespace {
std::pair<size_t, size_t> UTF8Decode(pdfium::span<const uint8_t> pSrc,
pdfium::span<wchar_t> pDst) { … }
void UTF16ToWChar(pdfium::span<wchar_t> buffer) { … }
void SwapByteOrder(pdfium::span<uint16_t> str) { … }
}
#define BOM_UTF8_MASK …
#define BOM_UTF8 …
#define BOM_UTF16_MASK …
#define BOM_UTF16_BE …
#define BOM_UTF16_LE …
CFX_SeekableStreamProxy::CFX_SeekableStreamProxy(
const RetainPtr<IFX_SeekableReadStream>& stream)
: … { … }
CFX_SeekableStreamProxy::~CFX_SeekableStreamProxy() = default;
FX_FILESIZE CFX_SeekableStreamProxy::GetSize() const { … }
FX_FILESIZE CFX_SeekableStreamProxy::GetPosition() const { … }
bool CFX_SeekableStreamProxy::IsEOF() const { … }
void CFX_SeekableStreamProxy::Seek(From eSeek, FX_FILESIZE iOffset) { … }
void CFX_SeekableStreamProxy::SetCodePage(FX_CodePage wCodePage) { … }
size_t CFX_SeekableStreamProxy::ReadData(pdfium::span<uint8_t> buffer) { … }
size_t CFX_SeekableStreamProxy::ReadBlock(pdfium::span<wchar_t> buffer) { … }