Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034 #ifndef NODE_PSKEL_HXX
00035 #define NODE_PSKEL_HXX
00036
00037
00038
00039
00040
00041
00042 #include <xsd/cxx/config.hxx>
00043
00044 #if (XSD_INT_VERSION != 3030000L)
00045 #error XSD runtime version mismatch
00046 #endif
00047
00048 #include <xsd/cxx/pre.hxx>
00049
00050
00051
00052 class node_pskel;
00053
00054 #ifndef XSD_USE_CHAR
00055 #define XSD_USE_CHAR
00056 #endif
00057
00058 #ifndef XSD_CXX_PARSER_USE_CHAR
00059 #define XSD_CXX_PARSER_USE_CHAR
00060 #endif
00061
00062 #include "xml_schema-pskel.hxx"
00063
00064 class tag_pskel;
00065 class node_pskel: public ::xml_schema::complex_content
00066 {
00067 public:
00068
00069
00070
00071
00072
00073 virtual void
00074 tag (const std::pair<std::string, std::string>&);
00075
00076 virtual void
00077 id (long long);
00078
00079 virtual void
00080 uid (long long);
00081
00082 virtual void
00083 user (const ::std::string&);
00084
00085 virtual void
00086 timestamp (const ::xml_schema::date_time&);
00087
00088 virtual void
00089 changeset (int);
00090
00091 virtual void
00092 version (int);
00093
00094 virtual void
00095 visible (bool);
00096
00097 virtual void
00098 lat (double);
00099
00100 virtual void
00101 lon (double);
00102
00103 virtual void
00104 action (const ::std::string&);
00105
00106 virtual osm::Node
00107 post_node () = 0;
00108
00109
00110
00111 void
00112 tag_parser (::tag_pskel&);
00113
00114 void
00115 id_parser (::xml_schema::long_pskel&);
00116
00117 void
00118 uid_parser (::xml_schema::long_pskel&);
00119
00120 void
00121 user_parser (::xml_schema::string_pskel&);
00122
00123 void
00124 timestamp_parser (::xml_schema::date_time_pskel&);
00125
00126 void
00127 changeset_parser (::xml_schema::int_pskel&);
00128
00129 void
00130 version_parser (::xml_schema::int_pskel&);
00131
00132 void
00133 visible_parser (::xml_schema::boolean_pskel&);
00134
00135 void
00136 lat_parser (::xml_schema::decimal_pskel&);
00137
00138 void
00139 lon_parser (::xml_schema::decimal_pskel&);
00140
00141 void
00142 action_parser (::xml_schema::string_pskel&);
00143
00144 void
00145 parsers (::tag_pskel& ,
00146 ::xml_schema::long_pskel& ,
00147 ::xml_schema::long_pskel& ,
00148 ::xml_schema::string_pskel& ,
00149 ::xml_schema::date_time_pskel& ,
00150 ::xml_schema::int_pskel& ,
00151 ::xml_schema::int_pskel& ,
00152 ::xml_schema::boolean_pskel& ,
00153 ::xml_schema::decimal_pskel& ,
00154 ::xml_schema::decimal_pskel& ,
00155 ::xml_schema::string_pskel& );
00156
00157
00158
00159 node_pskel ();
00160
00161
00162
00163 protected:
00164 virtual bool
00165 _start_element_impl (const ::xml_schema::ro_string&,
00166 const ::xml_schema::ro_string&,
00167 const ::xml_schema::ro_string*);
00168
00169 virtual bool
00170 _end_element_impl (const ::xml_schema::ro_string&,
00171 const ::xml_schema::ro_string&);
00172
00173 virtual bool
00174 _attribute_impl_phase_one (const ::xml_schema::ro_string&,
00175 const ::xml_schema::ro_string&,
00176 const ::xml_schema::ro_string&);
00177
00178
00179 protected:
00180 ::tag_pskel* tag_parser_;
00181 ::xml_schema::long_pskel* id_parser_;
00182 ::xml_schema::long_pskel* uid_parser_;
00183 ::xml_schema::string_pskel* user_parser_;
00184 ::xml_schema::date_time_pskel* timestamp_parser_;
00185 ::xml_schema::int_pskel* changeset_parser_;
00186 ::xml_schema::int_pskel* version_parser_;
00187 ::xml_schema::boolean_pskel* visible_parser_;
00188 ::xml_schema::decimal_pskel* lat_parser_;
00189 ::xml_schema::decimal_pskel* lon_parser_;
00190 ::xml_schema::string_pskel* action_parser_;
00191
00192 protected:
00193 struct v_state_descr_
00194 {
00195 void (::node_pskel::*func) (
00196 unsigned long&,
00197 unsigned long&,
00198 const ::xml_schema::ro_string&,
00199 const ::xml_schema::ro_string&,
00200 const ::xml_schema::ro_string*,
00201 bool);
00202 unsigned long state;
00203 unsigned long count;
00204 };
00205
00206 struct v_state_
00207 {
00208 v_state_descr_ data[2UL];
00209 unsigned long size;
00210 };
00211
00212 v_state_ v_state_first_;
00213 ::xsd::cxx::parser::pod_stack v_state_stack_;
00214
00215 virtual void
00216 _pre_e_validate ();
00217
00218 virtual void
00219 _post_e_validate ();
00220
00221 void
00222 sequence_0 (unsigned long& state,
00223 unsigned long& count,
00224 const ::xml_schema::ro_string& ns,
00225 const ::xml_schema::ro_string& n,
00226 const ::xml_schema::ro_string* t,
00227 bool start);
00228
00229 protected:
00230 struct v_state_attr_
00231 {
00232 bool id;
00233 bool lat;
00234 bool lon;
00235 };
00236
00237 v_state_attr_ v_state_attr_first_;
00238 ::xsd::cxx::parser::pod_stack v_state_attr_stack_;
00239
00240 virtual void
00241 _pre_a_validate ();
00242
00243 virtual void
00244 _post_a_validate ();
00245 };
00246
00247 #include <xsd/cxx/post.hxx>
00248
00249
00250
00251
00252
00253
00254 #endif // NODE_PSKEL_HXX