Klasse ByteArrayList

Alle implementierten Schnittstellen:
Iterable<Byte>, Collection<Byte>, List<Byte>, RandomAccess, ByteCollection, ByteIterable, ByteStack, ByteList, IByteArray, IArray, ISizeProvider, ITrimmable

public class ByteArrayList extends AbstractByteList implements IByteArray, ByteStack
A Type-Specific Array-based implementation of list that is written to reduce (un)boxing

This implementation is optimized to improve how data is processed with interfaces like IByteArray, ByteStack and with optimized functions that use type-specific implementations for primitives and optimized logic for bulkactions.

  • Konstruktordetails

    • ByteArrayList

      public ByteArrayList()
      Creates a new ArrayList with a Empty array.
    • ByteArrayList

      public ByteArrayList(int size)
      Creates a new ArrayList with the specific requested size
      Parameter:
      size - the minimum initial size of the Backing array
    • ByteArrayList

      @Deprecated public ByteArrayList(Collection<? extends Byte> c)
      Veraltet.
      Creates a new ArrayList a copy with the contents of the Collection.
      Parameter:
      c - the elements that should be added into the list
    • ByteArrayList

      public ByteArrayList(ByteCollection c)
      Creates a new ArrayList a copy with the contents of the Collection.
      Parameter:
      c - the elements that should be added into the list
    • ByteArrayList

      public ByteArrayList(ByteList l)
      Creates a new ArrayList a copy with the contents of the List.
      Parameter:
      l - the elements that should be added into the list
    • ByteArrayList

      public ByteArrayList(byte... a)
      Creates a new ArrayList with a Copy of the array
      Parameter:
      a - the array that should be copied
    • ByteArrayList

      public ByteArrayList(byte[] a, int length)
      Creates a new ArrayList with a Copy of the array with a custom length
      Parameter:
      a - the array that should be copied
      length - the desired length that should be copied
    • ByteArrayList

      public ByteArrayList(byte[] a, int offset, int length)
      Creates a new ArrayList with a Copy of the array with in the custom range.
      Parameter:
      a - the array that should be copied
      offset - the starting offset of where the array should be copied from
      length - the desired length that should be copied
      Löst aus:
      IllegalStateException - if offset is smaller then 0
      IllegalStateException - if the offset + length exceeds the array length
  • Methodendetails

    • wrap

      public static ByteArrayList wrap(byte... a)
      Creates a wrapped arraylist that uses the array as backing array
      Parameter:
      a - elements that should be wrapped
      Gibt zurück:
      a Wrapped list using the input array
    • wrap

      public static ByteArrayList wrap(byte[] a, int length)
      Creates a wrapped arraylist that uses the array as backing array and a custom fill size
      Parameter:
      a - elements that should be wrapped
      length - the size of the elements within the array
      Gibt zurück:
      a Wrapped list using the input array
    • add

      public boolean add(byte e)
      Appends the specified element to the end of this list.
      Angegeben von:
      add in Schnittstelle ByteCollection
      Angegeben von:
      add in Schnittstelle ByteList
      Setzt außer Kraft:
      add in Klasse AbstractByteList
      Parameter:
      e - element to be appended to this list
      Gibt zurück:
      true (as specified by Collection.add(E))
      Siehe auch:
    • push

      public void push(byte e)
      Appends the specified element to the end of this Stack.
      Angegeben von:
      push in Schnittstelle ByteStack
      Parameter:
      e - element to be appended to this Stack
      Siehe auch:
    • add

      public void add(int index, byte e)
      Appends the specified element to the index of the list
      Angegeben von:
      add in Schnittstelle ByteList
      Parameter:
      index - the index where to append the element to
      e - the element to append to the list
      Löst aus:
      IndexOutOfBoundsException - if index is outside of the lists range
      Siehe auch:
    • addAll

      @Deprecated public boolean addAll(int index, Collection<? extends Byte> c)
      Veraltet.
      Appends the specified elements to the index of the list. This function may delegate to more appropriate function if necessary
      Angegeben von:
      addAll in Schnittstelle List<Byte>
      Parameter:
      index - the index where to append the elements to
      c - the elements to append to the list
      Löst aus:
      IndexOutOfBoundsException - if index is outside of the lists range
      NullPointerException - if collection contains a null element
    • addAll

      public boolean addAll(int index, ByteCollection c)
      Appends the specified elements to the index of the list. This function may delegate to more appropriate function if necessary
      Angegeben von:
      addAll in Schnittstelle ByteList
      Parameter:
      index - the index where to append the elements to
      c - the elements to append to the list
      Gibt zurück:
      true if the list was modified
      Löst aus:
      IndexOutOfBoundsException - if index is outside of the lists range
      Siehe auch:
    • addAll

      public boolean addAll(int index, ByteList c)
      Appends the specified elements to the index of the list.
      Angegeben von:
      addAll in Schnittstelle ByteList
      Parameter:
      index - the index where to append the elements to
      c - the elements to append to the list
      Gibt zurück:
      true if the list was modified
      Löst aus:
      IndexOutOfBoundsException - if index is outside of the lists range
    • addAll

      public boolean addAll(byte[] e, int offset, int length)
      Beschreibung aus Schnittstelle kopiert: ByteCollection
      A Type-Specific Array based addAll method to reduce the amount of Wrapping
      Angegeben von:
      addAll in Schnittstelle ByteCollection
      Parameter:
      e - the elements that should be added
      offset - where to start within the array
      length - how many elements of the array should be added
      Gibt zurück:
      if the collection was modified
    • addElements

      public void addElements(int from, byte[] a, int offset, int length)
      Appends the specified array elements to the index of the list.
      Angegeben von:
      addElements in Schnittstelle ByteList
      Parameter:
      from - the index where to append the elements to
      a - the elements to append to the list
      offset - where to start ino the array
      length - the amount of elements to insert
      Löst aus:
      IndexOutOfBoundsException - if index is outside of the lists range
    • getElements

      public byte[] getElements(int from, byte[] a, int offset, int length)
      A function to fast fetch elements from the list
      Angegeben von:
      getElements in Schnittstelle ByteList
      Parameter:
      from - index where the list should be fetching elements from
      a - the array where the values should be inserted to
      offset - the startIndex of where the array should be written to
      length - the number of elements the values should be fetched from
      Gibt zurück:
      the inputArray
      Löst aus:
      NullPointerException - if the array is null
      IndexOutOfBoundsException - if from is outside of the lists range
      IllegalStateException - if offset or length are smaller then 0 or exceed the array length
    • removeElements

      public void removeElements(int from, int to)
      a function to fast remove elements from the list.
      Angegeben von:
      removeElements in Schnittstelle ByteList
      Parameter:
      from - the start index of where the elements should be removed from (inclusive)
      to - the end index of where the elements should be removed to (exclusive)
    • extractElements

      public byte[] extractElements(int from, int to)
      A function to fast extract elements out of the list, this removes the elements that were fetched.
      Angegeben von:
      extractElements in Schnittstelle ByteList
      Parameter:
      from - the start index of where the elements should be fetched from (inclusive)
      to - the end index of where the elements should be fetched to (exclusive)
      Gibt zurück:
      a array of the elements that were fetched
    • fillBuffer

      public void fillBuffer(ByteBuffer buffer)
      Beschreibung aus Schnittstelle kopiert: ByteList
      Helper function that allows to fastFill a buffer reducing the duplication requirement
      Angegeben von:
      fillBuffer in Schnittstelle ByteList
      Parameter:
      buffer - where the data should be stored in.
    • contains

      @Deprecated public boolean contains(Object o)
      Veraltet.
      A function to find if the Element is present in this list.
      Angegeben von:
      contains in Schnittstelle ByteCollection
      Angegeben von:
      contains in Schnittstelle ByteList
      Angegeben von:
      contains in Schnittstelle Collection<Byte>
      Angegeben von:
      contains in Schnittstelle List<Byte>
      Setzt außer Kraft:
      contains in Klasse AbstractByteCollection
      Parameter:
      o - the element that is searched for
      Gibt zurück:
      if the element was found.
    • indexOf

      @Deprecated public int indexOf(Object o)
      Veraltet.
      A function to find the index of a given element
      Angegeben von:
      indexOf in Schnittstelle ByteList
      Angegeben von:
      indexOf in Schnittstelle List<Byte>
      Setzt außer Kraft:
      indexOf in Klasse AbstractByteList
      Parameter:
      o - the element that is searched for
      Gibt zurück:
      the index of the element if found. (if not found then -1)
    • lastIndexOf

      @Deprecated public int lastIndexOf(Object o)
      Veraltet.
      A function to find the last index of a given element
      Angegeben von:
      lastIndexOf in Schnittstelle ByteList
      Angegeben von:
      lastIndexOf in Schnittstelle List<Byte>
      Setzt außer Kraft:
      lastIndexOf in Klasse AbstractByteList
      Parameter:
      o - the element that is searched for
      Gibt zurück:
      the last index of the element if found. (if not found then -1)
    • contains

      public boolean contains(byte e)
      A Type Specific implementation of the Collection#contains function.
      Angegeben von:
      contains in Schnittstelle ByteCollection
      Setzt außer Kraft:
      contains in Klasse AbstractByteCollection
      Parameter:
      e - the element that is searched for.
      Gibt zurück:
      if the element was found
    • indexOf

      public int indexOf(byte e)
      A Type-Specific function to find the index of a given element
      Angegeben von:
      indexOf in Schnittstelle ByteList
      Setzt außer Kraft:
      indexOf in Klasse AbstractByteList
      Parameter:
      e - the element that is searched for
      Gibt zurück:
      the index of the element if found. (if not found then -1)
    • lastIndexOf

      public int lastIndexOf(byte e)
      A Type-Specific function to find the last index of a given element
      Angegeben von:
      lastIndexOf in Schnittstelle ByteList
      Setzt außer Kraft:
      lastIndexOf in Klasse AbstractByteList
      Parameter:
      e - the element that is searched for
      Gibt zurück:
      the last index of the element if found. (if not found then -1)
    • sort

      public void sort(ByteComparator c)
      Sorts the elements specified by the Natural order either by using the Comparator or the elements
      Angegeben von:
      sort in Schnittstelle ByteList
      Parameter:
      c - the sorter of the elements, can be null
      Siehe auch:
    • unstableSort

      public void unstableSort(ByteComparator c)
      Sorts the elements specified by the Natural order either by using the Comparator or the elements using a unstable sort
      Angegeben von:
      unstableSort in Schnittstelle ByteList
      Parameter:
      c - the sorter of the elements, can be null
      Siehe auch:
    • getByte

      public byte getByte(int index)
      A Type-Specific get function to reduce (un)boxing
      Angegeben von:
      getByte in Schnittstelle ByteList
      Parameter:
      index - the index of the element to fetch
      Gibt zurück:
      the value of the requested index
      Löst aus:
      IndexOutOfBoundsException - if the index is out of range
      Siehe auch:
    • peek

      public byte peek(int index)
      Provides the Selected Object from the stack. Top to bottom
      Angegeben von:
      peek in Schnittstelle ByteStack
      Parameter:
      index - of the element that should be provided
      Gibt zurück:
      the element that was requested
      Löst aus:
      ArrayIndexOutOfBoundsException - if the index is out of bounds
      Siehe auch:
    • elements

      public byte[] elements()
      Provides the Underlying Array in the Implementation
      Angegeben von:
      elements in Schnittstelle IByteArray
      Gibt zurück:
      underlying Array
      Löst aus:
      ClassCastException - if the return type does not match the underlying array. (Only for Object Implementations)
    • forEach

      public void forEach(ByteConsumer action)
      A Type Specific foreach function that reduces (un)boxing
      Angegeben von:
      forEach in Schnittstelle ByteIterable
      Parameter:
      action - The action to be performed for each element
      Löst aus:
      NullPointerException - if the specified action is null
      Siehe auch:
      ImplSpec:

      The default implementation behaves as if:

      
       	for(int i = 0;i<size;i++)
      		action.accept(data[i]);
       
    • forEach

      public <E> void forEach(E input, ObjectByteConsumer<E> action)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce Lambda usage and allow for more method references, since these are faster/cleaner.
      Angegeben von:
      forEach in Schnittstelle ByteIterable
      Typparameter:
      E - the generic type of the Object
      Parameter:
      input - the object that should be included
      action - The action to be performed for each element
    • matchesAny

      public boolean matchesAny(BytePredicate filter)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce stream usage that allows to filter for any matches.
      Angegeben von:
      matchesAny in Schnittstelle ByteIterable
      Parameter:
      filter - that should be applied
      Gibt zurück:
      true if any matches were found
    • matchesNone

      public boolean matchesNone(BytePredicate filter)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce stream usage that allows to filter for no matches.
      Angegeben von:
      matchesNone in Schnittstelle ByteIterable
      Parameter:
      filter - that should be applied
      Gibt zurück:
      true if no matches were found
    • matchesAll

      public boolean matchesAll(BytePredicate filter)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce stream usage that allows to filter for all matches.
      Angegeben von:
      matchesAll in Schnittstelle ByteIterable
      Parameter:
      filter - that should be applied
      Gibt zurück:
      true if all matches.
    • findFirst

      public byte findFirst(BytePredicate filter)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce stream usage that allows to filter for the first match.
      Angegeben von:
      findFirst in Schnittstelle ByteIterable
      Parameter:
      filter - that should be applied
      Gibt zurück:
      the found value or the null equivalent variant.
    • reduce

      public byte reduce(byte identity, ByteByteUnaryOperator operator)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Performs a reduction on the elements of this Iterable
      Angegeben von:
      reduce in Schnittstelle ByteIterable
      Parameter:
      identity - the start value
      operator - the operation that should be applied
      Gibt zurück:
      the reduction result, returns identity if nothing was found
    • reduce

      public byte reduce(ByteByteUnaryOperator operator)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Performs a reduction on the elements of this Iterable
      Angegeben von:
      reduce in Schnittstelle ByteIterable
      Parameter:
      operator - the operation that should be applied
      Gibt zurück:
      the reduction result, returns null value if nothing was found
    • count

      public int count(BytePredicate filter)
      Beschreibung aus Schnittstelle kopiert: ByteIterable
      Helper function to reduce stream usage that allows to count the valid elements.
      Angegeben von:
      count in Schnittstelle ByteIterable
      Parameter:
      filter - that should be applied
      Gibt zurück:
      the amount of Valid Elements
    • set

      public byte set(int index, byte e)
      A Type-Specific set function to reduce (un)boxing
      Angegeben von:
      set in Schnittstelle ByteList
      Parameter:
      index - the index of the element to set
      e - the value that should be set
      Gibt zurück:
      the previous element
      Löst aus:
      IndexOutOfBoundsException - if the index is out of range
      Siehe auch:
    • replaceAll

      @Deprecated public void replaceAll(UnaryOperator<Byte> o)
      Veraltet.
      A function to replace all values in the list
      Angegeben von:
      replaceAll in Schnittstelle ByteList
      Angegeben von:
      replaceAll in Schnittstelle List<Byte>
      Parameter:
      o - the action to replace the values
      Löst aus:
      NullPointerException - if o is null
    • replaceBytes

      public void replaceBytes(IntUnaryOperator o)
      A Type-Specific replace function to reduce (un)boxing
      Angegeben von:
      replaceBytes in Schnittstelle ByteList
      Parameter:
      o - the action to replace the values
      Löst aus:
      NullPointerException - if o is null
    • removeByte

      public byte removeByte(int index)
      A Type-Specific remove function to reduce (un)boxing
      Angegeben von:
      removeByte in Schnittstelle ByteList
      Parameter:
      index - the index of the element to fetch
      Gibt zurück:
      the value of the requested index
      Löst aus:
      IndexOutOfBoundsException - if the index is out of range
      Siehe auch:
    • swapRemove

      public byte swapRemove(int index)
      Beschreibung aus Schnittstelle kopiert: ByteList
      A Highly Optimized remove function that removes the desired element. But instead of shifting the elements to the left it moves the last element to the removed space.
      Angegeben von:
      swapRemove in Schnittstelle ByteList
      Parameter:
      index - the index of the element to be removed
      Gibt zurück:
      the element previously at the specified position
    • remByte

      public boolean remByte(byte type)
      A Type-Specific implementation of remove. This implementation iterates over the elements until it finds the element that is searched for or it runs out of elements. It stops after finding the first element
      Angegeben von:
      remByte in Schnittstelle ByteCollection
      Setzt außer Kraft:
      remByte in Klasse AbstractByteCollection
      Parameter:
      type - the element that is searched for
      Gibt zurück:
      true if the element was found and removed.
      Siehe auch:
    • pop

      public byte pop()
      A Type-Specific pop function to reduce (un)boxing
      Angegeben von:
      pop in Schnittstelle ByteStack
      Gibt zurück:
      the value of the requested index
      Löst aus:
      IndexOutOfBoundsException - if the index is out of range
      Siehe auch:
    • removeAll

      @Deprecated public boolean removeAll(Collection<?> c)
      Veraltet.
      A function to remove all elements that were provided in the other collection This function might delegate to a more appropriate function if necessary
      Angegeben von:
      removeAll in Schnittstelle Collection<Byte>
      Angegeben von:
      removeAll in Schnittstelle List<Byte>
      Setzt außer Kraft:
      removeAll in Klasse AbstractCollection<Byte>
      Parameter:
      c - the elements that should be removed
      Gibt zurück:
      true if the collection was modified
      Löst aus:
      NullPointerException - if the collection is null
    • retainAll

      @Deprecated public boolean retainAll(Collection<?> c)
      Veraltet.
      A function to retain all elements that were provided in the other collection This function might delegate to a more appropriate function if necessary
      Angegeben von:
      retainAll in Schnittstelle Collection<Byte>
      Angegeben von:
      retainAll in Schnittstelle List<Byte>
      Setzt außer Kraft:
      retainAll in Klasse AbstractCollection<Byte>
      Parameter:
      c - the elements that should be kept. If empty, ByteArrayList#clear is called.
      Gibt zurück:
      true if the collection was modified
      Löst aus:
      NullPointerException - if the collection is null
    • removeIf

      @Deprecated public boolean removeIf(Predicate<? super Byte> filter)
      Veraltet.
      A optimized List#removeIf(Predicate) that more quickly removes elements from the list then the ArrayList implementation
      Angegeben von:
      removeIf in Schnittstelle ByteCollection
      Angegeben von:
      removeIf in Schnittstelle Collection<Byte>
      Parameter:
      filter - the filter to remove elements
      Gibt zurück:
      true if the list was modified
    • removeAll

      public boolean removeAll(ByteCollection c)
      A function to remove all elements that were provided in the other collection
      Angegeben von:
      removeAll in Schnittstelle ByteCollection
      Setzt außer Kraft:
      removeAll in Klasse AbstractByteCollection
      Parameter:
      c - the elements that should be removed
      Gibt zurück:
      true if the collection was modified
      Löst aus:
      NullPointerException - if the collection is null
      Siehe auch:
    • removeAll

      public boolean removeAll(ByteCollection c, ByteConsumer r)
      Beschreibung aus Schnittstelle kopiert: ByteCollection
      A Type-Specific removeAll function that reduces (un)boxing. It also notifies the remover of which exact element is going to be removed.
      Angegeben von:
      removeAll in Schnittstelle ByteCollection
      Setzt außer Kraft:
      removeAll in Klasse AbstractByteCollection
      Parameter:
      c - the collection of elements that should be removed
      r - elements that got removed
      Gibt zurück:
      true if any element was removed
      Siehe auch:
    • retainAll

      public boolean retainAll(ByteCollection c)
      A function to retain all elements that were provided in the other collection This function might delegate to a more appropriate function if necessary
      Angegeben von:
      retainAll in Schnittstelle ByteCollection
      Setzt außer Kraft:
      retainAll in Klasse AbstractByteCollection
      Parameter:
      c - the elements that should be kept. If empty, ByteArrayList#clear is called.
      Gibt zurück:
      true if the collection was modified
      Löst aus:
      NullPointerException - if the collection is null
      Siehe auch:
    • retainAll

      public boolean retainAll(ByteCollection c, ByteConsumer r)
      Beschreibung aus Schnittstelle kopiert: ByteCollection
      A Type-Specific retainAll function that reduces (un)boxing. It also notifies the remover of which exact element is going to be removed.
      Angegeben von:
      retainAll in Schnittstelle ByteCollection
      Setzt außer Kraft:
      retainAll in Klasse AbstractByteCollection
      Parameter:
      c - the collection of elements that should be kept
      r - elements that got removed
      Gibt zurück:
      true if any element was removed
      Siehe auch:
    • remIf

      public boolean remIf(IntPredicate filter)
      A optimized List#removeIf(Predicate) that more quickly removes elements from the list then the ArrayList implementation
      Angegeben von:
      remIf in Schnittstelle ByteCollection
      Parameter:
      filter - the filter to remove elements
      Gibt zurück:
      true if the list was modified
      Siehe auch:
    • toArray

      @Deprecated public Object[] toArray()
      Veraltet.
      A toArray implementation that ensures the Array itself is a Object.
      Angegeben von:
      toArray in Schnittstelle Collection<Byte>
      Angegeben von:
      toArray in Schnittstelle List<Byte>
      Setzt außer Kraft:
      toArray in Klasse AbstractCollection<Byte>
      Gibt zurück:
      a Array of the elements in the list
    • toArray

      @Deprecated public <E> E[] toArray(E[] a)
      Veraltet.
      A toArray implementation that ensures the Array itself is a Object.
      Angegeben von:
      toArray in Schnittstelle Collection<Byte>
      Angegeben von:
      toArray in Schnittstelle List<Byte>
      Setzt außer Kraft:
      toArray in Klasse AbstractCollection<Byte>
      Parameter:
      a - original array. If null a Object array with the right size is created. If to small the Array of the same type is created with the right size
      Gibt zurück:
      a Array of the elements in the list
    • toByteArray

      public byte[] toByteArray(byte[] a)
      Beschreibung aus Klasse kopiert: AbstractByteCollection
      A Type-Specific implementation of toArray. This implementation iterates over all elements and unwraps them into primitive type.
      Angegeben von:
      toByteArray in Schnittstelle ByteCollection
      Angegeben von:
      toByteArray in Schnittstelle ByteStack
      Setzt außer Kraft:
      toByteArray in Klasse AbstractByteCollection
      Parameter:
      a - array that the elements should be injected to. If null or to small a new array with the right size is created
      Gibt zurück:
      an array containing all of the elements in this collection
      Siehe auch:
    • size

      public int size()
      A function to return the size of the list
      Angegeben von:
      size in Schnittstelle ByteStack
      Angegeben von:
      size in Schnittstelle Collection<Byte>
      Angegeben von:
      size in Schnittstelle ISizeProvider
      Angegeben von:
      size in Schnittstelle List<Byte>
      Angegeben von:
      size in Klasse AbstractCollection<Byte>
      Gibt zurück:
      the size of elements in the list
    • size

      public void size(int size)
      A function to ensure the elements are within the requested size. If smaller then the stored elements they get removed as needed. If bigger it is ensured that enough room is provided depending on the implementation
      Angegeben von:
      size in Schnittstelle ByteList
      Setzt außer Kraft:
      size in Klasse AbstractByteList
      Parameter:
      size - the requested amount of elements/room for elements
    • clear

      public void clear()
      A function to clear all elements in the list.
      Angegeben von:
      clear in Schnittstelle ByteStack
      Angegeben von:
      clear in Schnittstelle Collection<Byte>
      Angegeben von:
      clear in Schnittstelle List<Byte>
      Setzt außer Kraft:
      clear in Klasse AbstractCollection<Byte>
    • trim

      public boolean trim(int size)
      Trims the original collection down to the size of the current elements or the requested size depending which is bigger
      Angegeben von:
      trim in Schnittstelle ITrimmable
      Parameter:
      size - the requested trim size.
      Gibt zurück:
      if the internal array has been trimmed.
    • clearAndTrim

      public void clearAndTrim(int size)
      Trims the collection down to the requested size and clears all elements while doing so
      Angegeben von:
      clearAndTrim in Schnittstelle ITrimmable
      Parameter:
      size - the amount of elements that should be allowed
      Note:
      this will enforce minimum size of the collection itself
    • ensureCapacity

      public void ensureCapacity(int size)
      Increases the capacity of this implementation instance, if necessary, to ensure that it can hold at least the number of elements specified by the minimum capacity argument.
      Angegeben von:
      ensureCapacity in Schnittstelle IArray
      Parameter:
      size - the desired minimum capacity
    • copy

      public ByteArrayList copy()
      Beschreibung aus Schnittstelle kopiert: ByteCollection
      A Function that does a shallow clone of the Collection itself. This function is more optimized then a copy constructor since the Collection does not have to be unsorted/resorted. It can be compared to Cloneable but with less exception risk
      Angegeben von:
      copy in Schnittstelle ByteCollection
      Angegeben von:
      copy in Schnittstelle ByteList
      Setzt außer Kraft:
      copy in Klasse AbstractByteList
      Gibt zurück:
      a Shallow Copy of the collection
    • primitiveStream

      public IntStream primitiveStream()
      Returns a Java-Type-Specific Stream to reduce boxing/unboxing.
      Angegeben von:
      primitiveStream in Schnittstelle ByteCollection
      Gibt zurück:
      a Stream of the closest java type
      Note:
      characteristics are ordered, sized, subsized
    • spliterator

      public ByteSplititerator spliterator()
      A Type Specific Type Splititerator to reduce boxing/unboxing
      Angegeben von:
      spliterator in Schnittstelle ByteCollection
      Angegeben von:
      spliterator in Schnittstelle ByteIterable
      Angegeben von:
      spliterator in Schnittstelle ByteList
      Angegeben von:
      spliterator in Schnittstelle Collection<Byte>
      Angegeben von:
      spliterator in Schnittstelle Iterable<Byte>
      Angegeben von:
      spliterator in Schnittstelle List<Byte>
      Gibt zurück:
      type specific splititerator
      Note:
      characteristics are ordered, sized, subsized