Package io.goobi.viewer.model.archives
Class BasexEADParser
java.lang.Object
io.goobi.viewer.model.archives.BasexEADParser
Loads and parses EAD documents from BaseX databases.
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
getIdForName
(String name) Get the database names and file names from the basex databasesloadDatabase
(ArchiveResource database) Loads the given database and parses the EAD document.readConfiguration
(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> metadataConfig) Loads fields from the given configuration node.static void
setNodeType
(org.jdom2.Element node, ArchiveEntry entry) void
-
Field Details
-
NAMESPACE_EAD
public static final org.jdom2.Namespace NAMESPACE_EAD
-
-
Constructor Details
-
BasexEADParser
public BasexEADParser(String basexUrl, SolrSearchIndex searchIndex) throws PresentationException, IndexUnreachableException - Parameters:
basexUrl
-searchIndex
-- Throws:
IndexUnreachableException
PresentationException
org.apache.commons.configuration2.ex.ConfigurationException
-
-
Method Details
-
updateAssociatedRecordMap
-
getPossibleDatabases
Get the database names and file names from the basex databases- Returns:
- List
- Throws:
HTTPException
IOException
-
loadDatabase
public ArchiveEntry loadDatabase(ArchiveResource database) throws IllegalStateException, IOException, HTTPException, org.jdom2.JDOMException Loads the given database and parses the EAD document.- Parameters:
database
-- Returns:
- Root element of the loaded tree
- Throws:
IllegalStateException
IOException
HTTPException
org.jdom2.JDOMException
-
setNodeType
- Parameters:
node
-entry
-
-
readConfiguration
public BasexEADParser readConfiguration(org.apache.commons.configuration2.HierarchicalConfiguration<org.apache.commons.configuration2.tree.ImmutableNode> metadataConfig) throws org.apache.commons.configuration2.ex.ConfigurationException Loads fields from the given configuration node.- Parameters:
metadataConfig
-- Returns:
BasexEADParser
- Throws:
org.apache.commons.configuration2.ex.ConfigurationException
-
getBasexUrl
- Returns:
- the basexUrl
-
getIdForName
-