Create a new file in the rdflibexperiments directory:
vim exp2.js
Add the contents:
var $rdf = require('../rdflib.js');
var uri = 'http://bshambaugh.rww.io/profile/card'
var body = '<a> <b> <c> .'
var mimeType = 'text/turtle'
var store = $rdf.graph()
try {
$rdf.parse(body, store, uri, mimeType)
} catch (err) {
console.log(err)
}
console.log(store);
Run the contents:
first in vim: wq!
second from the prompt: node exp2.js
To get the results:
var $rdf = require('../rdflib.js');
var uri = 'http://bshambaugh.rww.io/profile/card'
var body = '<a> <b> <c> .'
var mimeType = 'text/turtle'
var store = $rdf.graph()
try {
$rdf.parse(body, store, uri, mimeType)
} catch (err) {
console.log(err)
}
console.log(store);
Tuesday, May 31, 2016
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment