Annotation of parser3/src/include/pa_cache_managers.h, revision 1.1
1.1 ! paf 1: /** @file
! 2: Parser: cache managers center decl.
! 3:
! 4: Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com)
! 5: Author: Alexander Petrosyan <paf@design.ru> (http://paf.design.ru)
! 6:
! 7: $Id: pa_db_manager.h,v 1.6 2001/10/29 08:23:49 paf Exp $
! 8: */
! 9:
! 10: #ifndef PA_CACHE_MANAGERS_H
! 11: #define PA_CACHE_MANAGERS_H
! 12:
! 13: #include "pa_config_includes.h"
! 14: #include "pa_hash.h"
! 15: #include "pa_value.h"
! 16:
! 17: // defines
! 18:
! 19: // forwards
! 20:
! 21: /// maintains name=>Cache_manager association, can expire its contents
! 22: class Cache_managers : public Hash {
! 23: public:
! 24: Cache_managers(Pool& apool) : Hash(apool) {
! 25: }
! 26:
! 27: /// maybe-expires all caches it contains, each cache manager desides it itself
! 28: void maybe_expire();
! 29:
! 30: };
! 31:
! 32: /// can return status and can expire it contents
! 33: class Cache_manager {
! 34: public:
! 35: /// if filter_server_id not null, returns status only Cachable -s with matching cacheable_item_server_id()
! 36: virtual Value& get_status(Pool& pool, const String *source) =0;
! 37: virtual void maybe_expire_cache() {}
! 38: };
! 39:
! 40: /// global
! 41: extern Cache_managers *cache_managers;
! 42:
! 43: #endif
E-mail: