Package com.yahoo.document
Class StructDataType
java.lang.Object
com.yahoo.vespa.objects.Selectable
com.yahoo.vespa.objects.Identifiable
com.yahoo.document.DataType
com.yahoo.document.StructuredDataType
com.yahoo.document.BaseStructDataType
com.yahoo.document.StructDataType
- All Implemented Interfaces:
Serializable
,Cloneable
,Comparable<DataType>
- Direct Known Subclasses:
GeoPosType
,TemporaryStructuredDataType
- Author:
- Einar M R Rosenvinge
- See Also:
-
Field Summary
Fields inherited from class com.yahoo.document.BaseStructDataType
fieldIds, fields
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
assign
(StructDataType type) clone()
Creates a new, empty FieldValue of this typeCreates a new FieldValue of this type, with the given value.boolean
getField
(int id) Gets the field with the specified id.Gets the field matching a given name.int
int
hashCode()
void
inherit
(StructDataType type) boolean
inherits
(StructDataType type) boolean
isValueCompatible
(FieldValue value) Methods inherited from class com.yahoo.document.BaseStructDataType
assign, clearFields, getCompressionConfig, getCompressor, hasField, hasField, removeField, setCompressionConfig
Methods inherited from class com.yahoo.document.StructuredDataType
buildFieldPath, createByReflection, createId, getDataTypeName, register
Methods inherited from class com.yahoo.document.DataType
compareTo, getArray, getCode, getId, getMap, getName, getPrimitiveType, getTensor, getWeightedSet, getWeightedSet, isAssignableFrom, isMultivalue, isRegistered, lastPredefinedDataTypeId, register, setId, setName, toString, visitMembers
Methods inherited from class com.yahoo.vespa.objects.Identifiable
create, createFromId, deserialize, deserializeOptional, deserializeWithId, equals, getClassId, getRawUtf8Bytes, getUtf8, onDeserialize, onGetClassId, onSerialize, putUtf8, registerClass, serialize, serializeOptional, serializeWithId
Methods inherited from class com.yahoo.vespa.objects.Selectable
select, select, selectMembers
-
Field Details
-
classId
public static final int classId
-
-
Constructor Details
-
StructDataType
-
StructDataType
-
-
Method Details
-
createFieldValue
Description copied from class:DataType
Creates a new, empty FieldValue of this type- Specified by:
createFieldValue
in classStructuredDataType
-
createFieldValue
Description copied from class:DataType
Creates a new FieldValue of this type, with the given value.- Overrides:
createFieldValue
in classDataType
- Parameters:
o
- the value of the new FieldValue- Returns:
- a new FieldValue of this type, with the given value
-
clone
- Overrides:
clone
in classBaseStructDataType
-
assign
-
getField
Description copied from class:StructuredDataType
Gets the field matching a given name.- Overrides:
getField
in classBaseStructDataType
- Parameters:
fieldName
- The name of a field.- Returns:
- Returns the matching field, or null if not found.
-
getField
Description copied from class:StructuredDataType
Gets the field with the specified id.- Overrides:
getField
in classBaseStructDataType
- Parameters:
id
- the id of the field to return.- Returns:
- the matching field, or null if not found.
-
addField
- Overrides:
addField
in classBaseStructDataType
-
getFields
- Overrides:
getFields
in classBaseStructDataType
-
getFieldsThisTypeOnly
-
getFieldCount
public int getFieldCount()- Overrides:
getFieldCount
in classBaseStructDataType
-
getValueClass
- Specified by:
getValueClass
in classDataType
-
isValueCompatible
- Specified by:
isValueCompatible
in classDataType
-
inherit
-
getInheritedTypes
-
inherits
-
equals
- Overrides:
equals
in classStructuredDataType
-
hashCode
public int hashCode()- Overrides:
hashCode
in classStructuredDataType
-