2 #ifndef JAWS_FILECACHE_H
3 #define JAWS_FILECACHE_H
5 #include "ace/FILE_IO.h"
7 #include "JAWS/Cache_Manager.h"
9 #include "JAWS/Export.h"
11 class JAWS_Export JAWS_Referenced_Filecache_Factory
12 : public JAWS_Referenced_Cache_Object_Factory
15 virtual void destroy (JAWS_Cache_Object
*);
18 class JAWS_Export JAWS_Counted_Filecache_Factory
19 : public JAWS_Counted_Cache_Object_Factory
22 virtual void destroy (JAWS_Cache_Object
*);
25 typedef JAWS_Cache_Manager
<JAWS_Strdup_String
,
26 JAWS_Referenced_Filecache_Factory
,
27 JAWS_String_Hash_Functor
,
28 JAWS_String_Equal_Functor
>
29 JAWS_Referenced_Filecache_Manager
;
31 typedef JAWS_Cache_Manager
<JAWS_Strdup_String
,
32 JAWS_Counted_Filecache_Factory
,
33 JAWS_String_Hash_Functor
,
34 JAWS_String_Equal_Functor
>
35 JAWS_Counted_Filecache_Manager
;
37 typedef JAWS_Counted_Filecache_Manager JAWS_Filecache_Manager
;
39 typedef JAWS_Cache_Proxy
<const char *,
40 JAWS_FILE
, JAWS_Filecache_Manager
>
43 class JAWS_Export JAWS_Cached_FILE
: private JAWS_Filecache_Proxy
46 JAWS_Cached_FILE (const char *const &filename
,
47 JAWS_Filecache_Proxy::Cache_Manager
*cm
= 0);
48 JAWS_Cached_FILE (const char *const &filename
,
51 JAWS_Filecache_Proxy::Cache_Manager
*cm
= 0);
55 ACE_FILE_IO
* file ();
56 ACE_Mem_Map
* mmap ();
63 #endif /* JAWS_FILECACHE_H */