@halcyontech/vscode-ibmi-types 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/CompileTools.d.ts +2 -2
- package/api/Configuration.d.ts +3 -2
- package/api/CustomUI.d.ts +1 -1
- package/api/IBMiContent.d.ts +2 -1
- package/api/Search.d.ts +1 -1
- package/api/Tools.d.ts +1 -0
- package/package.json +1 -1
- package/typings.d.ts +42 -9
- package/api/errors/handler.d.ts +0 -29
- package/api/errors/handlers/new.d.ts +0 -9
- package/api/errors/handlers/old.d.ts +0 -9
package/api/CompileTools.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import vscode from 'vscode';
|
1
|
+
import vscode, { EventEmitter } from 'vscode';
|
2
2
|
import { Action, CommandResult, DeploymentMethod, RemoteCommand } from '../typings';
|
3
3
|
import Instance from './Instance';
|
4
4
|
export interface ILELibrarySettings {
|
@@ -11,5 +11,5 @@ export declare namespace CompileTools {
|
|
11
11
|
/**
|
12
12
|
* Execute a command
|
13
13
|
*/
|
14
|
-
function runCommand(instance: Instance, options: RemoteCommand,
|
14
|
+
function runCommand(instance: Instance, options: RemoteCommand, writeEvent?: EventEmitter<string>): Promise<CommandResult | null>;
|
15
15
|
}
|
package/api/Configuration.d.ts
CHANGED
@@ -1,7 +1,8 @@
|
|
1
|
-
|
1
|
+
import * as vscode from 'vscode';
|
2
2
|
export declare type SourceDateMode = "edit" | "diff";
|
3
|
+
export declare function onCodeForIBMiConfigurationChange<T>(props: string | string[], todo: (value: vscode.ConfigurationChangeEvent) => void): vscode.Disposable;
|
3
4
|
export declare namespace GlobalConfiguration {
|
4
|
-
function get<T>(
|
5
|
+
function get<T>(key: string): T | undefined;
|
5
6
|
function set(key: string, value: any): Thenable<void>;
|
6
7
|
}
|
7
8
|
export declare namespace ConnectionConfiguration {
|
package/api/CustomUI.d.ts
CHANGED
@@ -42,7 +42,7 @@ export declare class Section {
|
|
42
42
|
addComplexTabs(tabs: ComplexTab[], selected?: number): this;
|
43
43
|
addSelect(id: string, label: string, items: SelectItem[], description?: string): this;
|
44
44
|
addTree(id: string, label: string, treeItems: TreeListItem[], description?: string): this;
|
45
|
-
addButtons(...buttons: Button[]): this;
|
45
|
+
addButtons(...buttons: (Button | undefined)[]): this;
|
46
46
|
addField(field: Field): this;
|
47
47
|
}
|
48
48
|
export declare class CustomUI extends Section {
|
package/api/IBMiContent.d.ts
CHANGED
@@ -2,6 +2,7 @@ import { IBMiError, IBMiFile, IBMiMember, IBMiObject, IFSFile, QsysPath } from '
|
|
2
2
|
import { default as IBMi } from './IBMi';
|
3
3
|
import { Tools } from './Tools';
|
4
4
|
declare type Authority = "*ADD" | "*DLT" | "*EXECUTE" | "*READ" | "*UPD" | "*NONE" | "*ALL" | "*CHANGE" | "*USE" | "*EXCLUDE" | "*AUTLMGT";
|
5
|
+
export declare type SortOrder = `name` | `type`;
|
5
6
|
export declare type SortOptions = {
|
6
7
|
order: "name" | "date" | "?";
|
7
8
|
ascending?: boolean;
|
@@ -65,7 +66,7 @@ export default class IBMiContent {
|
|
65
66
|
library: string;
|
66
67
|
object?: string;
|
67
68
|
types?: string[];
|
68
|
-
}, sortOrder?:
|
69
|
+
}, sortOrder?: SortOrder): Promise<IBMiFile[]>;
|
69
70
|
/**
|
70
71
|
* @param lib
|
71
72
|
* @param spf
|
package/api/Search.d.ts
CHANGED
@@ -10,6 +10,6 @@ export declare namespace Search {
|
|
10
10
|
number: number;
|
11
11
|
content: string;
|
12
12
|
}
|
13
|
-
function searchMembers(instance: Instance, library: string, sourceFile: string, memberFilter: string, searchTerm: string,
|
13
|
+
function searchMembers(instance: Instance, library: string, sourceFile: string, memberFilter: string, searchTerm: string, readOnly?: boolean): Promise<Result[]>;
|
14
14
|
function searchIFS(instance: Instance, path: string, searchTerm: string): Promise<Result[]>;
|
15
15
|
}
|
package/api/Tools.d.ts
CHANGED
package/package.json
CHANGED
package/typings.d.ts
CHANGED
@@ -1,9 +1,11 @@
|
|
1
1
|
/// <reference types="node" />
|
2
|
-
import { WorkspaceFolder } from "vscode";
|
3
|
-
import Instance from "./api/Instance";
|
4
2
|
import { Ignore } from 'ignore';
|
3
|
+
import { TreeItem, TreeItemCollapsibleState, WorkspaceFolder } from "vscode";
|
4
|
+
import { ConnectionConfiguration } from './api/Configuration';
|
5
5
|
import { CustomUI } from "./api/CustomUI";
|
6
|
+
import Instance from "./api/Instance";
|
6
7
|
import { Tools } from "./api/Tools";
|
8
|
+
import { ProviderResult } from './api/import/git';
|
7
9
|
import { DeployTools } from "./api/local/deployTools";
|
8
10
|
export interface CodeForIBMi {
|
9
11
|
instance: Instance;
|
@@ -28,6 +30,7 @@ export interface StandardIO {
|
|
28
30
|
* External interface for extensions to call `code-for-ibmi.runCommand`
|
29
31
|
*/
|
30
32
|
export interface RemoteCommand {
|
33
|
+
title?: string;
|
31
34
|
command: string;
|
32
35
|
environment?: "ile" | "qsh" | "pase";
|
33
36
|
cwd?: string;
|
@@ -44,11 +47,13 @@ export interface CommandResult {
|
|
44
47
|
stderr: string;
|
45
48
|
command?: string;
|
46
49
|
}
|
50
|
+
export declare type ActionType = "member" | "streamfile" | "object" | "file";
|
51
|
+
export declare type ActionEnvironment = "ile" | "qsh" | "pase";
|
47
52
|
export interface Action {
|
48
53
|
name: string;
|
49
54
|
command: string;
|
50
|
-
type?:
|
51
|
-
environment:
|
55
|
+
type?: ActionType;
|
56
|
+
environment: ActionEnvironment;
|
52
57
|
extensions?: string[];
|
53
58
|
deployFirst?: boolean;
|
54
59
|
postDownload?: string[];
|
@@ -104,10 +109,6 @@ export interface IBMiError {
|
|
104
109
|
code: string;
|
105
110
|
text: string;
|
106
111
|
}
|
107
|
-
export interface Filter {
|
108
|
-
library: string;
|
109
|
-
filter: string;
|
110
|
-
}
|
111
112
|
export interface FileError {
|
112
113
|
sev: number;
|
113
114
|
lineNum: number;
|
@@ -121,6 +122,38 @@ export interface QsysFsOptions {
|
|
121
122
|
readonly?: boolean;
|
122
123
|
}
|
123
124
|
export declare type IBMiEvent = "connected" | "disconnected" | "deployLocation" | "deploy";
|
124
|
-
export interface
|
125
|
+
export interface WithPath {
|
125
126
|
path: string;
|
126
127
|
}
|
128
|
+
export interface Library extends WithPath {
|
129
|
+
}
|
130
|
+
export declare type FocusOptions = {
|
131
|
+
select?: boolean;
|
132
|
+
focus?: boolean;
|
133
|
+
expand?: boolean | number;
|
134
|
+
};
|
135
|
+
export declare type BrowserItemParameters = {
|
136
|
+
icon?: string;
|
137
|
+
state?: TreeItemCollapsibleState;
|
138
|
+
parent?: BrowserItem;
|
139
|
+
};
|
140
|
+
export declare class BrowserItem extends TreeItem {
|
141
|
+
readonly params?: BrowserItemParameters;
|
142
|
+
constructor(label: string, params?: BrowserItemParameters);
|
143
|
+
get parent(): BrowserItem;
|
144
|
+
getChildren?(): ProviderResult<BrowserItem[]>;
|
145
|
+
refresh?(): void;
|
146
|
+
reveal?(options?: FocusOptions): Thenable<void>;
|
147
|
+
}
|
148
|
+
export interface FilteredItem {
|
149
|
+
filter: ConnectionConfiguration.ObjectFilters;
|
150
|
+
}
|
151
|
+
export interface ObjectItem extends FilteredItem, WithPath {
|
152
|
+
object: IBMiObject;
|
153
|
+
}
|
154
|
+
export interface SourcePhysicalFileItem extends FilteredItem, WithPath {
|
155
|
+
sourceFile: IBMiFile;
|
156
|
+
}
|
157
|
+
export interface MemberItem extends FilteredItem, WithPath {
|
158
|
+
member: IBMiMember;
|
159
|
+
}
|
package/api/errors/handler.d.ts
DELETED
@@ -1,29 +0,0 @@
|
|
1
|
-
import { FileError } from "../../typings";
|
2
|
-
export declare enum RecordType {
|
3
|
-
TIMESTAMP = "TIMESTAMP",
|
4
|
-
PROCESSOR = "PROCESSOR",
|
5
|
-
FILE_ID = "FILEID",
|
6
|
-
FILE_ID_CONT = "FILEIDCONT",
|
7
|
-
FILE_END = "FILEEND",
|
8
|
-
ERROR_INFORMATION = "ERROR",
|
9
|
-
EXPANSION = "EXPANSION",
|
10
|
-
PROGRAM = "PROGRAM",
|
11
|
-
MAP_DEFINE = "MAPDEFINE",
|
12
|
-
MAP_START = "MAPSTART",
|
13
|
-
MAP_END = "MAPEND",
|
14
|
-
FEEDBACK_CODE = "FEEDBACK"
|
15
|
-
}
|
16
|
-
export interface FileId {
|
17
|
-
version: number;
|
18
|
-
sourceId: number;
|
19
|
-
line: number;
|
20
|
-
length: number;
|
21
|
-
filename: string;
|
22
|
-
sourcefileTimestamp: number;
|
23
|
-
tempFlag: number;
|
24
|
-
}
|
25
|
-
export declare function formatName(input: string): string;
|
26
|
-
export declare function formatIFS(path: string): string;
|
27
|
-
export declare function parseErrors(lines: string[]): Map<string, FileError[]>;
|
28
|
-
export declare function getLinesByRecodType(lines: string[], recordType: RecordType, sourceFileId?: number): string[];
|
29
|
-
export declare function getSourcePath(lines: string[], fileId: number): string;
|
@@ -1,9 +0,0 @@
|
|
1
|
-
import { FileError } from '../../../typings';
|
2
|
-
export declare namespace NewHandler {
|
3
|
-
/**
|
4
|
-
* Returns object of files and their errors
|
5
|
-
* @param lines file contents
|
6
|
-
* @returns Errors object
|
7
|
-
*/
|
8
|
-
function parse(lines: string[]): Map<string, FileError[]>;
|
9
|
-
}
|
@@ -1,9 +0,0 @@
|
|
1
|
-
import { FileError } from '../../../typings';
|
2
|
-
export declare namespace OldHandler {
|
3
|
-
/**
|
4
|
-
* Returns object of files and their errors
|
5
|
-
* @param lines file contents
|
6
|
-
* @returns Errors object
|
7
|
-
*/
|
8
|
-
function parse(lines: string[]): Map<string, FileError[]>;
|
9
|
-
}
|