Orcus
Loading...
Searching...
No Matches
orcus::sax_token_parser< HandlerT > Class Template Reference

#include <sax_token_parser.hpp>

Public Types

typedef HandlerT handler_type
 

Public Member Functions

 sax_token_parser (std::string_view content, const tokens &_tokens, xmlns_context &ns_cxt, handler_type &handler)
 
void parse ()
 

Detailed Description

template<typename HandlerT>
class orcus::sax_token_parser< HandlerT >

SAX parser that tokenizes element and attribute names while parsing. All pre-defined elements and attribute names are translated into integral identifiers via use of tokens. The user of this class needs to provide a pre-defined set of element and attribute names at construction time.

This parser internally uses sax_ns_parser.

Template Parameters
HandlerTHandler type with member functions for event callbacks. Refer to sax_token_handler.