-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test-cases: RMLTTC0007e: add test case for dcat:format
Fixes #52
- Loading branch information
1 parent
9449422
commit 225991e
Showing
3 changed files
with
63 additions
and
0 deletions.
There are no files selected for viewing
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<http://example.org/0> <http://xmlns.com/foaf/0.1/age> "33" . | ||
<http://example.org/0> <http://xmlns.com/foaf/0.1/name> "Monica Geller" . | ||
<http://example.org/1> <http://xmlns.com/foaf/0.1/age> "34" . | ||
<http://example.org/1> <http://xmlns.com/foaf/0.1/name> "Rachel Green" . | ||
<http://example.org/2> <http://xmlns.com/foaf/0.1/age> "35" . | ||
<http://example.org/2> <http://xmlns.com/foaf/0.1/name> "Joey Tribbiani" . | ||
<http://example.org/3> <http://xmlns.com/foaf/0.1/age> "36" . | ||
<http://example.org/3> <http://xmlns.com/foaf/0.1/name> "Chandler Bing" . | ||
<http://example.org/4> <http://xmlns.com/foaf/0.1/age> "37" . | ||
<http://example.org/4> <http://xmlns.com/foaf/0.1/name> "Ross Geller" . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
@prefix rml: <http://w3id.org/rml/> . | ||
@prefix foaf: <http://xmlns.com/foaf/0.1/> . | ||
@prefix dcat: <http://www.w3.org/ns/dcat#> . | ||
@prefix td: <https://www.w3.org/2019/wot/td#> . | ||
@prefix htv: <http://www.w3.org/2011/http#> . | ||
@prefix hctl: <https://www.w3.org/2019/wot/hypermedia#> . | ||
@prefix formats: <http://www.w3.org/ns/formats/> . | ||
@base <http://example.com/rules/> . | ||
|
||
<#DCATSourceAccess> a rml:Source, dcat:Distribution; | ||
dcat:downloadURL <http://w3id.org/rml/resources/rml-io/RMLTTC0007d/Friends.json>; | ||
dcat:format <http://www.iana.org/assignments/media-types/application/json> ; | ||
. | ||
|
||
<#TriplesMap> a rml:TriplesMap; | ||
rml:logicalSource [ a rml:LogicalSource; | ||
rml:source <#DCATSourceAccess>; | ||
rml:referenceFormulation rml:JSONPath; | ||
rml:iterator "$[*]"; | ||
]; | ||
rml:subjectMap [ a rml:SubjectMap; | ||
rml:template "http://example.org/{$.id}"; | ||
rml:logicalTarget <#TargetDump1>; | ||
]; | ||
rml:predicateObjectMap [ a rml:PredicateObjectMap; | ||
rml:predicateMap [ a rml:PredicateMap; | ||
rml:constant foaf:name; | ||
]; | ||
rml:objectMap [ a rml:ObjectMap; | ||
rml:reference "$.name"; | ||
]; | ||
]; | ||
rml:predicateObjectMap [ a rml:PredicateObjectMap; | ||
rml:predicateMap [ a rml:PredicateMap; | ||
rml:constant foaf:age; | ||
]; | ||
rml:objectMap [ a rml:ObjectMap; | ||
rml:reference "$.age"; | ||
]; | ||
]; | ||
. | ||
|
||
<#TargetDump1> a rml:LogicalTarget; | ||
rml:target [ a rml:Target, td:Thing; | ||
td:hasPropertyAffordance [ | ||
td:hasForm [ | ||
hctl:hasTarget "http://localhost/data"; | ||
hctl:forContentType "application/n-quads"; | ||
]; | ||
]; | ||
]; | ||
rml:serialization formats:N-Quads; | ||
. |