Class TupleCache<T>

java.lang.Object
com.semedy.reasoner.utils.TupleCache<T>

public class TupleCache<T> extends Object
A cache for objects
It consists of n units which may be released by cache manager.
Author:
angele
  • Constructor Details

    • TupleCache

      public TupleCache(int maxNumber)
    • TupleCache

      public TupleCache()
  • Method Details

    • put

      public void put(Tuple t, T list)
      put new tuple
      Parameters:
      t - , tuple t
      code - , code to add
    • clear

      public void clear()
      clear all
    • get

      public T get(Tuple t)
      get term list for this tuple
      Parameters:
      t - , tuple
      Returns:
    • isEmpty

      public boolean isEmpty()
      are any terms cached?
      Returns:
    • remove

      public boolean remove(Tuple t)
      remove a term with code
      Parameters:
      t - , tuple
      Returns:
    • size

      public int size()
      number of terms cached
      Returns: