Chris@16: ///////////////////////////////////////////////////////////////////////////// Chris@16: // Chris@16: // (C) Copyright Ion Gaztanaga 2008 Chris@16: // Chris@16: // Distributed under the Boost Software License, Version 1.0. Chris@16: // (See accompanying file LICENSE_1_0.txt or copy at Chris@16: // http://www.boost.org/LICENSE_1_0.txt) Chris@16: // Chris@16: // See http://www.boost.org/libs/intrusive for documentation. Chris@16: // Chris@16: ///////////////////////////////////////////////////////////////////////////// Chris@16: Chris@16: #ifndef BOOST_INTRUSIVE_PRIORITY_COMPARE_HPP Chris@16: #define BOOST_INTRUSIVE_PRIORITY_COMPARE_HPP Chris@16: Chris@16: #include Chris@16: #include Chris@16: Chris@101: #include Chris@101: Chris@101: #if defined(BOOST_HAS_PRAGMA_ONCE) Chris@101: # pragma once Chris@101: #endif Chris@16: Chris@16: namespace boost { Chris@16: namespace intrusive { Chris@16: Chris@16: template Chris@16: struct priority_compare Chris@16: { Chris@101: //Compatibility with std::binary_function Chris@101: typedef T first_argument_type; Chris@101: typedef T second_argument_type; Chris@101: typedef bool result_type; Chris@101: Chris@16: bool operator()(const T &val, const T &val2) const Chris@16: { Chris@16: return priority_order(val, val2); Chris@16: } Chris@16: }; Chris@16: Chris@16: /// @cond Chris@16: Chris@16: template Chris@16: struct get_prio Chris@16: { Chris@16: typedef Less type; Chris@16: }; Chris@16: Chris@16: Chris@16: template Chris@16: struct get_prio Chris@16: { Chris@16: typedef ::boost::intrusive::priority_compare type; Chris@16: }; Chris@16: Chris@16: /// @endcond Chris@16: Chris@101: } //namespace intrusive Chris@101: } //namespace boost Chris@16: Chris@16: #include Chris@16: Chris@16: #endif //BOOST_INTRUSIVE_PRIORITY_COMPARE_HPP