8 #include "boost/functional/hash.hpp"
19 friend inline std::size_t hash_value(
Node_iri const& node)
20 {
return node.hash_impl();}
24 explicit Node_iri(
const Ns_id ns = terms::empty::id(), std::string
const& val =
"")
27 if( is_blank(ns_) ) BOOST_THROW_EXCEPTION(
28 Rdf_err() << Rdf_err::msg_t(
"blank \"_\" namespace in IRI node")
32 std::string
const& fragment()
const {
return val_;}
40 Ns_id ns_id_impl()
const {
return ns_; }
42 bool equal_impl(
const Node& n)
const {
44 if(
Node_iri const*
const p = dynamic_cast<Node_iri const*>(&n) ) {
45 return ns_ == p->ns_ && val_ == p->val_;
50 std::size_t hash_impl()
const {
52 boost::hash_combine(h, val_);
53 boost::hash_combine(h, ns_);