From c04f7d6ed04d62efafa79a87bcde6c5f62e95327 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Wed, 20 Jun 2012 11:54:24 +0200 Subject: Completion of the CLI port --- xsd/cxx/elements.hxx | 40 +++++++++++----------------------------- 1 file changed, 11 insertions(+), 29 deletions(-) (limited to 'xsd/cxx/elements.hxx') diff --git a/xsd/cxx/elements.hxx b/xsd/cxx/elements.hxx index 15518fc..9ae4db8 100644 --- a/xsd/cxx/elements.hxx +++ b/xsd/cxx/elements.hxx @@ -18,7 +18,10 @@ #include #include +#include #include + +#include #include namespace CXX @@ -145,48 +148,36 @@ namespace CXX typedef Cult::Containers::Map ReservedNameMap; typedef Cult::Containers::Set KeywordSet; + typedef CXX::options options_type; + public: Context (std::wostream& o, SemanticGraph::Schema& root, SemanticGraph::Path const& path, - StringLiteralMap const* custom_literals_map, - NarrowString const& char_type__, - NarrowString const& char_encoding__, - Boolean include_with_brackets__, - NarrowString const& include_prefix__, - NarrowString const& esymbol, - Containers::Vector const& nsm, - Containers::Vector const& nsr, - Boolean trace_namespace_regex_, - Containers::Vector const& include_regex, - Boolean trace_include_regex_, - Boolean inline_, - Containers::Vector const& reserved_name); + options_type const& ops, + StringLiteralMap const* custom_literals_map); protected: Context (Context& c) : os (c.os), schema_root (c.schema_root), schema_path (c.schema_path), + options (c.options), char_type (c.char_type), char_encoding (c.char_encoding), L (c.L), string_type (c.string_type), string_literal_map (c.string_literal_map), - include_with_brackets (c.include_with_brackets), - include_prefix (c.include_prefix), type_exp (c.type_exp), inst_exp (c.inst_exp), inl (c.inl), ns_mapping_cache (c.ns_mapping_cache), xs_ns_ (c.xs_ns_), cxx_id_expr (c.cxx_id_expr), - trace_namespace_regex (c.trace_namespace_regex), urn_mapping (c.urn_mapping), nsr_mapping (c.nsr_mapping), nsm_mapping (c.nsm_mapping), include_mapping (c.include_mapping), - trace_include_regex (c.trace_include_regex), reserved_name_map (c.reserved_name_map), keyword_set (c.keyword_set) { @@ -196,25 +187,22 @@ namespace CXX : os (o), schema_root (c.schema_root), schema_path (c.schema_path), + options (c.options), char_type (c.char_type), char_encoding (c.char_encoding), L (c.L), string_type (c.string_type), string_literal_map (c.string_literal_map), - include_with_brackets (c.include_with_brackets), - include_prefix (c.include_prefix), type_exp (c.type_exp), inst_exp (c.inst_exp), inl (c.inl), ns_mapping_cache (c.ns_mapping_cache), xs_ns_ (c.xs_ns_), cxx_id_expr (c.cxx_id_expr), - trace_namespace_regex (c.trace_namespace_regex), urn_mapping (c.urn_mapping), nsr_mapping (c.nsr_mapping), nsm_mapping (c.nsm_mapping), include_mapping (c.include_mapping), - trace_include_regex (c.trace_include_regex), reserved_name_map (c.reserved_name_map), keyword_set (c.keyword_set) { @@ -342,15 +330,14 @@ namespace CXX SemanticGraph::Schema& schema_root; SemanticGraph::Path const& schema_path; + options_type const& options; + String& char_type; String& char_encoding; String& L; // string literal prefix String& string_type; StringLiteralMap const* string_literal_map; - Boolean& include_with_brackets; - String& include_prefix; - String& type_exp; String& inst_exp; String& inl; @@ -368,9 +355,6 @@ namespace CXX String L_; String string_type_; - Boolean include_with_brackets_; - String include_prefix_; - String type_exp_; String inst_exp_; String inl_; @@ -378,7 +362,6 @@ namespace CXX private: RegexPat const cxx_id_expr_; RegexPat const& cxx_id_expr; - Boolean trace_namespace_regex; Regex urn_mapping_; RegexMapping nsr_mapping_; MapMapping nsm_mapping_; @@ -389,7 +372,6 @@ namespace CXX RegexMapping include_mapping_; RegexMapping const& include_mapping; - Boolean trace_include_regex; ReservedNameMap const& reserved_name_map; ReservedNameMap reserved_name_map_; -- cgit v1.1