Class YLongList

java.lang.Object
de.hybris.platform.util.collections.fast.YLongList

public class YLongList extends Object
List that can hold long primitives.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Creates an empty list.
    YLongList(int initalCapacity)
    Creates an empty list with preallocated initial space for elements.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(long value)
    Add element to the list.
    long
    get(int offset)
    Get element at given offset.
    int
    Returns number of elements in the list.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • YLongList

      public YLongList()
      Creates an empty list.
    • YLongList

      public YLongList(int initalCapacity)
      Creates an empty list with preallocated initial space for elements.
      Parameters:
      initalCapacity - initial capacity of the list
  • Method Details

    • size

      public int size()
      Returns number of elements in the list.
      Returns:
      number of elements in the list
    • get

      public long get(int offset)
      Get element at given offset.
      Parameters:
      offset - given offset
      Returns:
      element at given offset
      Throws:
      IndexOutOfBoundsException - when offset is out of bound
    • add

      public void add(long value)
      Add element to the list.
      Parameters:
      value - value to be add at the end of the list