Class StoredListFactory

java.lang.Object
com.j_spaces.kernel.StoredListFactory

public final class StoredListFactory extends Object
StoredListFactory returns a IStoredList implementation, according to the Java version the sources were compiled. This is due to performance profiling conducted on both JDK1.4 and JDK1.5 - Thus, using 1.4 will return IStoredList, and using 1.5 will return SimpleLockStoredList.
Since:
4.1
Version:
1.0
Author:
moran
  • Constructor Details

    • StoredListFactory

      public StoredListFactory()
  • Method Details

    • createList

      public static <T> IStoredList<T> createList(boolean reuseLocks)
      Returns a StoredList instance according to the JVM Version. Equivalent to calling getStoredList(false,false);
      Returns:
      StoredList instance with random and SLHolder-Factory set to false.
    • createConcurrentList

      public static <T> IStoredList<T> createConcurrentList(boolean supportsFifo)
      Creates a concurrent stored list - used for highly concurrent lists.
      Returns:
      IStoredList
    • createConcurrentSegmentedList

      public static <T> IStoredList<T> createConcurrentSegmentedList(boolean supportsFifoPerSegment)
      Creates a concurrent segmented stored list - used for highly concurrent lists.
      Returns:
      IStoredList
    • createConcurrentSegmentedList

      public static <T> IStoredList<T> createConcurrentSegmentedList(boolean supportsFifoPerSegment, int numOfSegments, boolean padded)
      Creates a concurrent segmented stored list - used for highly concurrent lists.
      Returns:
      IStoredList
    • createConcurrentSegmentedList

      public static <T> IStoredList<T> createConcurrentSegmentedList(boolean segmented, boolean supportFifoPerSegment, Object StoredIndexValueInHashmap)
      Creates a segmented stored list - used for highly concurrent lists. this SL supports serving as a EconomyConcurrentHashMap HashEntry for storing an index value
      Returns:
      oncurrentSegmentedStoredListHashmapEntry
    • createStoredList

      public static <T> AbstractStoredList<T> createStoredList(boolean supportsRandomScans, boolean reuseLocks)
      Returns:
      StoredList instance according to the given parameters and JVM Version.
    • createHashList

      public static <T> IStoredList<T> createHashList()
      Create Hashed StoredList
      Returns:
      HashedSimpleLockIStoredList