aboutsummaryrefslogtreecommitdiff
path: root/libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2010-10-08 15:35:23 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2010-10-08 15:35:23 +0200
commit7db026e8056914d113ac0bbfd9bdc4908a9e7874 (patch)
tree0ab15cb8b0ee160a10cca21edaf0aca1e97e8921 /libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx
parent4f38adc11ab1a3a1ab2dd3f958c917182be7d71f (diff)
Add support for the whiteSpace facet
Use the same mechanism to handle whitespace processing for build-in types and enumerations.
Diffstat (limited to 'libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx')
-rw-r--r--libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx187
1 files changed, 169 insertions, 18 deletions
diff --git a/libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx b/libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx
index 95e3258..2be6cbf 100644
--- a/libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx
+++ b/libxsde/xsde/cxx/parser/non-validating/xml-schema-pskel.ixx
@@ -315,6 +315,20 @@ namespace xsde
}
#endif
+ // string_facets
+ //
+ inline string_facets::
+ string_facets ()
+ {
+ facets_.whitespace_ = 0;
+ }
+
+ inline void string_facets::
+ _whitespace_facet (unsigned int v)
+ {
+ facets_.whitespace_ = v;
+ }
+
// string_pskel
//
#ifdef XSDE_REUSE_STYLE_TIEIN
@@ -330,70 +344,137 @@ namespace xsde
{
}
#endif
+ inline const string_facets::facets& string_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const string_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// normalized_string_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline normalized_string_pskel::
normalized_string_pskel ()
- : normalized_string_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ normalized_string_impl_ = 0;
+#endif
+ _whitespace_facet (1); // replace
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline normalized_string_pskel::
normalized_string_pskel (normalized_string_pskel* impl, void*)
: simple_content (impl, 0), normalized_string_impl_ (impl)
{
+ _whitespace_facet (1); // replace
}
#endif
+ inline const string_facets::facets& normalized_string_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const normalized_string_pskel&> (
+ *parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// token_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline token_pskel::
token_pskel ()
- : token_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ token_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline token_pskel::
token_pskel (token_pskel* impl, void*)
: simple_content (impl, 0), token_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& token_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const token_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// name_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline name_pskel::
name_pskel ()
- : name_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ name_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline name_pskel::
name_pskel (name_pskel* impl, void*)
: simple_content (impl, 0), name_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& name_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const name_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// nmtoken_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline nmtoken_pskel::
nmtoken_pskel ()
- : nmtoken_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ nmtoken_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline nmtoken_pskel::
nmtoken_pskel (nmtoken_pskel* impl, void*)
: simple_content (impl, 0), nmtoken_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& nmtoken_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const nmtoken_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// nmtokens_pskel
//
@@ -413,51 +494,93 @@ namespace xsde
// ncname_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline ncname_pskel::
ncname_pskel ()
- : ncname_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ ncname_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline ncname_pskel::
ncname_pskel (ncname_pskel* impl, void*)
: simple_content (impl, 0), ncname_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& ncname_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const ncname_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// id_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline id_pskel::
id_pskel ()
- : id_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ id_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline id_pskel::
id_pskel (id_pskel* impl, void*)
: simple_content (impl, 0), id_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& id_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const id_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// idref_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline idref_pskel::
idref_pskel ()
- : idref_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ idref_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline idref_pskel::
idref_pskel (idref_pskel* impl, void*)
: simple_content (impl, 0), idref_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& idref_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const idref_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// idrefs_pskel
//
@@ -477,35 +600,63 @@ namespace xsde
// language_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline language_pskel::
language_pskel ()
- : language_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ language_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline language_pskel::
language_pskel (language_pskel* impl, void*)
: simple_content (impl, 0), language_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& language_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const language_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// uri_pskel
//
-#ifdef XSDE_REUSE_STYLE_TIEIN
inline uri_pskel::
uri_pskel ()
- : uri_impl_ (0)
{
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ uri_impl_ = 0;
+#endif
+ _whitespace_facet (2); // collapse
}
+#ifdef XSDE_REUSE_STYLE_TIEIN
inline uri_pskel::
uri_pskel (uri_pskel* impl, void*)
: simple_content (impl, 0), uri_impl_ (impl)
{
+ _whitespace_facet (2); // collapse
}
#endif
+ inline const string_facets::facets& uri_pskel::
+ _facets () const
+ {
+#ifdef XSDE_REUSE_STYLE_TIEIN
+ if (parent_ != 0)
+ return static_cast<const uri_pskel&> (*parent_).facets_;
+ else
+#endif
+ return facets_;
+ }
// qname_pskel
//