Annotation of parser3/src/include/pa_cache_managers.h, revision 1.15

1.1       paf         1: /** @file
                      2:        Parser: cache managers center decl.
                      3: 
1.10      paf         4:        Copyright (c) 2001-2003 ArtLebedev Group (http://www.artlebedev.com)
1.6       paf         5:        Author: Alexandr Petrosian <paf@design.ru> (http://paf.design.ru)
1.1       paf         6: 
1.15    ! paf         7:        $Date: 2003/12/11 09:25:50 $
1.1       paf         8: */
                      9: 
                     10: #ifndef PA_CACHE_MANAGERS_H
                     11: #define PA_CACHE_MANAGERS_H
1.7       paf        12: 
1.15    ! paf        13: static const char * const IDENT_CACHE_MANAGERS_H="$Date: 2003/12/11 09:25:50 $";
1.1       paf        14: 
                     15: #include "pa_hash.h"
                     16: #include "pa_value.h"
                     17: 
                     18: // defines
                     19: 
1.10      paf        20: /// can return status and can expire it contents
                     21: class Cache_manager: public PA_Object {
                     22: public:
                     23:        /// if filter_server_id not null, returns status only Cachable -s with matching cacheable_item_server_id()
                     24:        virtual Value* get_status() =0;
                     25:        virtual void maybe_expire_cache() {}
1.13      paf        26:        virtual ~Cache_manager() {}
1.10      paf        27: };
1.1       paf        28: 
                     29: /// maintains name=>Cache_manager association, can expire its contents
1.11      paf        30: class Cache_managers: public Hash<const String::Body, Cache_manager*> {
1.1       paf        31: public:
1.14      paf        32:        Cache_managers();
                     33: 
1.1       paf        34:        /// maybe-expires all caches it contains, each cache manager desides it itself
                     35:        void maybe_expire();
                     36: 
                     37: };
                     38: 
                     39: /// global
1.15    ! paf        40: extern Cache_managers* cache_managers;
1.1       paf        41: 
                     42: #endif

E-mail: