summaryrefslogtreecommitdiffstats
path: root/src/DocGen
diff options
context:
space:
mode:
authorRowan Goemans <RB.Goemans@student.han.nl>2017-10-15 02:32:52 +0200
committerRowan Goemans <RB.Goemans@student.han.nl>2017-10-15 02:32:52 +0200
commitdf8f38308b7871f2790b5b2cc466f7ce2add4362 (patch)
tree8f8cddcd498c8ace73a0a198036d255d92c5af1a /src/DocGen
parentcc0d69edcd362c1abde9d0005c70d8e3692395bc (diff)
downloaddoxdocgen-df8f38308b7871f2790b5b2cc466f7ce2add4362.tar.gz
-- Fixed tslint issues v2
Diffstat (limited to 'src/DocGen')
-rw-r--r--src/DocGen/CGen.ts24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/DocGen/CGen.ts b/src/DocGen/CGen.ts
index d4a1966..72bcfe0 100644
--- a/src/DocGen/CGen.ts
+++ b/src/DocGen/CGen.ts
@@ -1,6 +1,6 @@
-import { Position, Range, Selection, TextEditor, TextLine, WorkspaceEdit, workspace } from "vscode";
-import { IDocGen } from "./DocGen";
+import { Position, Range, Selection, TextEditor, TextLine, workspace, WorkspaceEdit } from "vscode";
import { Config, ConfigType } from "../Config";
+import { IDocGen } from "./DocGen";
export default class CGen implements IDocGen {
protected firstLine: string;
@@ -31,12 +31,12 @@ export default class CGen implements IDocGen {
* @param {string[]} returnVals The return values extracted by the parser
*/
public constructor(
- actEdit: TextEditor,
- cursorPosition:
- Position,
- param: string[],
- tparam: string[],
- returnVals: string[]
+ actEdit: TextEditor,
+ cursorPosition:
+ Position,
+ param: string[],
+ tparam: string[],
+ returnVals: string[],
) {
this.activeEditor = actEdit;
this.position = cursorPosition;
@@ -65,9 +65,9 @@ export default class CGen implements IDocGen {
Implementation
***************************************************************************/
- protected readConfig() {
+ protected readConfig() {
const getCfg = workspace.getConfiguration;
-
+
this.firstLine = getCfg(ConfigType.generic).get<string>(Config.firstLine, "");
this.commentPrefix = getCfg(ConfigType.generic).get<string>(Config.commentPrefix, "");
this.lastLine = getCfg(ConfigType.generic).get<string>(Config.lastLine, "");
@@ -115,7 +115,7 @@ export default class CGen implements IDocGen {
}
protected generateComment(): string {
- let lines: string[] = [];
+ const lines: string[] = [];
if (this.firstLine.trim().length !== 0) {
lines.push(this.firstLine);
@@ -144,7 +144,7 @@ export default class CGen implements IDocGen {
if (this.returnTemplate.trim().length !== 0 && this.retVals.length > 0) {
if (this.includeTypeAtReturn === false) {
- this.retVals = this.retVals.map(t => t === "true" || t === "false" ? t : "");
+ this.retVals = this.retVals.map((t) => t === "true" || t === "false" ? t : "");
}
this.generateFromTemplate(lines, this.returnTemplate, this.retVals);