Class LRUHashList

  • All Implemented Interfaces:
    java.io.Serializable

    public class LRUHashList
    extends java.lang.Object
    implements java.io.Serializable
    A simple HashList wrapper where entries expire on a LRU basis.
    Since:
    MicroStrategy Web 8.0.2
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      LRUHashList​(int capacity)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()
      Clear the LRUHashList.
      java.lang.Object get​(java.lang.Object key)
      Returns the object contained with the specified key in the collection.
      void load​(java.lang.String value)
      Load the string representation of the LRUHashList.
      void put​(java.lang.Object key, java.lang.Object value)
      Adds or replaces the object, with the specified key, into the collection.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • LRUHashList

        public LRUHashList​(int capacity)
        Constructor.
        Parameters:
        capacity - The size of LRUHashList. LRU algorithm is used for replacement if the capacity is reached.
    • Method Detail

      • clear

        public void clear()
        Clear the LRUHashList.
      • get

        public java.lang.Object get​(java.lang.Object key)
        Returns the object contained with the specified key in the collection.
        Parameters:
        key - The key of the item in the collection to get.
      • put

        public void put​(java.lang.Object key,
                        java.lang.Object value)
        Adds or replaces the object, with the specified key, into the collection.
        Parameters:
        key - The key used to identify the object in the collection.
        value - The object to add to the collection.
      • load

        public void load​(java.lang.String value)
        Load the string representation of the LRUHashList. The string representation of the LRUHashList is a ";" separated name : value pairs. Such as "name:value;name2:value2;". If this method if used, the key and value in the LRUHashList are all strings.
        Parameters:
        value - The string representation of the LRUHashList.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
        Returns:
        Returns the string representation of the LRUHashList.