Commit 8e1d564c authored by Andrei Popescu's avatar Andrei Popescu
Browse files

removed issue for which ttl were not created on windows

parent 166f27d0
Pipeline #57102 passed with stage
in 49 seconds
......@@ -30,9 +30,11 @@ var RDFTools = /** @class */ (function () {
};
// Write with the writer that is passed; fileName and fs have been set previously
RDFTools.writeTurtle = function (writer) {
var _this = this;
// Write the content of the writer in the .ttl
writer.end(function (error, result) { return _this.fs.writeFile("build/".concat(_this.fileName, ".ttl"), result, function (err) {
var _this = this;
var filePath = "build/".concat(this.fileName, ".ttl").replace(/:/g, '');
console.log(filePath);
writer.end(function (error, result) { return _this.fs.writeFile(filePath, result, function (err) {
// throws an error, you could also catch it here
if (err)
throw err;
......
......@@ -41,13 +41,21 @@ static getOneOfQuad(prefix, name, oneOf, writer){
// Write with the writer that is passed; fileName and fs have been set previously
static writeTurtle (writer){
// Write the content of the writer in the .ttl
writer.end((error:any, result:any) => this.fs.writeFile(`build/${this.fileName}.ttl`, result, (err:any) => {
let filePath = `build/${this.fileName}.ttl`.replace(/:/g,'');
console.log(filePath);
writer.end((error:any, result:any) => this.fs.writeFile(filePath, result, (err:any) => {
// throws an error, you could also catch it here
if (err) throw err;
// success case, the file was saved
console.log('Turtle saved!');}));
}
// Create quads of different shape
static node_node_literal (subj: string, pred:string, obj:string) {
if(pred == 'rdfs:label' || pred == 'rdfs:comment'){
......
Markdown is supported
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