From 8f9a80a9ac8f353ce2cdafa23f0e5163d30d5800 Mon Sep 17 00:00:00 2001 From: Karen Arutyunov Date: Wed, 1 May 2019 22:32:11 +0300 Subject: Add support for description-type package manifest value --- web/xhtml-fragment.hxx | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) (limited to 'web/xhtml-fragment.hxx') diff --git a/web/xhtml-fragment.hxx b/web/xhtml-fragment.hxx index 14b9a21..fd41967 100644 --- a/web/xhtml-fragment.hxx +++ b/web/xhtml-fragment.hxx @@ -22,16 +22,21 @@ namespace web class fragment { public: + bool truncated = false; + + public: fragment () = default; - // Parse string as XHTML document fragment. The fragment should be - // complete, in the sense that all elements should have closing tags. - // Elements and attributes are considered to be in the namespace of the - // entire XHTML document, so no namespace should be specified for them. - // Do not validate against XHTML vocabulary. Can throw xml::parsing - // exception. + // Parse string as an XHTML document fragment, truncating it if + // requested. The fragment should be complete, in the sense that all + // elements should have closing tags. Elements and attributes are + // considered to be in the namespace of the entire XHTML document, so no + // namespace should be specified for them. Do not validate against XHTML + // vocabulary. Can throw xml::parsing exception. // - fragment (const std::string& xhtml, const std::string& input_name); + fragment (const std::string& xhtml, + const std::string& input_name, + size_t length = 0); void operator() (xml::serializer&) const; -- cgit v1.1