summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2015-12-23 16:55:23 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2015-12-23 16:55:23 +0000
commit9de4960af81d2d7a142b7b57e3e3914a9144f516 (patch)
treec4f940f8d3f97fd3d94f70ddfafc74b488c59611
parentRemove flto cos I'm sick of it randomly breaking stuff (diff)
downloadlibadhocutil-9de4960af81d2d7a142b7b57e3e3914a9144f516.tar.bz2
libadhocutil-9de4960af81d2d7a142b7b57e3e3914a9144f516.tar.xz
libadhocutil-9de4960af81d2d7a142b7b57e3e3914a9144f516.zip
Add missing visibility attributes in cache
-rw-r--r--libadhocutil/cache.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/libadhocutil/cache.h b/libadhocutil/cache.h
index ff899dc..06d4d5a 100644
--- a/libadhocutil/cache.h
+++ b/libadhocutil/cache.h
@@ -9,12 +9,13 @@
#include <boost/multi_index/ordered_index.hpp>
#include <boost/thread/shared_mutex.hpp>
#include <boost/variant.hpp>
+#include "visibility.h"
namespace AdHoc {
/// @cond
template <typename T, typename K>
-class Cacheable {
+class DLL_PUBLIC Cacheable {
public:
Cacheable(const K & k, time_t validUntil);
@@ -25,7 +26,7 @@ class Cacheable {
};
template <typename T, typename K>
-class ObjectCacheable : public Cacheable<T, K> {
+class DLL_PUBLIC ObjectCacheable : public Cacheable<T, K> {
public:
ObjectCacheable(const T & t, const K & k, time_t validUtil);
@@ -36,7 +37,7 @@ class ObjectCacheable : public Cacheable<T, K> {
};
template <typename T, typename K>
-class CallCacheable : public Cacheable<T, K> {
+class DLL_PUBLIC CallCacheable : public Cacheable<T, K> {
public:
CallCacheable(const T & t, const K & k, time_t validUtil);
CallCacheable(const boost::function<T()> & t, const K & k, time_t validUtil);
@@ -54,7 +55,7 @@ struct byKey {};
/// In-memory cache of T, keyed by K.
template <typename T, typename K>
-class Cache {
+class DLL_PUBLIC Cache {
public:
/// @cond
typedef K Key;
@@ -93,7 +94,7 @@ class Cache {
size_t size() const;
private:
- void prune() const;
+ void DLL_PRIVATE prune() const;
mutable time_t lastPruneTime;
mutable boost::shared_mutex lock;