Commit 5f803bca authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Adds conditionsOfUse and conditionsOfUse

Both literal properties are there for some text if no rights object should be created.
parent 540d8865
......@@ -44,6 +44,7 @@ object KEYS {
const val sameAs = "sameAs"
const val relation = "relation"
const val conditionsOfUse = "conditionsOfUse"
const val conditionsOfAccess = "conditionsOfAccess"
// Rules
......@@ -159,6 +160,7 @@ object KEYS {
Pair(locator, EBUCORE.locator),
Pair(sameAs, SCHEMA.sameAs),
Pair(relation, DC.relation),
Pair(conditionsOfUse, RICO.conditionsOfUse)
Pair(conditionsOfUse, RICO.conditionsOfUse),
Pair(conditionsOfAccess, RICO.conditionsOfAccess)
)
}
\ No newline at end of file
......@@ -103,7 +103,8 @@ class MappingConfig(directory: String) {
}
// literal properties
KEYS.name, KEYS.title, KEYS.descriptiveNote, KEYS.scopeAndContent, KEYS.sameAs,
KEYS.abstract, KEYS.source, KEYS.hasSponsoringAgent, KEYS.hasFindingAid, KEYS.relation ->
KEYS.abstract, KEYS.source, KEYS.hasSponsoringAgent, KEYS.hasFindingAid, KEYS.relation,
KEYS.conditionsOfUse, KEYS.conditionsOfAccess ->
recordFieldMappers.add(buildAnnotationMappers(entry))
KEYS.rights ->
recordFieldMappers.addAll(buildRuleMappers(entry.value))
......@@ -154,7 +155,7 @@ class MappingConfig(directory: String) {
when (val key = entry.key) {
KEYS.descriptiveNote, KEYS.medium, KEYS.physicalCharacteristics,
KEYS.colour, KEYS.duration,
KEYS.conditionsOfUse ->
KEYS.conditionsOfUse, KEYS.conditionsOfAccess ->
physicalObjectFieldMappers.add(buildAnnotationMappers(entry))
KEYS.identifiers ->
physicalObjectFieldMappers.addAll(buildRicoConceptMappers(key, entry.value))
......@@ -168,7 +169,7 @@ class MappingConfig(directory: String) {
private fun parseDigitalInstantiationConfig(source: Map<String, Any>) {
for (entry in source) {
when (val key = entry.key) {
KEYS.locator, KEYS.descriptiveNote, KEYS.duration, KEYS.conditionsOfUse ->
KEYS.locator, KEYS.descriptiveNote, KEYS.duration, KEYS.conditionsOfUse, KEYS.conditionsOfAccess ->
digitalObjectFieldMappers.add(buildAnnotationMappers(entry))
KEYS.identifiers ->
digitalObjectFieldMappers.addAll(buildRicoConceptMappers(key, entry.value))
......
......@@ -56,6 +56,7 @@ object RICO {
val scopeAndContent: Property = prop( "scopeAndContent")
val physicalCharacteristics: Property = prop( "physicalCharacteristics")
val conditionsOfUse: Property = prop("conditionsOfUse")
val conditionsOfAccess: Property = prop("conditionsOfAccess")
// Object Properties
......
id: jobXYZ
app:
institutionId: "BAZ"
recordSetId: "BAZ-B_MEI"
......@@ -10,4 +9,4 @@ kafka:
topic:
in: test-topic-in
out: test-topic-out
process: test-topic-process
\ No newline at end of file
process: test-process
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment