From a15cf65c44d5c224169c32ef5495b68c758134b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 18 May 2014 16:08:14 +0200 Subject: Imported Upstream version 3.3.0.2 --- .../cxx/tree/custom/wildcard/wildcard-custom.hxx | 67 ++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 xsd/examples/cxx/tree/custom/wildcard/wildcard-custom.hxx (limited to 'xsd/examples/cxx/tree/custom/wildcard/wildcard-custom.hxx') diff --git a/xsd/examples/cxx/tree/custom/wildcard/wildcard-custom.hxx b/xsd/examples/cxx/tree/custom/wildcard/wildcard-custom.hxx new file mode 100644 index 0000000..2c58cc8 --- /dev/null +++ b/xsd/examples/cxx/tree/custom/wildcard/wildcard-custom.hxx @@ -0,0 +1,67 @@ +// file : examples/cxx/tree/custom/wildcard/wildcard-custom.hxx +// author : Boris Kolpackov +// copyright : not copyrighted - public domain + +// Do not include this file directly, use wildcard.hxx instead. This +// file is included into generated wildcard.hxx so we do not need to +// guard against multiple inclusions. +// + +namespace wildcard +{ + class data: public data_base + { + // Standard constructors. + // + public: + data (const xml_schema::string&); + + data (const xercesc::DOMElement&, + xml_schema::flags = 0, + xml_schema::container* = 0); + + data (const data&, + xml_schema::flags = 0, + xml_schema::container* = 0); + + virtual data* + _clone (xml_schema::flags = 0, + xml_schema::container* = 0) const; + + // Our customizations. + // + public: + bool + scope_present () const + { + return scope_present_; + } + + const xml_schema::string& + scope () const + { + return scope_; + } + + void + scope (const xml_schema::string& s) + { + scope_present_ = true; + scope_ = s; + } + + private: + bool scope_present_; + xml_schema::string scope_; + }; + + // Serialization operator. + // + void + operator<< (xercesc::DOMElement&, const data&); + + // std::ostream insertion operator. + // + std::ostream& + operator<< (std::ostream&, const data&); +} -- cgit v1.2.3