owlcpp  v0.3.3~
C++ library for working with OWL ontologies
 All Classes Namespaces Files Functions Macros Pages
ns_iri_tag_macro.hpp
Go to the documentation of this file.
1 
6 #ifndef NS_IRI_TAG_MACRO_HPP_
7 #define NS_IRI_TAG_MACRO_HPP_
8 #include <string>
9 #include "owlcpp/ns_id.hpp"
10 
33 #define OWLCPP_NAMESPACE_TAG_TYPE(name, prefix_str, iri_str, i) struct name { \
34  typedef ::owlcpp::Ns_id id_type; \
35  static const id_type::value_type index = i; \
36  static std::string const & iri() { \
37  static const std::string str=iri_str; \
38  return str; \
39  } \
40  static std::string const & prefix() { \
41  static const std::string str=prefix_str; \
42  return str; \
43  } \
44  static id_type id() {return id_type(index);} \
45 }
46 /* */
47 
48 #endif /* NS_IRI_TAG_MACRO_HPP_ */