@ui5/linter
Version:
A static code analysis tool for UI5
57 lines • 1.78 kB
JavaScript
export default class ManifestReporter {
constructor(resourcePath, context, manifest) {
this.
this.
this.
}
addMessage(id, argsOrNode, node) {
if (!argsOrNode) {
throw new Error("Invalid arguments: Missing second argument");
}
let args;
if (typeof argsOrNode === "string") {
node = argsOrNode;
args = null;
}
else if (!node) {
throw new Error("Invalid arguments: Missing 'node'");
}
else {
args = argsOrNode;
}
this.
}
addCoverageInfo({ node, message, category }) {
const location = this.
this.
category,
// One-based to be aligned with most IDEs
line: location.key.line,
column: location.key.column,
endLine: location.valueEnd.line,
endColumn: location.valueEnd.column,
message,
});
}
const location = this.
return location || { key: 1, keyEnd: 1, value: 1, valueEnd: 1 };
}
let line = 1;
let column = 1;
const location = this.
if (location) {
line = location.key.line + 1;
column = location.key.column + 1;
}
return {
line,
column,
};
}
}
//# sourceMappingURL=ManifestReporter.js.map