Class EndnoteImportMetadataSourceServiceImpl
- java.lang.Object
-
- org.dspace.importer.external.metadatamapping.AbstractMetadataFieldMapping<PlainMetadataSourceDto>
-
- org.dspace.importer.external.service.components.AbstractPlainMetadataSource
-
- org.dspace.importer.external.endnote.service.EndnoteImportMetadataSourceServiceImpl
-
- All Implemented Interfaces:
MetadataFieldMapping<PlainMetadataSourceDto,MetadataContributor<PlainMetadataSourceDto>>,FileSource,MetadataSource
public class EndnoteImportMetadataSourceServiceImpl extends AbstractPlainMetadataSource
Implements a metadata importer for Endnote files- Author:
- Pasquale Cavallo (pasquale.cavallo at 4science dot it)
-
-
Constructor Summary
Constructors Constructor Description EndnoteImportMetadataSourceServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetImportSource()The string that identifies this import implementation.protected List<PlainMetadataSourceDto>readData(InputStream fileInpuStream)This method map the data present in the inputStream, then return a list PlainMetadataSourceDto.voidsetMetadataFieldMap(Map<MetadataFieldConfig,MetadataContributor<PlainMetadataSourceDto>> metadataFieldMap)Defines which metadatum is mapped on which metadatum.-
Methods inherited from class org.dspace.importer.external.service.components.AbstractPlainMetadataSource
getRecord, getRecords, getSupportedExtensions, setSupportedExtensions
-
Methods inherited from class org.dspace.importer.external.metadatamapping.AbstractMetadataFieldMapping
getMetadataFieldMap, getMetadataProcessor, resultToDCValueMapping, setMetadataProcessorMap, toDCValue
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.dspace.importer.external.service.components.FileSource
isValidSourceForFile
-
-
-
-
Method Detail
-
getImportSource
public String getImportSource()
Description copied from interface:MetadataSourceThe string that identifies this import implementation. Preferable a URI- Returns:
- the identifying uri
-
readData
protected List<PlainMetadataSourceDto> readData(InputStream fileInpuStream) throws FileSourceException
This method map the data present in the inputStream, then return a list PlainMetadataSourceDto. Any PlainMetadataSourceDto will be used to create a singleImportRecord- Specified by:
readDatain classAbstractPlainMetadataSource- Parameters:
inputStream- the inputStream of the Endnote file- Returns:
- List of
PlainMetadataSourceDto - Throws:
FileSourceException- See Also:
AbstractPlainMetadataSource
-
setMetadataFieldMap
public void setMetadataFieldMap(Map<MetadataFieldConfig,MetadataContributor<PlainMetadataSourceDto>> metadataFieldMap)
Description copied from class:AbstractMetadataFieldMappingDefines which metadatum is mapped on which metadatum. Note that while the key must be unique it only matters here for postprocessing of the value. The mapped MetadatumContributor has full control over what metadatafield is generated.- Overrides:
setMetadataFieldMapin classAbstractMetadataFieldMapping<PlainMetadataSourceDto>- Parameters:
metadataFieldMap- The map containing the link between retrieve metadata and metadata that will be set to the item.
-
-