summaryrefslogtreecommitdiff
path: root/indra/newview/llvocache.h
diff options
context:
space:
mode:
authorAndreyL ProductEngine <alihatskiy@productengine.com>2019-11-27 08:19:22 +0200
committerAndreyL ProductEngine <alihatskiy@productengine.com>2019-11-27 08:19:22 +0200
commitd0c7b4fade611bb3bd05a4e6230145b1babc9f7f (patch)
tree96edb360c7cacaef64a4b865e7d97c9ef8404669 /indra/newview/llvocache.h
parent49216183902045a2b9ba4a0627eb4298a65c004c (diff)
parent78bdf57ad6610b34389226bf941ba736ca0c2225 (diff)
Merged in lindenlab/viewer-release
Diffstat (limited to 'indra/newview/llvocache.h')
-rw-r--r--indra/newview/llvocache.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/indra/newview/llvocache.h b/indra/newview/llvocache.h
index 594d38249b..6c95541c11 100644
--- a/indra/newview/llvocache.h
+++ b/indra/newview/llvocache.h
@@ -221,9 +221,9 @@ private:
//
//Note: LLVOCache is not thread-safe
//
-class LLVOCache : public LLSingleton<LLVOCache>
+class LLVOCache : public LLParamSingleton<LLVOCache>
{
- LLSINGLETON(LLVOCache);
+ LLSINGLETON(LLVOCache, bool read_only);
~LLVOCache() ;
private:
@@ -259,15 +259,14 @@ private:
typedef std::map<U64, HeaderEntryInfo*> handle_entry_map_t;
public:
- void initCache(ELLPath location, U32 size, U32 cache_version) ;
+ // We need this init to be separate from constructor, since we might construct cache, purge it, then init.
+ void initCache(ELLPath location, U32 size, U32 cache_version);
void removeCache(ELLPath location, bool started = false) ;
void readFromCache(U64 handle, const LLUUID& id, LLVOCacheEntry::vocache_entry_map_t& cache_entry_map) ;
void writeToCache(U64 handle, const LLUUID& id, const LLVOCacheEntry::vocache_entry_map_t& cache_entry_map, BOOL dirty_cache, bool removal_enabled);
void removeEntry(U64 handle) ;
- void setReadOnly(bool read_only) {mReadOnly = read_only;}
-
U32 getCacheEntries() { return mNumEntries; }
U32 getCacheEntriesMax() { return mCacheSize; }