Package org.apache.avro.generic
Class GenericData.Array<T>
java.lang.Object
java.util.AbstractCollection<T>
java.util.AbstractList<T>
org.apache.avro.generic.GenericData.AbstractArray<T>
org.apache.avro.generic.GenericData.Array<T>
- All Implemented Interfaces:
Comparable<GenericArray<T>>,Iterable<T>,Collection<T>,List<T>,GenericArray<T>,GenericContainer
- Enclosing class:
GenericData
Default implementation of an array.
-
Field Summary
Fields inherited from class org.apache.avro.generic.GenericData.AbstractArray
sizeFields inherited from class java.util.AbstractList
modCount -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidclear()get(int i) peek()The current content of the location whereList.add(Object)would next store an element, if any.voidprune()clean up reusable objects from array (if reset didn't already)remove(int i) protected voidswap(int index1, int index2) Methods inherited from class org.apache.avro.generic.GenericData.AbstractArray
compareTo, equals, getSchema, hashCode, iterator, reset, reverse, sizeMethods inherited from class java.util.AbstractList
add, addAll, indexOf, lastIndexOf, listIterator, listIterator, removeRange, subListMethods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface java.util.List
add, addAll, addAll, contains, containsAll, indexOf, isEmpty, lastIndexOf, listIterator, listIterator, remove, removeAll, replaceAll, retainAll, sort, spliterator, subList, toArray, toArray
-
Constructor Details
-
Array
-
Array
-
-
Method Details
-
clear
public void clear()- Specified by:
clearin interfaceCollection<T>- Specified by:
clearin interfaceList<T>- Overrides:
clearin classAbstractList<T>
-
prune
public void prune()Description copied from interface:GenericArrayclean up reusable objects from array (if reset didn't already) -
get
-
add
-
set
-
remove
-
peek
Description copied from interface:GenericArrayThe current content of the location whereList.add(Object)would next store an element, if any. This permits reuse of arrays and their elements without allocating new objects. -
swap
protected void swap(int index1, int index2) - Specified by:
swapin classGenericData.AbstractArray<T>
-