| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | 2× 1× 1× 1× 2× 1× | 'use strict';
export default class Result {
/**
* The Result class wraps the possible responses from the SPARQL endpoint's response
*
* @class Result
* @constructor
* @param {String} data - Result object
*/
constructor(data) {
if (data.results) {
this.bindings = data.results.bindings;
this.vars = data.head.vars;
this.link = data.head.link;
}
if (data.boolean) {
this.boolean = data.boolean;
}
}
} |