jmri-client 2.2.0 → 2.3.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/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  declare type Protocol = 'http' | 'https';
2
+ declare type FFunction = 'F1' | 'F2' | 'F3' | 'F4' | 'F5' | 'F6' | 'F7' | 'F8' | 'F9' | 'F10' | 'F11' | 'F12';
2
3
  declare class JmriClient {
3
4
  protected readonly _protocol: Protocol;
4
5
  protected readonly _host: string;
@@ -11,5 +12,11 @@ declare class JmriClient {
11
12
  getPower: () => Promise<import("axios").AxiosResponse<any, any>>;
12
13
  setPower: (isOn: boolean) => Promise<import("axios").AxiosResponse<any, any>>;
13
14
  getRoster: () => Promise<import("axios").AxiosResponse<any, any>>;
15
+ getThrottle: (addresses: Array<string>) => Promise<never>;
16
+ setThrottleSpeed: (address: string, value: number) => Promise<never>;
17
+ setThrottleFunction: (address: string, ffunction: FFunction, value: string) => Promise<never>;
18
+ setThrottleDirection: (address: string, value: string) => Promise<never>;
19
+ setTurnout: (address: string, value: string) => Promise<never>;
20
+ getTurnouts: () => Promise<never>;
14
21
  }
15
22
  export { JmriClient };
package/dist/index.js CHANGED
@@ -115,6 +115,36 @@ var JmriClient = /** @class */ (function () {
115
115
  }
116
116
  });
117
117
  }); };
118
+ this.getThrottle = function (addresses) { return __awaiter(_this, void 0, void 0, function () {
119
+ return __generator(this, function (_a) {
120
+ throw new Error("Not Yet Implemented");
121
+ });
122
+ }); };
123
+ this.setThrottleSpeed = function (address, value) { return __awaiter(_this, void 0, void 0, function () {
124
+ return __generator(this, function (_a) {
125
+ throw new Error("Not Yet Implemented");
126
+ });
127
+ }); };
128
+ this.setThrottleFunction = function (address, ffunction, value) { return __awaiter(_this, void 0, void 0, function () {
129
+ return __generator(this, function (_a) {
130
+ throw new Error("Not Yet Implemented");
131
+ });
132
+ }); };
133
+ this.setThrottleDirection = function (address, value) { return __awaiter(_this, void 0, void 0, function () {
134
+ return __generator(this, function (_a) {
135
+ throw new Error("Not Yet Implemented");
136
+ });
137
+ }); };
138
+ this.setTurnout = function (address, value) { return __awaiter(_this, void 0, void 0, function () {
139
+ return __generator(this, function (_a) {
140
+ throw new Error("Not Yet Implemented");
141
+ });
142
+ }); };
143
+ this.getTurnouts = function () { return __awaiter(_this, void 0, void 0, function () {
144
+ return __generator(this, function (_a) {
145
+ throw new Error("Not Yet Implemented");
146
+ });
147
+ }); };
118
148
  this._protocol = protocol;
119
149
  this._host = host;
120
150
  if (port !== undefined)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jmri-client",
3
- "version": "2.2.0",
3
+ "version": "2.3.0",
4
4
  "description": "node client to connect to a JMRI xmlio webservice",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -45,8 +45,7 @@
45
45
  "typescript": "^4.8.3"
46
46
  },
47
47
  "dependencies": {
48
- "axios": "^0.27.2",
49
- "xml2json": "^0.12.0"
48
+ "axios": "^0.27.2"
50
49
  },
51
50
  "files": [
52
51
  "dist",