$NetBSD: patch-libcassandra_cassandra.h,v 1.1 2013/05/30 15:36:29 joerg Exp $ --- libcassandra/cassandra.h.orig 2013-05-30 10:29:32.000000000 +0000 +++ libcassandra/cassandra.h @@ -14,7 +14,11 @@ #include #include #include +#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L +#include +#else #include +#endif #include "libgenthrift/cassandra_types.h" @@ -65,17 +69,29 @@ public: /** * @return the keyspace with the given name. */ +#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L + std::shared_ptr getKeyspace(const std::string &name); +#else std::tr1::shared_ptr getKeyspace(const std::string &name); +#endif /** * @return the keyspace with the given name at the given consistency level. */ +#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L + std::shared_ptr getKeyspace(const std::string &name, org::apache::cassandra::ConsistencyLevel level); +#else std::tr1::shared_ptr getKeyspace(const std::string &name, org::apache::cassandra::ConsistencyLevel level); +#endif /** * Remove the given keyspace. */ +#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L + void removeKeyspace(std::shared_ptr k); +#else void removeKeyspace(std::tr1::shared_ptr k); +#endif /** * @return the target server cluster name. @@ -128,7 +144,11 @@ private: std::string config_file; std::set key_spaces; std::map token_map; +#if defined(_LIBCPP_VERSION) || __cplusplus >= 201103L + std::map > keyspace_map; +#else std::map > keyspace_map; +#endif Cassandra(const Cassandra&); Cassandra &operator=(const Cassandra&);