Class MetadataField
- java.lang.Object
-
- org.gcube.common.metadataprofilediscovery.jaxb.MetadataField
-
- All Implemented Interfaces:
Serializable
public class MetadataField extends Object implements Serializable
The Class MetadataField.- Author:
- Francesco Mangiacrapa at ISTI-CNR francesco.mangiacrapa@isti.cnr.it Jun 20, 2022
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MetadataField()Instantiates a new metadata field.MetadataField(String fieldName, Boolean mandatory)Instantiates a new metadata field.MetadataField(String fieldName, Boolean mandatory, String categoryID)Instantiates a new metadata field.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetCategoryFieldQName()Gets the category field qualified name.StringgetCategoryRef()Gets the category ref.DataTypegetDataType()Gets the data type.StringgetDefaultValue()Gets the default value.StringgetFieldId()Gets the field id.StringgetFieldName()Gets the field name.MetadataGroupinggetGrouping()Gets the grouping.BooleangetMandatory()Gets the mandatory.StringgetMaxOccurs()Gets the max occurs.StringgetNote()Gets the note.MetadataTagginggetTagging()Gets the tagging.MetadataValidatorgetValidator()Gets the validator.MetadataVocabularygetVocabulary()Gets the vocabulary.voidsetCategoryRefToCategoryId(String categoryID)Sets the category ref to category id.voidsetDataType(DataType dataType)Sets the data type.voidsetDefaultValue(String defaultValue)Sets the default value.voidsetFieldId(String fieldId)Sets the field id.voidsetFieldName(String fieldName)Sets the field name.voidsetGrouping(MetadataGrouping grouping)Sets the grouping.voidsetMandatory(Boolean mandatory)Sets the mandatory.voidsetMaxOccurs(String maxOccurs)Sets the max occurs.voidsetNote(String note)Sets the note.voidsetTagging(MetadataTagging tagging)Sets the tagging.voidsetValidator(MetadataValidator validator)Sets the validator.voidsetVocabulary(MetadataVocabulary vocabulary)Sets the vocabulary.StringtoString()To string.
-
-
-
Method Detail
-
getCategoryRef
public String getCategoryRef()
Gets the category ref. If exists its value is a Category-ID- Returns:
- the categoryRef
-
setCategoryRefToCategoryId
public void setCategoryRefToCategoryId(String categoryID)
Sets the category ref to category id.- Parameters:
categoryID- the new category ref to category id
-
getCategoryFieldQName
public String getCategoryFieldQName()
Gets the category field qualified name. If the Metadata Field belongs to a category, returns the qualified name:categoryRefNamespace.Separator} fieldName; Otherwise returns the fieldName- Returns:
- the category q name
-
getFieldId
public String getFieldId()
Gets the field id.- Returns:
- the field id
-
setFieldId
public void setFieldId(String fieldId)
Sets the field id. Optional Field used as fieldName in the (result) Document. (e.g. JSON Document { fieldId: [data entry value]} If it absent, the mandatory fieldName is used- Parameters:
fieldId- the new field id
-
getFieldName
public String getFieldName()
Gets the field name.- Returns:
- the fieldName
-
getMandatory
public Boolean getMandatory()
Gets the mandatory.- Returns:
- the mandatory
-
getDataType
public DataType getDataType()
Gets the data type.- Returns:
- the dataType
-
getMaxOccurs
public String getMaxOccurs()
Gets the max occurs.- Returns:
- the maxOccurs
-
setMaxOccurs
public void setMaxOccurs(String maxOccurs)
Sets the max occurs.- Parameters:
maxOccurs- the maxOccurs to set
-
getDefaultValue
public String getDefaultValue()
Gets the default value.- Returns:
- the defaultValue
-
getNote
public String getNote()
Gets the note.- Returns:
- the note
-
getVocabulary
public MetadataVocabulary getVocabulary()
Gets the vocabulary.- Returns:
- the vocabulary
-
getValidator
public MetadataValidator getValidator()
Gets the validator.- Returns:
- the validator
-
getTagging
public MetadataTagging getTagging()
Gets the tagging.- Returns:
- the tagging
-
getGrouping
public MetadataGrouping getGrouping()
Gets the grouping.- Returns:
- the grouping
-
setFieldName
public void setFieldName(String fieldName)
Sets the field name.- Parameters:
fieldName- the fieldName to set
-
setMandatory
public void setMandatory(Boolean mandatory)
Sets the mandatory.- Parameters:
mandatory- the mandatory to set
-
setDataType
public void setDataType(DataType dataType)
Sets the data type.- Parameters:
dataType- the dataType to set
-
setDefaultValue
public void setDefaultValue(String defaultValue)
Sets the default value.- Parameters:
defaultValue- the defaultValue to set
-
setNote
public void setNote(String note)
Sets the note.- Parameters:
note- the note to set
-
setVocabulary
public void setVocabulary(MetadataVocabulary vocabulary)
Sets the vocabulary.- Parameters:
vocabulary- the vocabulary to set
-
setValidator
public void setValidator(MetadataValidator validator)
Sets the validator.- Parameters:
validator- the validator to set
-
setTagging
public void setTagging(MetadataTagging tagging)
Sets the tagging.- Parameters:
tagging- the tagging to set
-
setGrouping
public void setGrouping(MetadataGrouping grouping)
Sets the grouping.- Parameters:
grouping- the grouping to set
-
-