msgid ""
msgstr ""
"Project-Id-Version: Chinese (Simplified Han script) (Boost Beast Translation "
"(zh_Hans))\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-06-06 20:30+0000\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Chinese (Simplified Han script) <https://"
"insights.cppalliance.org/weblate/projects/boost-beast-documentation-zh_Hans/"
"doc-qbk-04-http-06-serializer-buffers-qbk/zh_Hans/>\n"
"Language: zh_Hans\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Weblate 2026.5\n"

#. type: section title
#: 10
#, fuzzy
msgid "Buffer-Oriented Serializing"
msgstr "Buffer-Oriented Serializing"

#. type: paragraph
#: 13
#, fuzzy
msgid ""
"An instance of __serializer__ can be invoked directly, without using the "
"provided stream operations. This could be useful for implementing algorithms "
"on objects whose interface does not conform to __Stream__. For example, a "
"[@https://github.com/libuv/libuv *libuv* socket]. The serializer interface "
"is interactive; the caller invokes it repeatedly to produce buffers until "
"all of the serialized octets have been generated. Then the serializer is "
"destroyed."
msgstr ""
"An instance of __serializer__ can be invoked directly, without using the "
"provided stream operations. This could be useful for implementing algorithms "
"on objects whose interface does not conform to __Stream__. For example, a "
"[@https://github.com/libuv/libuv *libuv* socket]. The serializer interface "
"is interactive; the caller invokes it repeatedly to produce buffers until "
"all of the serialized octets have been generated. Then the serializer is "
"destroyed."

#. type: paragraph
#: 22
#, fuzzy
msgid ""
"To obtain the serialized next buffer sequence, call [link "
"beast.ref.boost__beast__http__serializer.next `serializer::next`]. Then, "
"call [link beast.ref.boost__beast__http__serializer.consume "
"`serializer::consume`] to indicate the number of bytes consumed. This "
"updates the next set of buffers to be returned, if any. `serializer::next` "
"takes an error code parameter and invokes a visitor argument with the error "
"code and buffer of unspecified type. In C++14 this is easily expressed with "
"a generic lambda. The function [link "
"beast.ref.boost__beast__http__serializer.is_done `serializer::is_done`] will "
"return `true` when all the buffers have been produced. This C++14 example "
"prints the buffers to standard output:"
msgstr ""
"To obtain the serialized next buffer sequence, call [link "
"beast.ref.boost__beast__http__serializer.next `serializer::next`]. Then, "
"call [link beast.ref.boost__beast__http__serializer.consume "
"`serializer::consume`] to indicate the number of bytes consumed. This "
"updates the next set of buffers to be returned, if any. `serializer::next` "
"takes an error code parameter and invokes a visitor argument with the error "
"code and buffer of unspecified type. In C++14 this is easily expressed with "
"a generic lambda. The function [link "
"beast.ref.boost__beast__http__serializer.is_done `serializer::is_done`] will "
"return `true` when all the buffers have been produced. This C++14 example "
"prints the buffers to standard output:"

#. type: paragraph
#: 37
#, fuzzy
msgid ""
"Generic lambda expressions are only available in C++14 or later. A functor "
"with a templated function call operator is necessary to use C++11 as shown:"
msgstr ""
"Generic lambda expressions are only available in C++14 or later. A functor "
"with a templated function call operator is necessary to use C++11 as shown:"

#. type: heading
#: 42
#, fuzzy
msgid "Split Serialization"
msgstr "Split Serialization"

#. type: paragraph
#: 44
#, fuzzy
msgid ""
"In some cases, such as the handling of the [@https://tools.ietf.org/html/"
"rfc7231#section-5.1.1 Expect: 100-continue] field, it may be desired to "
"first serialize the header, perform some other action, and then continue "
"with serialization of the body. This is accomplished by calling [link "
"beast.ref.boost__beast__http__serializer.split `serializer::split`] with a "
"boolean indicating that when buffers are produced, the last buffer "
"containing serialized header octets will not contain any octets "
"corresponding to the body. The function [link "
"beast.ref.boost__beast__http__serializer.is_header_done "
"`serializer::is_header_done`] informs the caller whether the header been "
"serialized fully. In this C++14 example we print the header first, followed "
"by the body:"
msgstr ""
"In some cases, such as the handling of the [@https://tools.ietf.org/html/"
"rfc7231#section-5.1.1 Expect: 100-continue] field, it may be desired to "
"first serialize the header, perform some other action, and then continue "
"with serialization of the body. This is accomplished by calling [link "
"beast.ref.boost__beast__http__serializer.split `serializer::split`] with a "
"boolean indicating that when buffers are produced, the last buffer "
"containing serialized header octets will not contain any octets "
"corresponding to the body. The function [link "
"beast.ref.boost__beast__http__serializer.is_header_done "
"`serializer::is_header_done`] informs the caller whether the header been "
"serialized fully. In this C++14 example we print the header first, followed "
"by the body:"

#. type: section title
#: 61
#, fuzzy
msgid "Write To std::ostream __example__"
msgstr "Write To std::ostream __example__"

#. type: paragraph
#: 63
#, fuzzy
msgid ""
"The standard library provides the type `std::ostream` for performing high "
"level write operations on character streams. The variable `std::cout` is "
"based on this output stream. This example uses the buffer oriented interface "
"of __serializer__ to write an HTTP message to a `std::ostream`:"
msgstr ""
"The standard library provides the type `std::ostream` for performing high "
"level write operations on character streams. The variable `std::cout` is "
"based on this output stream. This example uses the buffer oriented interface "
"of __serializer__ to write an HTTP message to a `std::ostream`:"

#. type: paragraph
#: 71
#, fuzzy
msgid "Serializing to a `std::ostream` could be implemented using an alternate"
msgstr "Serializing to a `std::ostream` could be implemented using an alternate"
