coldbox.system.cache.store

Interface IObjectStore

coldbox.system.cache.store.IObjectStore
All Known Implementing Classes:
BlackHoleStore , ConcurrentSoftReferenceStore , ConcurrentStore , DiskStore , JDBCStore

Copyright Since 2005 ColdBox Framework by Luis Majano and Ortus Solutions, Corp www.ortussolutions.com --- The main interface for CacheBox object storages. A store is a physical counterpart to a cache, in which objects are kept, indexed and monitored.

Class Attributes:
  • author : Luis Majano
  •  
    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.
    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.
    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])
         Sets an object in the storage.

    Method Detail

    clear

    public any clear(any objectKey)

    Clears an object from the storage

    Parameters:
    objectKey - The object key to clear

    clearAll

    public void clearAll()

    Clear all the elements in the store


    expireObject

    public void expireObject(any objectKey)

    Expire an object

    Parameters:
    objectKey - The key to expire

    flush

    public void flush()

    Flush the store to a permanent storage


    get

    public any get(any objectKey)

    Get an object from the store with metadata tracking

    Parameters:
    objectKey - The key to retrieve

    getIndexer

    public any getIndexer()

    Get the store's pool metadata indexer structure

    Returns:
    coldbox.system.cache.store.indexers.MetadataIndexer

    getKeys

    public any getKeys()

    Get all the store's object keys array

    Returns:
    array

    getQuiet

    public any getQuiet(any objectKey)

    Get an object from cache with no metadata tracking

    Parameters:
    objectKey - The key to retrieve

    getSize

    public any getSize()

    Get the size of the store


    isExpired

    public any isExpired(any objectKey)

    Expire check

    Parameters:
    objectKey - The key to check
    Returns:
    boolean

    lookup

    public any lookup(any objectKey)

    Check if an object is in the store

    Parameters:
    objectKey - The key to lookup
    Returns:
    boolean

    reap

    public void reap()

    Reap the storage


    set

    public void set(any objectKey, any object, [any timeout], [any lastAccessTimeout], [any extras])

    Sets an object in the storage

    Parameters:
    objectKey - The object key
    object - The object to save
    timeout - Timeout in minutes
    lastAccessTimeout - Idle Timeout in minutes
    extras - A map of extra name-value pairs to store alongside the object