Interface CacheService


  • @Deprecated
    public interface CacheService
    Deprecated.
    This interface is not used and will be removed in future.
    Defines the caching service interface.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static int CACHE_SIZE
      Deprecated.
      The default size of a cache.
      static int DEFAULT
      Deprecated.
      Indicates to create a default cache.
      static int IN_MEMORY
      Deprecated.
      Indicates to cache data in memory only.
      static int PERSISTENCE_ON_DISK
      Deprecated.
      Indicates to cache data on disk.
    • Method Summary

      All Methods Instance Methods Abstract Methods Deprecated Methods 
      Modifier and Type Method Description
      void addElement​(int cacheID, java.lang.Object key, java.lang.Object element)
      Deprecated.
      Adds the specified element to the selected cache.
      void clearAllCaches()
      Deprecated.
      Clears all the caches.
      void clearCache​(int cacheID)
      Deprecated.
      Clears the specified cache.
      int createCache()
      Deprecated.
      Creates a default cache.
      int createCache​(int type)
      Deprecated.
      Creates a cache of a given type.
      int createCache​(int type, int size)
      Deprecated.
      Creates a cache of a given type.
      java.lang.Object getElement​(int cacheID, java.lang.Object key)
      Deprecated.
      Adds the specified element to the selected cache.
      void removeCache​(int cacheID)
      Deprecated.
      Removes the cache corresponding to the passed id.
      void setCacheEntries​(int cacheID, int entries)
      Deprecated.
      Resets the number of items in memory of the cache, when a new cache is created or deleted.
      void shutDown()
      Deprecated.
      Shuts the cache down.
    • Field Detail

      • DEFAULT

        static final int DEFAULT
        Deprecated.
        Indicates to create a default cache.
        See Also:
        Constant Field Values
      • PERSISTENCE_ON_DISK

        static final int PERSISTENCE_ON_DISK
        Deprecated.
        Indicates to cache data on disk.
        See Also:
        Constant Field Values
      • IN_MEMORY

        static final int IN_MEMORY
        Deprecated.
        Indicates to cache data in memory only.
        See Also:
        Constant Field Values
      • CACHE_SIZE

        static final int CACHE_SIZE
        Deprecated.
        The default size of a cache.
        See Also:
        Constant Field Values
    • Method Detail

      • createCache

        int createCache()
        Deprecated.
        Creates a default cache.
        Returns:
        See above.
      • createCache

        int createCache​(int type,
                        int size)
        Deprecated.
        Creates a cache of a given type.
        Parameters:
        type - The type of cache to create.
        size - The size of the cache.
        Returns:
        See above.
      • createCache

        int createCache​(int type)
        Deprecated.
        Creates a cache of a given type.
        Parameters:
        type - The type of cache to create.
        Returns:
        See above.
      • removeCache

        void removeCache​(int cacheID)
        Deprecated.
        Removes the cache corresponding to the passed id.
        Parameters:
        cacheID - The id of the cache.
      • addElement

        void addElement​(int cacheID,
                        java.lang.Object key,
                        java.lang.Object element)
        Deprecated.
        Adds the specified element to the selected cache.
        Parameters:
        cacheID - The id of the cache.
        key - The key corresponding to the element to add.
        element - The element to add.
      • getElement

        java.lang.Object getElement​(int cacheID,
                                    java.lang.Object key)
        Deprecated.
        Adds the specified element to the selected cache.
        Parameters:
        cacheID - The id of the cache.
        key - The key corresponding to the element to add.
        Returns:
        See above.
      • clearCache

        void clearCache​(int cacheID)
        Deprecated.
        Clears the specified cache.
        Parameters:
        cacheID - The id of the cache to clear.
      • setCacheEntries

        void setCacheEntries​(int cacheID,
                             int entries)
        Deprecated.
        Resets the number of items in memory of the cache, when a new cache is created or deleted.
        Parameters:
        cacheID - The id of the cache.
        entries - The number of entries.
      • clearAllCaches

        void clearAllCaches()
        Deprecated.
        Clears all the caches.
      • shutDown

        void shutDown()
        Deprecated.
        Shuts the cache down.