| // Copyright 2018 PDFium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| #ifndef CORE_FXCRT_CFX_UTF8ENCODER_H_ |
| #define CORE_FXCRT_CFX_UTF8ENCODER_H_ |
| #include "core/fxcrt/bytestring.h" |
| #include "core/fxcrt/fx_memory_wrappers.h" |
| void Input(wchar_t unicodeAsWchar); |
| // The data returned by GetResult() is invalidated when this is modified by |
| ByteStringView GetResult() const { |
| return ByteStringView(m_Buffer.data(), m_Buffer.size()); |
| std::vector<uint8_t, FxAllocAllocator<uint8_t>> m_Buffer; |
| #endif // CORE_FXCRT_CFX_UTF8ENCODER_H_ |