Package org.n52.shetland.ogc.swe
Class SweAbstractDataRecord
- java.lang.Object
-
- org.n52.shetland.ogc.swe.SweAbstractDataComponent
-
- org.n52.shetland.ogc.swe.SweAbstractDataRecord
-
- All Implemented Interfaces:
Copyable<SweAbstractDataComponent>,HasDefaultEncoding<SweAbstractDataComponent>,DataRecord
- Direct Known Subclasses:
SweDataRecord,SweSimpleDataRecord
public abstract class SweAbstractDataRecord extends SweAbstractDataComponent implements DataRecord
- Since:
- 1.0.0
-
-
Constructor Summary
Constructors Constructor Description SweAbstractDataRecord()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description SweAbstractDataRecordaddField(SweField field)Adds field to field listabstract SweAbstractDataRecordcopy()booleanequals(Object obj)booleanexistsFieldForIdentifier(String fieldNameOrElementDefinition)SweFieldgetFieldByIdentifier(String fieldNameOrElementDefinition)intgetFieldIndexByIdentifier(String fieldNameOrElementDefinition)Return the index of the first field with the given fieldNameOrElementDefinition or -1 if not found.List<SweField>getFields()Set<SweAbstractSimpleType<?>>getSweAbstractSimpleTypeFromFields(Class clazz)inthashCode()(package private) booleanisElementDefinition(String fieldNameOrElementDefinition, SweField sweField)(package private) booleanisFieldName(String fieldNameOrElementDefinition, SweField sweField)booleanisSetFields()Check if there are field elementsSweAbstractDataRecordsetFields(List<SweField> fields)-
Methods inherited from class org.n52.shetland.ogc.swe.SweAbstractDataComponent
accept, accept, addName, addName, addName, copyValueTo, getDataComponentType, getDefaultElementEncoding, getDefinition, getDescription, getIdentifier, getLabel, getName, getNames, getXml, isSetDefinition, isSetDescription, isSetIdentifier, isSetLabel, isSetName, isSetNames, isSetXml, setDefaultElementEncoding, setDefinition, setDescription, setIdentifier, setLabel, setName, setName, setName, setXml
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.n52.shetland.ogc.HasDefaultEncoding
isSetDefaultElementEncoding
-
-
-
-
Method Detail
-
getFields
public List<SweField> getFields()
- Specified by:
getFieldsin interfaceDataRecord- Returns:
- the fields
-
setFields
public SweAbstractDataRecord setFields(List<SweField> fields)
- Specified by:
setFieldsin interfaceDataRecord- Parameters:
fields- the fields to set- Returns:
- this
-
addField
public SweAbstractDataRecord addField(SweField field)
Description copied from interface:DataRecordAdds field to field list- Specified by:
addFieldin interfaceDataRecord- Parameters:
field- Field to add- Returns:
- this
-
isSetFields
public boolean isSetFields()
Description copied from interface:DataRecordCheck if there are field elements- Specified by:
isSetFieldsin interfaceDataRecord- Returns:
- Fields not empty
-
getFieldIndexByIdentifier
public int getFieldIndexByIdentifier(String fieldNameOrElementDefinition)
Description copied from interface:DataRecordReturn the index of the first field with the given fieldNameOrElementDefinition or -1 if not found.- Specified by:
getFieldIndexByIdentifierin interfaceDataRecord- Parameters:
fieldNameOrElementDefinition- a definition identifying aSweFieldin thisDataRecord.- Returns:
- the index of the first field with the given fieldDefinition or -1 if not found.
-
getFieldByIdentifier
public SweField getFieldByIdentifier(String fieldNameOrElementDefinition)
- Specified by:
getFieldByIdentifierin interfaceDataRecord
-
existsFieldForIdentifier
public boolean existsFieldForIdentifier(String fieldNameOrElementDefinition)
- Specified by:
existsFieldForIdentifierin interfaceDataRecord
-
isElementDefinition
boolean isElementDefinition(String fieldNameOrElementDefinition, SweField sweField)
-
equals
public boolean equals(Object obj)
- Overrides:
equalsin classSweAbstractDataComponent
-
hashCode
public int hashCode()
- Overrides:
hashCodein classSweAbstractDataComponent
-
getSweAbstractSimpleTypeFromFields
public Set<SweAbstractSimpleType<?>> getSweAbstractSimpleTypeFromFields(Class clazz)
- Specified by:
getSweAbstractSimpleTypeFromFieldsin interfaceDataRecord
-
copy
public abstract SweAbstractDataRecord copy()
- Specified by:
copyin interfaceCopyable<SweAbstractDataComponent>
-
-