Class HistoricalDataCacheNullImpl

java.lang.Object
com.espertech.esper.common.internal.epl.historical.datacache.HistoricalDataCacheNullImpl
All Implemented Interfaces:
HistoricalDataCache

public class HistoricalDataCacheNullImpl extends Object implements HistoricalDataCache
Null implementation for a data cache that doesn't ever hit.
  • Constructor Details

    • HistoricalDataCacheNullImpl

      public HistoricalDataCacheNullImpl()
  • Method Details

    • getCached

      public EventTable[] getCached(Object methodParams)
      Description copied from interface: HistoricalDataCache
      Ask the cache if the keyed value is cached, returning a list or rows if the key is in the cache, or returning null to indicate no such key cached. Zero rows may also be cached.
      Specified by:
      getCached in interface HistoricalDataCache
      Parameters:
      methodParams - is the keys to look up in the cache
      Returns:
      a list of rows that can be empty is the key was found in the cache, or null if the key is not found in the cache
    • put

      public void put(Object methodParams, EventTable[] rows)
      Description copied from interface: HistoricalDataCache
      Puts into the cache a key and a list of rows, or an empty list if zero rows.

      The put method is designed to be called when the cache does not contain a key as determined by the get method. Implementations typically simply overwrite any keys put into the cache that already existed in the cache.

      Specified by:
      put in interface HistoricalDataCache
      Parameters:
      methodParams - is the keys to the cache entry
      rows - is a number of rows
    • isActive

      public boolean isActive()
      Description copied from interface: HistoricalDataCache
      Returns true if the cache is active and currently caching, or false if the cache is inactive and not currently caching
      Specified by:
      isActive in interface HistoricalDataCache
      Returns:
      true for caching enabled, false for no caching taking place
    • destroy

      public void destroy()
      Specified by:
      destroy in interface HistoricalDataCache