Package com.yahoo.document.datatypes
Class CollectionFieldValue<T extends FieldValue>
- java.lang.Object
-
- com.yahoo.vespa.objects.Selectable
-
- com.yahoo.vespa.objects.Identifiable
-
- com.yahoo.document.datatypes.FieldValue
-
- com.yahoo.document.datatypes.CompositeFieldValue
-
- com.yahoo.document.datatypes.CollectionFieldValue<T>
-
- All Implemented Interfaces:
Cloneable
,Comparable<FieldValue>
- Direct Known Subclasses:
Array
,WeightedSet
public abstract class CollectionFieldValue<T extends FieldValue> extends CompositeFieldValue
Superclass of multivalue field values- Author:
- HÃ¥kon Humberset
-
-
Field Summary
-
Fields inherited from class com.yahoo.document.datatypes.FieldValue
classId
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract boolean
add(T value)
abstract boolean
contains(Object o)
protected FieldValue
createFieldValue(Object o)
Utility function to wrap primitives.abstract Iterator<T>
fieldValueIterator()
CollectionDataType
getDataType()
abstract boolean
isEmpty()
protected boolean
isEmpty(Collection collection)
abstract Iterator<T>
iterator()
abstract boolean
removeValue(FieldValue o)
protected boolean
removeValue(FieldValue o, Collection collection)
abstract int
size()
void
verifyElementCompatibility(T o)
-
Methods inherited from class com.yahoo.document.datatypes.CompositeFieldValue
equals, hashCode, setDataType
-
Methods inherited from class com.yahoo.document.datatypes.FieldValue
assign, clear, clone, compareTo, create, deserialize, deserialize, getRecursiveValue, getRecursiveValue, getWrappedValue, onDeserialize, onSerialize, printXml, serialize, serialize, toXml
-
-
-
-
Method Detail
-
getDataType
public CollectionDataType getDataType()
- Overrides:
getDataType
in classCompositeFieldValue
-
createFieldValue
protected FieldValue createFieldValue(Object o)
Utility function to wrap primitives.- See Also:
Array.ListWrapper
-
verifyElementCompatibility
public void verifyElementCompatibility(T o)
-
add
public abstract boolean add(T value)
-
contains
public abstract boolean contains(Object o)
-
isEmpty
public abstract boolean isEmpty()
-
isEmpty
protected boolean isEmpty(Collection collection)
-
removeValue
public abstract boolean removeValue(FieldValue o)
-
removeValue
protected boolean removeValue(FieldValue o, Collection collection)
-
size
public abstract int size()
-
-