From fb5176bbd5355b02b7d0e65da3ef3f0105824cd0 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sun, 17 Mar 2013 23:45:21 +0000 Subject: The new cache system has been broken out into it's individual headers, and is now ready for actual use. --- src/experimental/cachecalc.h | 63 -------------------------------------------- 1 file changed, 63 deletions(-) delete mode 100644 src/experimental/cachecalc.h (limited to 'src/experimental/cachecalc.h') diff --git a/src/experimental/cachecalc.h b/src/experimental/cachecalc.h deleted file mode 100644 index c6cf33a..0000000 --- a/src/experimental/cachecalc.h +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (C) 2007-2013 Xagasoft, All rights reserved. - * - * This file is part of the libbu++ library and is released under the - * terms of the license contained in the file LICENSE. - */ - -#ifndef BU_CACHE_CALC_H -#define BU_CACHE_CALC_H - -#include "bu/trace.h" - -#include - -namespace Bu -{ - template class Cache; - - template - class CacheCalc - { - friend class Cache; - private: - typedef Cache MyCache; - public: - CacheCalc() : - pCache( (MyCache *)0 ) - { - TRACE(); - } - - virtual ~CacheCalc() - { - TRACE(); - } - - virtual void onLoad( obtype *pSrc, const keytype &key )=0; - virtual void onUnload( obtype *pSrc, const keytype &key )=0; - virtual void onDestroy( obtype *pSrc, const keytype &key )=0; - virtual void onDestroy( const keytype &key )=0; - virtual bool shouldSync( obtype *pSrc, const keytype &key, - time_t tLastSync )=0; - virtual void onTick() { }; - - protected: - MyCache *getCache() - { - TRACE(); - return pCache; - } - - private: - void setCache( MyCache *pCache ) - { - TRACE(); - this->pCache = pCache; - } - - MyCache *pCache; - }; -}; - -#endif -- cgit v1.2.3