public class RecordFieldsExtractor extends Object
| Constructor and Description |
|---|
RecordFieldsExtractor() |
RecordFieldsExtractor(List<PublisherField> storeIndices) |
| Modifier and Type | Method and Description |
|---|---|
com.google.common.collect.Multimap<String,String> |
extractFields(String record,
Collection<String> enrichmentXPaths)
Parses the record and returns a map where a key is the name of an index, the value is the value in the record at the xpath specificed
in this.storeIndices.
|
String |
getDuplicateXPath() |
Collection<String> |
getEnrichedSets(org.dom4j.Document docBody,
Collection<String> enrichmentXPaths,
Collection<String> originalSets) |
List<PublisherField> |
getStoreIndices() |
boolean |
isDuplicate(org.dom4j.Document doc) |
boolean |
isSkipDuplicates() |
void |
setDuplicateXPath(String duplicateXPath) |
void |
setSkipDuplicates(boolean skipDuplicates) |
void |
setStoreIndices(List<PublisherField> storeIndices) |
public RecordFieldsExtractor(List<PublisherField> storeIndices)
public RecordFieldsExtractor()
public com.google.common.collect.Multimap<String,String> extractFields(String record, Collection<String> enrichmentXPaths)
record - the XML string to parse.enrichmentXPaths - collection of xpaths that must be satisfied to consider the current record as "enriched by OpenAIRE"public Collection<String> getEnrichedSets(org.dom4j.Document docBody, Collection<String> enrichmentXPaths, Collection<String> originalSets)
public boolean isDuplicate(org.dom4j.Document doc)
public List<PublisherField> getStoreIndices()
public void setStoreIndices(List<PublisherField> storeIndices)
public String getDuplicateXPath()
public void setDuplicateXPath(String duplicateXPath)
public boolean isSkipDuplicates()
public void setSkipDuplicates(boolean skipDuplicates)
Copyright © 2018. All rights reserved.