lucee.Componentcoldbox.system.cache.store.DiskStore
Copyright Since 2005 ColdBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com --- I am a disk store, I am not that fancy as I am slower.
Property Summary | ||||
---|---|---|---|---|
type | property | default | serializable | required |
any<ICacheProvider>
|
cacheProvider
The cache provider reference.
|
true
|
false
|
|
any<ObjectMarshaller>
|
converter
The object serializer and deserializer utility.
|
true
|
false
|
|
any
|
directoryPath
The location of the disk cache.
|
true
|
false
|
|
any<MetadataIndexer>
|
indexer
The metadata indexer object.
|
true
|
false
|
|
any
|
storeID
The human store name.
|
true
|
false
|
Constructor Summary | |
---|---|
init(any<ICacheProvider> cacheProvider)
Constructor. |
Method Summary | |
---|---|
any
|
clear(any objectKey)
Clears an object from the storage. |
void
|
clearAll()
Clear all the elements in the store. |
void
|
expireObject(any objectKey)
Expire an object. |
void
|
flush()
Flush the store to a permanent storage. |
any
|
get(any objectKey)
Get an object from the store with metadata tracking, or null if not found. |
any
|
getCacheFilePath(any objectKey)
Get the cached file path according to our rules. |
string
|
getCacheProvider()
|
string
|
getConverter()
|
string
|
getDirectoryPath()
|
any
|
getIndexer()
Get the store's pool metadata indexer structure. |
any
|
getKeys()
Get all the store's object keys array. |
any
|
getQuiet(any objectKey)
Get an object from cache with no metadata tracking. |
any
|
getSize()
Get the size of the store. |
string
|
getStoreID()
|
any
|
isExpired(any objectKey)
Expire check. |
any
|
lookup(any objectKey)
Check if an object is in the store. |
void
|
reap()
Reap the storage. |
void
|
set(any objectKey, any object, [any timeout=''], [any lastAccessTimeout=''], [any extras='[runtime expression]'])
Sets an object in the storage. |
any
|
setCacheProvider(any cacheProvider)
|
any
|
setConverter(any converter)
|
any
|
setDirectoryPath(any directoryPath)
|
any
|
setIndexer(any indexer)
|
any
|
setStoreID(any storeID)
|
Methods inherited from class lucee.Component |
---|
None |
Constructor Detail |
---|
Constructor
cacheProvider
- The associated cache provider as coldbox.system.cache.providers.ICacheProviderProperty Detail |
---|
The cache provider reference
access
- publicrequired
- falsereturntype
- anydoc_generic
- coldbox.system.cache.providers.ICacheProviderserializable
- trueThe object serializer and deserializer utility
access
- publicrequired
- falsereturntype
- anydoc_generic
- coldbox.system.core.conversion.ObjectMarshallerserializable
- trueThe location of the disk cache
access
- publicrequired
- falsereturntype
- anyserializable
- trueThe metadata indexer object
access
- publicrequired
- falsereturntype
- anydoc_generic
- coldbox.system.cache.store.indexers.MetadataIndexerserializable
- trueThe human store name
access
- publicrequired
- falsereturntype
- anyserializable
- trueMethod Detail |
---|
Clears an object from the storage
clear
in interface
IObjectStore
objectKey
- The object key to clearClear all the elements in the store
clearAll
in interface
IObjectStore
Expire an object
expireObject
in interface
IObjectStore
objectKey
- The key to expireFlush the store to a permanent storage
flush
in interface
IObjectStore
Get an object from the store with metadata tracking, or null if not found
get
in interface
IObjectStore
objectKey
- The key to retrieveGet the cached file path according to our rules
objectKey
- The key to lookupGet the store's pool metadata indexer structure
getIndexer
in interface
IObjectStore
Get all the store's object keys array
getKeys
in interface
IObjectStore
Get an object from cache with no metadata tracking
getQuiet
in interface
IObjectStore
objectKey
- The key to retrieveGet the size of the store
getSize
in interface
IObjectStore
Expire check
isExpired
in interface
IObjectStore
objectKey
- The key to checkCheck if an object is in the store
lookup
in interface
IObjectStore
objectKey
- The key to lookupReap the storage
reap
in interface
IObjectStore
Sets an object in the storage
set
in interface
IObjectStore
objectKey
- The object keyobject
- The object to savetimeout
- Timeout in minuteslastAccessTimeout
- Idle Timeout in minutesextras
- A map of extra name-value pairs to store alongside the objectcacheProvider
converter
directoryPath
indexer
storeID