T
- the generic typepublic class FSArrayList<T extends TOP> extends TOP implements UimaSerializableFSs, CommonArrayFS<T>, SelectViaCopyToArray<T>, List<T>, RandomAccess, Cloneable
An ArrayList type containing Feature Structures, for UIMA
Implementation notes:
Modifier and Type | Field and Description |
---|---|
static String |
_FeatName_fsArray |
static String |
_TypeName |
static int |
type |
static int |
typeIndexID |
_singleton
Modifier | Constructor and Description |
---|---|
protected |
FSArrayList()
Never called.
|
|
FSArrayList(JCas jcas) |
|
FSArrayList(JCas jcas,
int length)
Make a new ArrayList with an initial size .
|
|
FSArrayList(org.apache.uima.cas.impl.TypeImpl type,
org.apache.uima.cas.impl.CASImpl casImpl)
Internal - constructor used by generator
|
Modifier and Type | Method and Description |
---|---|
void |
_init_from_cas_data() |
void |
_save_to_cas_data()
This method is called by the framework before serialization of an instance of this
JCas class.
|
org.apache.uima.cas.impl.FeatureStructureImplC |
_superClone() |
FeatureStructure[] |
_toArrayForSelect() |
void |
add(int index,
T element) |
boolean |
add(T e) |
boolean |
addAll(Collection<? extends T> c) |
boolean |
addAll(int index,
Collection<? extends T> c) |
void |
clear() |
boolean |
contains(Object o) |
boolean |
containsAll(Collection<?> c) |
<E extends FeatureStructure> |
copyFromArray(E[] src,
int srcPos,
int destPos,
int length)
Copy from array.
|
void |
copyFromArray(String[] src,
int srcPos,
int destPos,
int length)
Not supported, will throw UnsupportedOperationException.
|
<E extends FeatureStructure> |
copyToArray(int srcPos,
E[] dest,
int destPos,
int length)
Copy to array.
|
void |
copyToArray(int srcPos,
String[] dest,
int destPos,
int length)
Copies an array of Feature Structures to an Array of Strings.
|
void |
copyValuesFrom(CommonArrayFS v)
Copy values from another array of the same kind
|
static <E extends TOP,F extends FeatureStructure> |
create(JCas jcas,
F[] a)
Convenience - create a FSArrayList from an existing Array.
|
boolean |
equals(Object o)
A feature structure is equal to another feature structure iff it is identical in the underlying
representation.
|
void |
forEach(Consumer<? super T> action) |
T |
get(int i) |
int |
getTypeIndexID() |
int |
hashCode()
Will return a hash code that's consistent with equality, i.e., if two FSs are equal, they will
also return the same hash code.
|
int |
indexOf(Object o) |
boolean |
isEmpty() |
Iterator<T> |
iterator() |
int |
lastIndexOf(Object o) |
ListIterator<T> |
listIterator() |
ListIterator<T> |
listIterator(int index) |
Stream<T> |
parallelStream() |
T |
remove(int index) |
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
boolean |
removeIf(Predicate<? super T> filter) |
void |
replaceAll(UnaryOperator<T> operator) |
boolean |
retainAll(Collection<?> c) |
T |
set(int i,
T v)
updates the i-th value of the FSArrayList.
|
int |
size()
return the size of the array.
|
void |
sort(Comparator<? super T> c) |
Spliterator<T> |
spliterator() |
Stream<T> |
stream() |
List<T> |
subList(int fromIndex,
int toIndex) |
TOP[] |
toArray()
returns TOP[] because can't make array of T
Note: converts to pear trampolines.
|
<U> U[] |
toArray(U[] a) |
String |
toString() |
_createJCasHashMapReserve, _createSearchKey
_copyIntAndRefArraysEqTypesFrom, _copyIntAndRefArraysFrom, _copyIntArrayEqTypesFrom, _getBooleanValueNc, _getBooleanValueNc, _getByteValueNc, _getByteValueNc, _getDoubleValueNc, _getDoubleValueNc, _getFeatFromAdjOffset, _getFeatureValueNc, _getFeatureValueNc, _getFloatValueNc, _getFloatValueNc, _getIntLikeValue, _getIntValueNc, _getIntValueNc, _getLongValueNc, _getLongValueNc, _getRefValueCommon, _getShortValueNc, _getShortValueNc, _getStringValueNc, _getStringValueNc, _getTypeCode, _getTypeImpl, _getView, _id, _inSetSortedIndex, _isJCasHashMapReserve, _isPearTrampoline, _maybeGetBaseForPearFs, _maybeGetBaseForPearFs, _maybeGetPearFs, _maybeGetPearFs, _resetInSetSortedIndex, _setBooleanValueNcNj, _setBooleanValueNcNj, _setBooleanValueNfc, _setByteValueNcNj, _setByteValueNcNj, _setByteValueNfc, _setDoubleValueNcNj, _setDoubleValueNcNj, _setDoubleValueNfc, _setFeatureValueNcNj, _setFeatureValueNcNj, _setFeatureValueNcWj, _setFloatValueNcNj, _setFloatValueNcNj, _setFloatValueNfc, _setInSetSortedIndexed, _setIntLikeValue, _setIntLikeValueNcNj, _setIntValueCJ, _setIntValueNcNj, _setIntValueNcNj, _setIntValueNfc, _setIntValueNfcCJ, _setJCasHashMapReserve, _setLongValueCJ, _setLongValueNcNj, _setLongValueNcNj, _setLongValueNfc, _setLongValueNfcCJ, _setPearTrampoline, _setRefValueCJ, _setRefValueCommon, _setRefValueCommonWj, _setRefValueNfcCJ, _setShortValueNcNj, _setShortValueNcNj, _setShortValueNfc, _setStringValueNcNj, _setStringValueNcWj, _setStringValueNfc, _setTypeImpl, addStringOrPrimitive, addToIndexes, addToIndexes, addToIndexes, clone, compare, getAddress, getBooleanValue, getByteValue, getCAS, getCASImpl, getDoubleValue, getFeatureValue, getFeatureValueAsString, getFloatValue, getIntValue, getLongValue, getLowLevelCas, getShortValue, getStringValue, getType, prettyPrint, prettyPrint, prettyPrint, prettyPrint, prettyPrint, prettyPrint, prettyPrintShort, removeFromIndexes, removeFromIndexes, removeFromIndexes, setBooleanValue, setByteValue, setDoubleValue, setFeatureValue, setFeatureValueFromString, setFloatValue, setIntValue, setLongValue, setShortValue, setStringValue, toShortString, toString, wrapGetIntCatchException
finalize, getClass, notify, notifyAll, wait, wait, wait
_save_fsRefs_to_cas_data
_reset_cas_data, clone
getValuesAsCommaSeparatedString, toStringArray
_getTypeCode, _id, clone, getAddress, getBooleanValue, getByteValue, getCAS, getDoubleValue, getFeatureValue, getFeatureValueAsString, getFloatValue, getIntValue, getJCas, getLongValue, getShortValue, getStringValue, getType, setBooleanValue, setByteValue, setDoubleValue, setFeatureValue, setFeatureValueFromString, setFloatValue, setIntValue, setLongValue, setShortValue, setStringValue
public static final String _TypeName
public static final int typeIndexID
public static final int type
public static final String _FeatName_fsArray
protected FSArrayList()
public FSArrayList(org.apache.uima.cas.impl.TypeImpl type, org.apache.uima.cas.impl.CASImpl casImpl)
casImpl
- the CAS this Feature Structure belongs totype
- the type of this Feature Structurepublic FSArrayList(JCas jcas)
jcas
- JCas to which this Feature Structure belongspublic FSArrayList(JCas jcas, int length)
jcas
- The JCaslength
- initial sizepublic int getTypeIndexID()
getTypeIndexID
in class TOP
public void _init_from_cas_data()
_init_from_cas_data
in interface UimaSerializable
public void _save_to_cas_data()
UimaSerializable
_save_to_cas_data
in interface UimaSerializable
public int size()
public <E extends FeatureStructure> void copyFromArray(E[] src, int srcPos, int destPos, int length)
E
- the type of the source array being copied fromsrc
- -srcPos
- -destPos
- -length
- -ArrayFS.copyFromArray(FeatureStructure[], int, int, int)
public <E extends FeatureStructure> void copyToArray(int srcPos, E[] dest, int destPos, int length)
E
- the type of the elements of the Array being copied intosrcPos
- -dest
- -destPos
- -length
- -ArrayFS.copyToArray(int, FeatureStructure[], int, int)
public TOP[] toArray()
public FeatureStructure[] _toArrayForSelect()
_toArrayForSelect
in interface SelectViaCopyToArray<T extends TOP>
public void copyFromArray(String[] src, int srcPos, int destPos, int length)
copyFromArray
in interface CommonArrayFS<T extends TOP>
src
- the srcsrcPos
- the src posdestPos
- the dest poslength
- the lengthpublic void copyToArray(int srcPos, String[] dest, int destPos, int length)
copyToArray
in interface CommonArrayFS<T extends TOP>
srcPos
- The index of the first element to copy.dest
- The array to copy to.destPos
- Where to start copying into dest
.length
- The number of elements to copy.ArrayIndexOutOfBoundsException
- If srcPos < 0
or
length > size()
or
destPos + length > destArray.length
.public void copyValuesFrom(CommonArrayFS v)
CommonArrayFS
copyValuesFrom
in interface CommonArrayFS<T extends TOP>
v
- the other arraypublic static <E extends TOP,F extends FeatureStructure> FSArrayList<E> create(JCas jcas, F[] a)
E
- generic type of returned FSF
- generic type of the elements of the array argumentjcas
- -a
- -public org.apache.uima.cas.impl.FeatureStructureImplC _superClone()
_superClone
in interface UimaSerializable
public boolean containsAll(Collection<?> c)
containsAll
in interface Collection<T extends TOP>
containsAll
in interface List<T extends TOP>
public boolean isEmpty()
public boolean contains(Object o)
public int lastIndexOf(Object o)
lastIndexOf
in interface List<T extends TOP>
public <U> U[] toArray(U[] a)
public String toString()
toString
in class org.apache.uima.cas.impl.FeatureStructureImplC
public boolean add(T e)
public boolean equals(Object o)
FeatureStructure
equals
in interface Collection<T extends TOP>
equals
in interface List<T extends TOP>
equals
in interface FeatureStructure
equals
in class org.apache.uima.cas.impl.FeatureStructureImplC
public boolean remove(Object o)
public int hashCode()
FeatureStructure
hashCode
in interface Collection<T extends TOP>
hashCode
in interface List<T extends TOP>
hashCode
in interface FeatureStructure
hashCode
in class org.apache.uima.cas.impl.FeatureStructureImplC
public void clear()
public boolean addAll(Collection<? extends T> c)
public boolean addAll(int index, Collection<? extends T> c)
public boolean removeAll(Collection<?> c)
public boolean retainAll(Collection<?> c)
public Stream<T> parallelStream()
parallelStream
in interface Collection<T extends TOP>
public ListIterator<T> listIterator(int index)
listIterator
in interface List<T extends TOP>
public ListIterator<T> listIterator()
listIterator
in interface List<T extends TOP>
public Spliterator<T> spliterator()
spliterator
in interface Iterable<T extends TOP>
spliterator
in interface Collection<T extends TOP>
spliterator
in interface List<T extends TOP>
public boolean removeIf(Predicate<? super T> filter)
removeIf
in interface Collection<T extends TOP>
public void replaceAll(UnaryOperator<T> operator)
replaceAll
in interface List<T extends TOP>
Copyright © 2006–2018 The Apache Software Foundation. All rights reserved.