Removed legacy comparator.h
authorkhizmax <libcds.dev@gmail.com>
Mon, 16 Mar 2015 17:49:44 +0000 (20:49 +0300)
committerkhizmax <libcds.dev@gmail.com>
Mon, 16 Mar 2015 17:49:44 +0000 (20:49 +0300)
cds/details/comparator.h [deleted file]
projects/Win/vc12/cds.vcxproj
projects/Win/vc12/cds.vcxproj.filters

diff --git a/cds/details/comparator.h b/cds/details/comparator.h
deleted file mode 100644 (file)
index 2fc5a39..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-//$$CDS-header$$
-
-#ifndef CDSLIB_DETAILS_COMPARATOR_H
-#define CDSLIB_DETAILS_COMPARATOR_H
-
-#include <functional>
-#include <string>
-
-namespace cds {
-    /// Helper classes and functions
-    namespace details {
-        /// Comparator
-        /**
-            Comparator is a functor (a class with binary @a operator() ) that compares two values.
-            The comparator is based on \p std::less<T> functor and returns the result
-            of comparing of two values:
-            \li -1 if a < b
-            \li 0 if a == b
-            \li 1 if a > b
-        */
-        template <typename T>
-        class Comparator {
-            //@cond
-            std::less< T > m_cmp;
-            //@endcond
-        public:
-            typedef T        value_type    ;    ///< Type of values to compare
-
-            /// Compare method
-            /**
-                @return -1 if @p p1 < @p p2 \n
-                0 if @p p1 == @p p2 \n
-                1 if @p p1 > @p p2 \n
-            */
-            int operator()( const T& p1, const T& p2 ) const
-            {
-                if ( m_cmp( p1, p2 ) )
-                    return -1;
-                if ( m_cmp( p2, p1 ))
-                    return 1;
-                return 0;
-            }
-        };
-
-        /// String specialization. It uses @a string::compare method
-        template <>
-        class Comparator< std::string > {
-        public:
-            //@cond
-            typedef std::string        value_type    ;    ///< Type of values to compare
-
-            int operator()( const std::string& str1, const std::string& str2 ) const
-            {
-                return str1.compare( str2 );
-            }
-            //@endcond
-        };
-    }    // namespace details
-}    // namespace cds
-
-#endif // #ifndef CDSLIB_DETAILS_COMPARATOR_H
index 159bf0470ad0a4be8617688b70fdc40f4f35ae77..09504492d19c2b7baac140887fe585fd4acabdc4 100644 (file)
     <ClInclude Include="..\..\..\cds\details\allocator.h" />\r
     <ClInclude Include="..\..\..\cds\details\bitop_generic.h" />\r
     <ClInclude Include="..\..\..\cds\details\bounded_array.h" />\r
-    <ClInclude Include="..\..\..\cds\details\comparator.h" />\r
     <ClInclude Include="..\..\..\cds\details\defs.h" />\r
     <ClInclude Include="..\..\..\cds\details\is_aligned.h" />\r
     <ClInclude Include="..\..\..\cds\details\make_const_type.h" />\r
index 6306656382477bb2b0b0fa0a543337275c480238..54bc40c49827e47e724274cec912d1453a5b50f0 100644 (file)
     <ClInclude Include="..\..\..\cds\details\bounded_array.h">\r
       <Filter>Header Files\cds\details</Filter>\r
     </ClInclude>\r
-    <ClInclude Include="..\..\..\cds\details\comparator.h">\r
-      <Filter>Header Files\cds\details</Filter>\r
-    </ClInclude>\r
     <ClInclude Include="..\..\..\cds\details\defs.h">\r
       <Filter>Header Files\cds\details</Filter>\r
     </ClInclude>\r