test for carare
This commit is contained in:
parent
22976a6983
commit
e356f50ad7
|
@ -56,6 +56,17 @@ public class ApplyX3MappingTest {
|
|||
x3mEngine.execute();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testCarareCollection() throws MalformedURLException {
|
||||
X3MLEngineFactory x3mEngine = X3MLEngineFactory.create()
|
||||
.withMappings(new URL("https://mapping.d4science.org/3MEditor/Services?id=1010&output=text/xml&method=export"))
|
||||
.withVerboseLogging()
|
||||
.withGeneratorPolicy(getInputStreamFromClasspath("/eu/dnetlib/x3m/ariadne_policy.xml"))
|
||||
.withInput(getInputStreamFromClasspath("/eu/dnetlib/x3m/carare_collection.xml"))
|
||||
.withOutput(System.out, X3MLEngineFactory.OutputFormat.RDF_XML);
|
||||
x3mEngine.execute();
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void doBasicTest(String policyPath, String recordPath) throws IOException {
|
||||
|
|
|
@ -1,51 +1,37 @@
|
|||
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<generator_policy>
|
||||
<!-- ARIADNEplus Generator Policy version 1.5 -->
|
||||
|
||||
<!-- ARIADNEplus Generator Policy version 1.10 -->
|
||||
<!-- The prefix is a namespace that must be declared in the X3ML definition.
|
||||
in the x3ml define <namespace prefix="ariadneplus" uri="https://ariadne-infrastructure.eu/aocat/"/> -->
|
||||
|
||||
<generator name="CollectionURI" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Collection/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="CollectionURI-2" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Collection/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="DataResourceURI" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Resource/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="DataResourceURI-2" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Resource/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
|
||||
<generator name="ObjectURI" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Object/{resource}-{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="ObjectURI-2" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Object/{arg1}/{arg2}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="ObjectLabel">
|
||||
<pattern>Resource {resource} is about object {term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="IdentifierURI" prefix="ariadneplus">
|
||||
<pattern>Identifier/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="DocumentURI" prefix="ariadneplus" shorten="yes">>
|
||||
<generator name="DocumentURI" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Document/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="DocumentURI-2" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Document/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="EventURI" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Event/{resource}-{term}</pattern>
|
||||
</generator>
|
||||
|
@ -70,7 +56,7 @@
|
|||
<generator name="PlaceURI-2" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Place/{arg1}/{arg2}</pattern>
|
||||
</generator>
|
||||
<generator name="AgentURI" prefix="ariadneplus" >
|
||||
<generator name="AgentURI" prefix="ariadneplus">
|
||||
<pattern>Agent/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="AgentURI-short" prefix="ariadneplus" shorten="yes">
|
||||
|
@ -82,65 +68,63 @@
|
|||
<generator name="OrgURI" prefix="ariadneplus">
|
||||
<pattern>Organisation/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="ConceptURI" prefix="ariadneplus">
|
||||
<pattern>Concept/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="ConceptURI-2" prefix="ariadneplus">
|
||||
<pattern>Concept/{scheme}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="ConceptURI-3" prefix="ariadneplus">
|
||||
<pattern>Concept/{db}/{scheme}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="ConceptURI-2-short" prefix="ariadneplus" shorten="yes">
|
||||
<pattern>Concept/{scheme}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="LangURI" prefix="lexvo">
|
||||
<pattern>{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="OneLevelCustomURI" prefix="ariadneplus">
|
||||
<pattern>{level1}/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="TwoLevelCustomURI" prefix="ariadneplus">
|
||||
<pattern>{level1}/{level2}/{term}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="GraveURI-2" prefix="ariadneplus">
|
||||
<pattern>Grave/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="BurialURI-2" prefix="ariadneplus">
|
||||
<pattern>Burial/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="FindsURI-2" prefix="ariadneplus">
|
||||
<pattern>Finds/{provider}/{term}</pattern>
|
||||
</generator>
|
||||
<generator name="SimpleLabel">
|
||||
<pattern>{label}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="CompositeLabel">
|
||||
<pattern>{label} {text}</pattern>
|
||||
</generator>
|
||||
|
||||
<generator name="URIorUUID">
|
||||
<custom generatorClass="gr.forth.URIorUUID">
|
||||
<set-arg name="text"/>
|
||||
</custom>
|
||||
</generator>
|
||||
|
||||
<generator name="URNfromTextualContent">
|
||||
<custom generatorClass="gr.forth.TextualContent">
|
||||
<set-arg name="text" type="xpath"/>
|
||||
</custom>
|
||||
</generator>
|
||||
|
||||
<generator name="TypedLiteralGen">
|
||||
<custom generatorClass="gr.forth.TypedLiteralGenerator">
|
||||
<set-arg name="text"/>
|
||||
</custom>
|
||||
</generator>
|
||||
|
||||
<generator name="ConcatMultipleTerms1">
|
||||
<custom generatorClass="gr.forth.ConcatMultipleTerms">
|
||||
<set-arg name="prefix" type="constant"/>
|
||||
<set-arg name="delimiter" type="constant"/>
|
||||
<set-arg name="sameTermsDelim" type="constant"/>
|
||||
<set-arg name="diffTermsDelim" type="constant"/>
|
||||
<set-arg name="text1"/>
|
||||
</custom>
|
||||
</generator>
|
||||
|
||||
</generator_policy>
|
|
@ -0,0 +1,20 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<record xmlns:dc="http://purl.org/dc/elements/1.1/" type="collection">
|
||||
<dc:title>Sites and Monuments Record (SMR), Ireland</dc:title>
|
||||
<dc:identifier>https://archaeology.ie/archaeological-survey-ireland</dc:identifier>
|
||||
<dc:source>National Monuments Service, Department of Housing, Local Government and Heritage</dc:source>
|
||||
<dc:description>The SMR contains details of all monuments and places (sites) where it is believed there is a
|
||||
monument known to the ASI pre-dating AD 1700 and also includes a selection of monuments from the post-AD 1700
|
||||
period. There are in excess of 150,800 records in the database and over 138,800 of these relate to
|
||||
archaeological monuments. The remaining 12,000 records are classified as ‘Redundant record’: the majority of
|
||||
these relate to obsolete terms, records or features that are not monuments.
|
||||
</dc:description>
|
||||
<dc:publisher>National Monuments Service, Department of Housing, Local Government and Heritage, Republic of
|
||||
Ireland
|
||||
</dc:publisher>
|
||||
<date_created>Tue July 21 12:00:00 BST 2022</date_created>
|
||||
<date_modified>Tue July 21 12:00:00 BST 2022</date_modified>
|
||||
<dc:format>Dataset Collection</dc:format>
|
||||
<dc:language>eng</dc:language>
|
||||
<dc:rights>https://archaeology.ie/archaeological-survey-ireland/historic-environment-viewer-application</dc:rights>
|
||||
</record>
|
Loading…
Reference in New Issue