Class MetadataFieldConfig
- java.lang.Object
-
- org.dspace.importer.external.metadatamapping.MetadataFieldConfig
-
public class MetadataFieldConfig extends Object
A generalised configuration for metadatafields. This is used to make the link between values and the actual MetadatumDTO object.- Author:
- Roeland Dillen (roeland at atmire dot com)
-
-
Constructor Summary
Constructors Constructor Description MetadataFieldConfig()An empty initialization of MetadataFieldConfigMetadataFieldConfig(String full)Create a MetadataFieldConfig using a single value.MetadataFieldConfig(String schema, String element)Create a MetadataFieldConfig using a schema and element qualifier will be set tonullMetadataFieldConfig(String schema, String element, String qualifier)Create a MetadataFieldConfig using a schema,element and qualifierMetadataFieldConfig(MetadatumDTO value)Create a MetadataFieldConfig based on a given MetadatumDTO This MetadatumDTO object contains the schema, element and qualifier needed to initialize the MetadataFieldConfig
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Indicates whether some other object is "equal to" this one.StringgetElement()Return the qualifier set to this object.StringgetField()Return a string representing the field of this objectStringgetQualifier()Return the qualifier set to this object.StringgetSchema()Return the schema set to this object.inthashCode()Returns a hash code value for the object.voidsetElement(String element)Set the element to this MetadataFieldConfigvoidsetQualifier(String qualifier)Set the qualifier to this MetadataFieldConfigvoidsetSchema(String schema)Set the schema to this MetadataFieldConfigStringtoString()Create the String representation of the MetadataFieldConfig
-
-
-
Constructor Detail
-
MetadataFieldConfig
public MetadataFieldConfig(MetadatumDTO value)
Create a MetadataFieldConfig based on a given MetadatumDTO This MetadatumDTO object contains the schema, element and qualifier needed to initialize the MetadataFieldConfig- Parameters:
value- the DTO.
-
MetadataFieldConfig
public MetadataFieldConfig()
An empty initialization of MetadataFieldConfig
-
MetadataFieldConfig
public MetadataFieldConfig(String schema, String element, String qualifier)
Create a MetadataFieldConfig using a schema,element and qualifier- Parameters:
schema- The schema to set to this objectelement- The element to set to this objectqualifier- The qualifier to set to this object
-
MetadataFieldConfig
public MetadataFieldConfig(String full)
Create a MetadataFieldConfig using a single value. This value is split up into schema, element and qualifier, based on a dot(.)- Parameters:
full- A string representing the schema.element.qualifier triplet
-
-
Method Detail
-
equals
public boolean equals(Object o)
Indicates whether some other object is "equal to" this one.
-
toString
public String toString()
Create the String representation of the MetadataFieldConfig
-
hashCode
public int hashCode()
Returns a hash code value for the object. This method is supported for the benefit of hash tables such as those provided byHashMap.
-
setSchema
public void setSchema(String schema)
Set the schema to this MetadataFieldConfig- Parameters:
schema- The schema to set to this object
-
getSchema
public String getSchema()
Return the schema set to this object.nullif nothing is set- Returns:
- The schema of this object
-
getField
public String getField()
Return a string representing the field of this object- Returns:
- The field that is set to this object, in the form of schema.element.qualifier
-
getElement
public String getElement()
Return the qualifier set to this object.nullif nothing is set- Returns:
- The qualifier of this object
-
setElement
public void setElement(String element)
Set the element to this MetadataFieldConfig- Parameters:
element- The element to set to this object
-
getQualifier
public String getQualifier()
Return the qualifier set to this object.nullif nothing is set- Returns:
- The qualifier of this object
-
setQualifier
public void setQualifier(String qualifier)
Set the qualifier to this MetadataFieldConfig- Parameters:
qualifier- The qualifier to set to this object
-
-