| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| Parent folder | |||
| 2026.01.20 source code.tar.gz | < 8 hours ago | 36.1 MB | |
| 2026.01.20 source code.zip | < 8 hours ago | 36.5 MB | |
| README.md | < 8 hours ago | 6.2 kB | |
| Totals: 3 Items | 72.6 MB | 0 | |
This release introduces a major overhaul of the SDK's core, focusing on modern C++20 features for XML parsing, robust type-safe data conversions, and configurable safety policies. Significant architectural changes have been made to enhance resilience against partial failures in parsers, improve memory management, and standardize date/time handling using std::chrono. The update also includes new utilities for named parameters and non-null or in-range assertions, alongside numerous fixes and documentation improvements.
The XML stream, a new path it takes,
With C++20, a modern API awakes.
Safety policies, strict or relaxed,
Data conversions, precisely taxed.
Partial failures, now gracefully met,
std::chronodates, no more regret.
A robust foundation, strong and so keen,
DocWire's future, brightly foreseen.
✨🚀🛡️
- Features
- Modern C++20 XML Parsing API: Introduced a new, expressive, and safe API for parsing XML documents, featuring a single-pass, forward-only reader and utilizing C++20 ranges and views for efficient node filtering and manipulation. This replaces the legacy
XmlStreamwithxml::reader,xml::node_ref,xml::children, andxml::attributes. - Configurable Safety Policies: Implemented a general concept of safety policies (
strictvs.relaxed) allowing developers to choose between robust error-checking (throwing exceptions on violations) and maximum performance (omitting checks). This is applied throughcheckedandnot_nullwrappers, and theenforceutility. - Type-Safe Data Conversion Framework: Introduced a new
convertnamespace withtry_toandtofunctions for robust, type-safe data conversions, replacing manual string-to-numeric/date conversions. This framework supports custom format tags likewith::date_formatandwith::partial_match. - C++20
std::chronofor Date/Time Handling: Replaced allstruct tmusage withstd::chrono::sys_secondsfor date and time attributes and conversions, enhancing type safety and robustness across the SDK. - Partial Failure Resilience in Parsers: Implemented
message_countersandmake_counted_message_callbacksinarchives_parser,EMLParser,HTMLParser,PDFParser, andPSTParserto allow processing to continue even if some sub-items fail, and to detect total failures. - Base64 Decoding: Added a
base64::decodefunction and support for parsingdata:URLs in HTML image sources. - Named Parameters and Structured Bindings: Introduced
named::valueandoperator""_vliteral for creating named parameters, with full support for C++ structured bindings. - Non-Null Assertion Utility: Added
not_nullwrapper for pointer-like types, enforcing non-null invariants based on the configuredsafety_policy. Includesassume_not_nullfor unchecked construction when non-null is guaranteed. - Ranged Numeric Types: Introduced
rangedtemplate for numeric types with compile-time or runtime-checked bounds, along with fluent aliases likeat_least,at_most,exactly, andnon_negative. -
Debug-Only Assertions: Added
debug_assertfor assertions that are only active in debug builds, providing a mechanism for internal contract checking without runtime overhead in release builds. -
Improvements
- HTML Parser Memory Management: Improved HTML parser by using
std::unique_ptrforlxb_html_document_tand validating head text before CSS parsing to prevent potential crashes. - PST Parser Robustness: Enhanced PST parser with
unique_handleRAII wrappers forlibpffandlibbfioresources, ensuring exception-safe cleanup. Fixed destruction order of handles and usedLIBBFIO_OPEN_READto prevent accidental file truncation. - Logging Enhancements: Refactored
log_scopemacro andscopeclass for better control and zero-cost in release builds. Addedto_log_valuefordocwire::named::valueto improve structured logging. - Error Reporting:
make_error_from_tupleandmake_error_ptr_from_tuplefunctions were added for more flexible error creation. -
Efficient String View Access: Added a
string_view()method todata_sourcefor efficient, allocation-free access to data asstd::string_viewwhere possible. -
Refactor
- XML Parsing Integration: All XML-based parsers (
CommonXMLDocumentParser,ODFOOXMLParser,ODFXMLParser,XMLParser) have been refactored to utilize the new C++20 XML parsing API. - Date/Time Serialization: Removed
serialization_time.hasstd::chronotypes are now directly convertible to/from strings via the newconvertframework. rapidfuzzDependency: Updated therapidfuzzdependency torapidfuzz-cppto align with the upstream vcpkg port rename.-
XmlStreamRemoval: The legacyXmlStreamclass and its associated files (xml_stream.h,xml_stream.cpp) have been removed, replaced by the newxml::readerAPI. -
Fixes
CommonXMLDocumentParser::onODFOOXMLText: Removed a redundant check for the "#text" node name.-
ODFOOXMLParser::onOOXMLFldData: Added a handler to skipfldDatacontent in OOXML. -
Documentation
- Updated
README.md: TheREADME.mdfile has been updated to highlight the new "Modern C++20 XML Parsing" and "Configurable Safety Policies" features, including a new example demonstrating the XML parsing API. -
Doxygen Documentation: Comprehensive Doxygen documentation has been added for the new XML parsing utilities and helper classes.
-
Tests
- New XML API Tests: Added
xml_tests.cppandxml_parsing_example.cppto thoroughly test the new C++20 XML parsing API. api_tests.cppEnhancements: Updatedapi_tests.cppwith new tests forbase64::decode,convertfrom and tostd::chrono,namedstructured bindings,not_nullassertions, andPartialAndTotalFailuresscenarios forZIP,EML,PST,HTML, andPDFparsers.- New Test Files: Added
embedded_images.htmlandembedded_images.html.outfor testing HTML image processing.