summaryrefslogtreecommitdiff
path: root/boost/intrusive/sg_set.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/intrusive/sg_set.hpp')
-rw-r--r--boost/intrusive/sg_set.hpp59
1 files changed, 59 insertions, 0 deletions
diff --git a/boost/intrusive/sg_set.hpp b/boost/intrusive/sg_set.hpp
index 171bd59ed1..745c3790b9 100644
--- a/boost/intrusive/sg_set.hpp
+++ b/boost/intrusive/sg_set.hpp
@@ -26,6 +26,11 @@
namespace boost {
namespace intrusive {
+#if !defined(BOOST_INTRUSIVE_DOXYGEN_INVOKED)
+template<class ValueTraits, class VoidOrKeyOfValue, class Compare, class SizeType, bool ConstantTimeSize, typename HeaderHolder>
+class sg_multiset_impl;
+#endif
+
//! The class template sg_set is an intrusive container, that mimics most of
//! the interface of std::sg_set as described in the C++ standard.
//!
@@ -148,6 +153,15 @@ class sg_set_impl
//! @copydoc ::boost::intrusive::sgtree::crend()const
const_reverse_iterator crend() const;
+ //! @copydoc ::boost::intrusive::sgtree::root()
+ iterator root();
+
+ //! @copydoc ::boost::intrusive::sgtree::root()const
+ const_iterator root() const;
+
+ //! @copydoc ::boost::intrusive::sgtree::croot()const
+ const_iterator croot() const;
+
//! @copydoc ::boost::intrusive::sgtree::container_from_end_iterator(iterator)
static sg_set_impl &container_from_end_iterator(iterator end_iterator);
@@ -410,6 +424,24 @@ class sg_set_impl
//! @copydoc ::boost::intrusive::sgtree::balance_factor(float)
void balance_factor(float new_alpha);
+ //! @copydoc ::boost::intrusive::rbtree::merge_unique
+ template<class ...Options2>
+ void merge(sg_set<T, Options2...> &source);
+
+ //! @copydoc ::boost::intrusive::rbtree::merge_unique
+ template<class ...Options2>
+ void merge(sg_multiset<T, Options2...> &source);
+
+ #else
+
+ template<class Compare2>
+ void merge(sg_set_impl<ValueTraits, VoidOrKeyOfValue, Compare2, SizeType, FloatingPoint, HeaderHolder> &source)
+ { return tree_type::merge_unique(source); }
+
+ template<class Compare2>
+ void merge(sg_multiset_impl<ValueTraits, VoidOrKeyOfValue, Compare2, SizeType, FloatingPoint, HeaderHolder> &source)
+ { return tree_type::merge_unique(source); }
+
#endif //#ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED
};
@@ -669,6 +701,15 @@ class sg_multiset_impl
//! @copydoc ::boost::intrusive::sgtree::crend()const
const_reverse_iterator crend() const;
+ //! @copydoc ::boost::intrusive::sgtree::root()
+ iterator root();
+
+ //! @copydoc ::boost::intrusive::sgtree::root()const
+ const_iterator root() const;
+
+ //! @copydoc ::boost::intrusive::sgtree::croot()const
+ const_iterator croot() const;
+
//! @copydoc ::boost::intrusive::sgtree::container_from_end_iterator(iterator)
static sg_multiset_impl &container_from_end_iterator(iterator end_iterator);
@@ -889,6 +930,24 @@ class sg_multiset_impl
//! @copydoc ::boost::intrusive::sgtree::balance_factor(float)
void balance_factor(float new_alpha);
+ //! @copydoc ::boost::intrusive::treap::merge_unique
+ template<class ...Options2>
+ void merge(sg_multiset<T, Options2...> &source);
+
+ //! @copydoc ::boost::intrusive::treap::merge_unique
+ template<class ...Options2>
+ void merge(sg_set<T, Options2...> &source);
+
+ #else
+
+ template<class Compare2>
+ void merge(sg_multiset_impl<ValueTraits, VoidOrKeyOfValue, Compare2, SizeType, FloatingPoint, HeaderHolder> &source)
+ { return tree_type::merge_equal(source); }
+
+ template<class Compare2>
+ void merge(sg_set_impl<ValueTraits, VoidOrKeyOfValue, Compare2, SizeType, FloatingPoint, HeaderHolder> &source)
+ { return tree_type::merge_equal(source); }
+
#endif //#ifdef BOOST_INTRUSIVE_DOXYGEN_INVOKED
};