General Actions:
Log-in
Register
Home
▼
:
Wiki Index
Document Index
User Index
»
Space:
2. Accessing the CB-NL
▼
:
Document Index
»
Page:
SPARQL-endpoint
Search
Page Actions:
Export
▼
:
Export as PDF
Export as RTF
Export as HTML
More actions
▼
:
Print preview
View Source
Welcome to the CB-NL Wiki
»
Accessing the CB-NL
»
The CB-NL RDF distribution
Wiki source code of
The CB-NL RDF distribution
Last modified by
Hans Schevers
on 2015/05/07 11:26
Content
·
Comments
(0)
·
Attachments
(0)
·
History
·
Information
Hide line numbers
1: The CBNL version contains currently 4 separate graphs. These are the CBNL topmodel, the CBNL core, the CBNL metamodel and a graph for listvalues. 2: 3: 4: **cbnlcore** http:~/~/ont.cbnl.org/cb/def/ 5: 6: **cbnltop** http:~/~/ont.cbnl.org/top/def/ 7: 8: (% style="font-size: 14px; background-color: rgb(245, 245, 245);" %)**meta** http:~/~/ont.cbnl.org/metamodel/def/ 9: 10: **list** [[http:~~/~~/ont.cbnl.org/cb/id/>>url:http://ont.cbnl.org/cb/id/||style="font-size: 14px; background-color: rgb(245, 245, 245);"]] 11: 12: 13: In addition the following graphs are available in the Sesame repository interrelating CB-NL Concepts with other information sources: 14: 15: 16: [[http:~~/~~/ont.cbnl.org/mapping/IMGeo-2.1.1-CBNL-20150501>>url:http://ont.cbnl.org/mapping/IMGeo-2.1.1-CBNL-20150501||style="font-size: 14px; background-color: rgb(245, 245, 245);"]] 17: 18: [[http:~~/~~/ont.cbnl.org/mapping/ETIMClasses-1-CBNL-20150501>>url:http://ont.cbnl.org/mapping/ETIMClasses-1-CBNL-20150501]] 19: 20: [[http:~~/~~/ont.cbnl.org/mapping/ETIMFeatures-1-CBNL-20150501>>url:http://ont.cbnl.org/mapping/ETIMFeatures-1-CBNL-20150501]] 21: 22: [[http:~~/~~/ont.cbnl.org/mapping/ETIMValues-1-CBNL-20150501>>url:http://ont.cbnl.org/mapping/ETIMValues-1-CBNL-20150501]] 23: 24: [[http:~~/~~/ont.cbnl.org/mapping/ETIMSTABU-1-CBNL-20150501>>url:http://ont.cbnl.org/mapping/ETIMSTABU-1-CBNL-20150501]] 25: 26: [[http:~~/~~/ont.cbnl.org/mapping/NEN2767-4-1.0-CBNL-20150501>>url:http://ont.cbnl.org/mapping/NEN2767-4-1.0-CBNL-20150501]] 27: 28: 29: 30: (% style="font-size: 24.7800006866455px; line-height: 1.2em; color: rgb(33, 115, 175); background-color: rgb(245, 245, 245);" %)Access to the CBNL RDF source 31: 32: The CBNL is coded in RDF-OWL. The CBNL RDF source is distributed in a RDF/XML file and via a SPARQL endpoint (including. REST interface). 33: 34: = The CBNL source files = 35: 36: Location of the CBNL core RDF/XML file: http:~/~/ont.cbnl.org/cb/def/ 37: 38: Location of the CBNL top RDF/XML file: http:~/~/ont.cbnl.org/top/def/ 39: 40: 41: == The CBNL SPARQL endpoint == 42: 43: (% style="font-size: 14px; background-color: rgb(245, 245, 245);" %)The CBNL endpoint can be accessed via the following HTTP address: http:~/~/api.cbnl.org/sparql/CBNL 44: 45: 46: (% style="font-size: 20.4400005340576px; line-height: 1.2em; color: rgb(33, 115, 175); background-color: rgb(245, 245, 245);" %)Accessing the CBNL endpoint with a SPARQL client 47: 48: A SPARQL client, such as [[Topbraid Composer>>url:http://www.topquadrant.com]] or [[ARQ>>url:http://jena.apache.org/documentation/query/]] can be used to access the endpoint. Another good option is Yasque (http:~/~/legacy.yasgui.org/). The SPARQL statement that is executed by the client must include the endpoint address like is done in this example: 49: 50: 51: (% style="font-size: 14px; background-color: rgb(245, 245, 245);" %)SELECT * 52: 53: WHERE 54: { 55: SERVICE <http:~/~/api.cbnl.org/sparql/CBNL> 56: { GRAPH <http:~/~/ont.cbnl.org/top/def/> 57: { ?s ?b ?o } 58: } 59: } 60: LIMIT 10 61: 62: 63: === Accessing the CBNL endpoint via REST interface === 64: 65: The endpoint can be queried as follows: 66: 67: <http address of the endpoint>?query=<the SPARQL query> Note: The "<" and ">" sign are not part of the statement, there are listed here to list the separate parts of the request. 68: 69: 70: Example: [[http:~~/~~/api.cbnl.org/sparql/CBNL?query= PREFIX cbnlcore: <http:~~/~~/ont.cbnl.org/cb/def/> DESCRIBE cbnlcore:Brug>>url:http://api.cbnl.org/sparql/CBNL?query=%20PREFIX%20cbnlcore:%20%3Chttp://ont.cbnl.org/cb/def/%3E%20DESCRIBE%20cbnlcore:Brug]] 71: 72: Encoded version: http:~/~/api.cbnl.org/sparql/CBNL?query=%20PREFIX%20cbnlcore:%20%3Chttp:~/~/ont.cbnl.org/cb/def/%3E%20DESCRIBE%20cbnlcore:Brug 73: 74: 75: The REST interface query results are served in the browser as a file that can be opened in a text editor.