varlink-js 0.1.1 → 0.1.2
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/chunk-QUYAB4HT.js +42 -0
- package/chunk-QUYAB4HT.js.map +1 -0
- package/chunk-XDPGXLHF.js +90 -0
- package/chunk-XDPGXLHF.js.map +1 -0
- package/client/client.cjs +139 -0
- package/client/client.cjs.map +1 -0
- package/client/client.d.cts +16 -0
- package/client/client.d.ts +16 -0
- package/client/client.js +102 -0
- package/client/client.js.map +1 -0
- package/package.json +4 -3
- package/protocol/protocol.cjs +107 -0
- package/protocol/protocol.cjs.map +1 -0
- package/protocol/protocol.d.cts +42 -0
- package/protocol/protocol.d.ts +42 -0
- package/protocol/protocol.js +19 -0
- package/protocol/protocol.js.map +1 -0
- package/schemas/org.varlink.certification.varlink.cjs +75 -0
- package/schemas/org.varlink.certification.varlink.cjs.map +1 -0
- package/schemas/org.varlink.certification.varlink.d.cts +20 -0
- package/schemas/org.varlink.certification.varlink.d.ts +20 -0
- package/schemas/org.varlink.certification.varlink.js +38 -0
- package/schemas/org.varlink.certification.varlink.js.map +1 -0
- package/schemas/org.varlink.resolver.varlink.cjs +56 -0
- package/schemas/org.varlink.resolver.varlink.cjs.map +1 -0
- package/schemas/org.varlink.resolver.varlink.d.cts +19 -0
- package/schemas/org.varlink.resolver.varlink.d.ts +19 -0
- package/schemas/org.varlink.resolver.varlink.js +24 -0
- package/schemas/org.varlink.resolver.varlink.js.map +1 -0
- package/schemas/org.varlink.service.varlink.cjs +56 -0
- package/schemas/org.varlink.service.varlink.cjs.map +1 -0
- package/schemas/org.varlink.service.varlink.d.cts +19 -0
- package/schemas/org.varlink.service.varlink.d.ts +19 -0
- package/schemas/org.varlink.service.varlink.js +24 -0
- package/schemas/org.varlink.service.varlink.js.map +1 -0
- package/server/server.cjs +168 -0
- package/server/server.cjs.map +1 -0
- package/server/server.d.cts +16 -0
- package/server/server.d.ts +16 -0
- package/server/server.js +130 -0
- package/server/server.js.map +1 -0
- package/transport/node-socket.cjs +247 -0
- package/transport/node-socket.cjs.map +1 -0
- package/transport/node-socket.d.cts +35 -0
- package/transport/node-socket.d.ts +35 -0
- package/{src/transport/node-socket.ts → transport/node-socket.js} +60 -84
- package/transport/node-socket.js.map +1 -0
- package/transport/transport.cjs +109 -0
- package/transport/transport.cjs.map +1 -0
- package/transport/transport.d.cts +31 -0
- package/transport/transport.d.ts +31 -0
- package/transport/transport.js +10 -0
- package/transport/transport.js.map +1 -0
- package/.github/workflows/bun.yml +0 -18
- package/.github/workflows/nodejs.yml +0 -18
- package/eslint.config.cjs +0 -17
- package/src/client/client.test.ts +0 -138
- package/src/client/client.ts +0 -119
- package/src/protocol/protocol.ts +0 -124
- package/src/schemas/org.varlink.certification.varlink +0 -86
- package/src/schemas/org.varlink.certification.varlink.ts +0 -32
- package/src/schemas/org.varlink.resolver.varlink +0 -18
- package/src/schemas/org.varlink.resolver.varlink.ts +0 -25
- package/src/schemas/org.varlink.service.varlink +0 -29
- package/src/schemas/org.varlink.service.varlink.ts +0 -25
- package/src/server/reference-server.ts +0 -436
- package/src/server/run-reference-server.ts +0 -11
- package/src/server/server.test.ts +0 -41
- package/src/server/server.ts +0 -180
- package/src/transport/transport.ts +0 -58
- package/tsconfig.json +0 -27
- package/tsup.config.ts +0 -19
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
type VarlinkDictionary = Record<string, any>;
|
|
2
|
+
declare class VarlinkError extends Error {
|
|
3
|
+
type_: string;
|
|
4
|
+
parameters: VarlinkDictionary;
|
|
5
|
+
constructor(type_: string, parameters: VarlinkDictionary);
|
|
6
|
+
}
|
|
7
|
+
declare class VarlinkMethod<Name extends string, Input extends VarlinkDictionary, Output extends VarlinkDictionary> {
|
|
8
|
+
name: Name;
|
|
9
|
+
private readonly inputPhantom;
|
|
10
|
+
private readonly outputPhantom;
|
|
11
|
+
constructor(name: Name, inputPhantom: Input, outputPhantom: Output);
|
|
12
|
+
}
|
|
13
|
+
type VarlinkMethodGetName<M> = M extends VarlinkMethod<infer Name, any, any> ? Name : never;
|
|
14
|
+
type VarlinkMethodGetInput<M> = M extends VarlinkMethod<any, infer Input, any> ? Input : never;
|
|
15
|
+
type VarlinkMethodGetOutput<M> = M extends VarlinkMethod<any, any, infer Output> ? Output : never;
|
|
16
|
+
declare class VarlinkDynamicMethod extends VarlinkMethod<string, VarlinkDictionary, VarlinkDictionary> {
|
|
17
|
+
constructor(name: string);
|
|
18
|
+
}
|
|
19
|
+
interface VarlinkRequest {
|
|
20
|
+
method: string;
|
|
21
|
+
parameters: VarlinkDictionary;
|
|
22
|
+
oneway: boolean;
|
|
23
|
+
more: boolean;
|
|
24
|
+
upgrade: boolean;
|
|
25
|
+
}
|
|
26
|
+
declare function serializeVarlinkRequest(request: VarlinkRequest): Uint8Array;
|
|
27
|
+
declare function deserializeVarlinkRequest(buffer: Uint8Array): VarlinkRequest;
|
|
28
|
+
interface VarlinkSuccessResponse {
|
|
29
|
+
error: undefined;
|
|
30
|
+
parameters: VarlinkDictionary;
|
|
31
|
+
continues: boolean;
|
|
32
|
+
}
|
|
33
|
+
interface VarlinkErrorResponse {
|
|
34
|
+
error: string;
|
|
35
|
+
parameters: VarlinkDictionary;
|
|
36
|
+
continues: undefined;
|
|
37
|
+
}
|
|
38
|
+
type VarlinkResponse = VarlinkSuccessResponse | VarlinkErrorResponse;
|
|
39
|
+
declare function serializeVarlinkResponse(response: VarlinkResponse): Uint8Array;
|
|
40
|
+
declare function deserializeVarlinkResponse(buffer: Uint8Array): VarlinkResponse;
|
|
41
|
+
|
|
42
|
+
export { type VarlinkDictionary, VarlinkDynamicMethod, VarlinkError, type VarlinkErrorResponse, VarlinkMethod, type VarlinkMethodGetInput, type VarlinkMethodGetName, type VarlinkMethodGetOutput, type VarlinkRequest, type VarlinkResponse, type VarlinkSuccessResponse, deserializeVarlinkRequest, deserializeVarlinkResponse, serializeVarlinkRequest, serializeVarlinkResponse };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import {
|
|
2
|
+
VarlinkDynamicMethod,
|
|
3
|
+
VarlinkError,
|
|
4
|
+
VarlinkMethod,
|
|
5
|
+
deserializeVarlinkRequest,
|
|
6
|
+
deserializeVarlinkResponse,
|
|
7
|
+
serializeVarlinkRequest,
|
|
8
|
+
serializeVarlinkResponse
|
|
9
|
+
} from "../chunk-XDPGXLHF.js";
|
|
10
|
+
export {
|
|
11
|
+
VarlinkDynamicMethod,
|
|
12
|
+
VarlinkError,
|
|
13
|
+
VarlinkMethod,
|
|
14
|
+
deserializeVarlinkRequest,
|
|
15
|
+
deserializeVarlinkResponse,
|
|
16
|
+
serializeVarlinkRequest,
|
|
17
|
+
serializeVarlinkResponse
|
|
18
|
+
};
|
|
19
|
+
//# sourceMappingURL=protocol.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/schemas/org.varlink.certification.varlink.ts
|
|
21
|
+
var org_varlink_certification_varlink_exports = {};
|
|
22
|
+
__export(org_varlink_certification_varlink_exports, {
|
|
23
|
+
OrgVarlinkCertification: () => OrgVarlinkCertification
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(org_varlink_certification_varlink_exports);
|
|
26
|
+
|
|
27
|
+
// src/protocol/protocol.ts
|
|
28
|
+
var VarlinkMethod = class {
|
|
29
|
+
constructor(name, inputPhantom, outputPhantom) {
|
|
30
|
+
this.name = name;
|
|
31
|
+
this.inputPhantom = inputPhantom;
|
|
32
|
+
this.outputPhantom = outputPhantom;
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
var VarlinkDynamicMethod = class extends VarlinkMethod {
|
|
36
|
+
constructor(name) {
|
|
37
|
+
super(name, {}, {});
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
// src/schemas/org.varlink.certification.varlink.ts
|
|
42
|
+
var Start = new VarlinkDynamicMethod("org.varlink.certification.Start");
|
|
43
|
+
var Test01 = new VarlinkDynamicMethod("org.varlink.certification.Test01");
|
|
44
|
+
var Test02 = new VarlinkDynamicMethod("org.varlink.certification.Test02");
|
|
45
|
+
var Test03 = new VarlinkDynamicMethod("org.varlink.certification.Test03");
|
|
46
|
+
var Test04 = new VarlinkDynamicMethod("org.varlink.certification.Test04");
|
|
47
|
+
var Test05 = new VarlinkDynamicMethod("org.varlink.certification.Test05");
|
|
48
|
+
var Test06 = new VarlinkDynamicMethod("org.varlink.certification.Test06");
|
|
49
|
+
var Test07 = new VarlinkDynamicMethod("org.varlink.certification.Test07");
|
|
50
|
+
var Test08 = new VarlinkDynamicMethod("org.varlink.certification.Test08");
|
|
51
|
+
var Test09 = new VarlinkDynamicMethod("org.varlink.certification.Test09");
|
|
52
|
+
var Test10 = new VarlinkDynamicMethod("org.varlink.certification.Test10");
|
|
53
|
+
var Test11 = new VarlinkDynamicMethod("org.varlink.certification.Test11");
|
|
54
|
+
var End = new VarlinkDynamicMethod("org.varlink.certification.End");
|
|
55
|
+
var OrgVarlinkCertification = {
|
|
56
|
+
interface: "org.varlink.certification",
|
|
57
|
+
Start,
|
|
58
|
+
Test01,
|
|
59
|
+
Test02,
|
|
60
|
+
Test03,
|
|
61
|
+
Test04,
|
|
62
|
+
Test05,
|
|
63
|
+
Test06,
|
|
64
|
+
Test07,
|
|
65
|
+
Test08,
|
|
66
|
+
Test09,
|
|
67
|
+
Test10,
|
|
68
|
+
Test11,
|
|
69
|
+
End
|
|
70
|
+
};
|
|
71
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
72
|
+
0 && (module.exports = {
|
|
73
|
+
OrgVarlinkCertification
|
|
74
|
+
});
|
|
75
|
+
//# sourceMappingURL=org.varlink.certification.varlink.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.certification.varlink.ts","../../src/protocol/protocol.ts"],"sourcesContent":["import { VarlinkDynamicMethod } from \"../protocol/protocol\";\n\nconst Start = new VarlinkDynamicMethod(\"org.varlink.certification.Start\");\nconst Test01 = new VarlinkDynamicMethod(\"org.varlink.certification.Test01\");\nconst Test02 = new VarlinkDynamicMethod(\"org.varlink.certification.Test02\");\nconst Test03 = new VarlinkDynamicMethod(\"org.varlink.certification.Test03\");\nconst Test04 = new VarlinkDynamicMethod(\"org.varlink.certification.Test04\");\nconst Test05 = new VarlinkDynamicMethod(\"org.varlink.certification.Test05\");\nconst Test06 = new VarlinkDynamicMethod(\"org.varlink.certification.Test06\");\nconst Test07 = new VarlinkDynamicMethod(\"org.varlink.certification.Test07\");\nconst Test08 = new VarlinkDynamicMethod(\"org.varlink.certification.Test08\");\nconst Test09 = new VarlinkDynamicMethod(\"org.varlink.certification.Test09\");\nconst Test10 = new VarlinkDynamicMethod(\"org.varlink.certification.Test10\");\nconst Test11 = new VarlinkDynamicMethod(\"org.varlink.certification.Test11\");\nconst End = new VarlinkDynamicMethod(\"org.varlink.certification.End\");\n\nexport const OrgVarlinkCertification = {\n interface: \"org.varlink.certification\",\n Start,\n Test01,\n Test02,\n Test03,\n Test04,\n Test05,\n Test06,\n Test07,\n Test08,\n Test09,\n Test10,\n Test11,\n End,\n};\n","export type VarlinkDictionary = Record<string, any>;\n\nexport class VarlinkError extends Error {\n constructor(\n public type_: string,\n public parameters: VarlinkDictionary,\n ) {\n super(`${type_} ${JSON.stringify(parameters)}`);\n this.name = this.constructor.name;\n }\n}\n\nexport class VarlinkMethod<\n Name extends string,\n Input extends VarlinkDictionary,\n Output extends VarlinkDictionary,\n> {\n constructor(\n public name: Name,\n private readonly inputPhantom: Input,\n private readonly outputPhantom: Output,\n ) {}\n}\n\nexport type VarlinkMethodGetName<M> =\n M extends VarlinkMethod<infer Name, any, any> ? Name : never;\nexport type VarlinkMethodGetInput<M> =\n M extends VarlinkMethod<any, infer Input, any> ? Input : never;\nexport type VarlinkMethodGetOutput<M> =\n M extends VarlinkMethod<any, any, infer Output> ? Output : never;\n\nexport class VarlinkDynamicMethod extends VarlinkMethod<\n string,\n VarlinkDictionary,\n VarlinkDictionary\n> {\n constructor(name: string) {\n super(name, {}, {});\n }\n}\n\nexport interface VarlinkRequest {\n method: string;\n parameters: VarlinkDictionary;\n oneway: boolean;\n more: boolean;\n upgrade: boolean;\n}\n\nexport function serializeVarlinkRequest(request: VarlinkRequest): Uint8Array {\n const partial: Partial<VarlinkRequest> = { method: request.method };\n\n if (Object.keys(request.parameters).length > 0) {\n partial.parameters = request.parameters;\n }\n\n if (request.oneway) {\n partial.oneway = request.oneway;\n }\n\n if (request.more) {\n partial.more = request.more;\n }\n\n if (request.upgrade) {\n partial.upgrade = request.upgrade;\n }\n\n return new TextEncoder().encode(JSON.stringify(partial));\n}\n\nexport function deserializeVarlinkRequest(buffer: Uint8Array): VarlinkRequest {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkRequest;\n partial.parameters ||= {};\n partial.oneway ||= false;\n partial.more ||= false;\n partial.upgrade ||= false;\n return partial;\n}\n\nexport interface VarlinkSuccessResponse {\n error: undefined;\n parameters: VarlinkDictionary;\n continues: boolean;\n}\n\nexport interface VarlinkErrorResponse {\n error: string;\n parameters: VarlinkDictionary;\n continues: undefined;\n}\n\nexport type VarlinkResponse = VarlinkSuccessResponse | VarlinkErrorResponse;\n\nexport function serializeVarlinkResponse(\n response: VarlinkResponse,\n): Uint8Array {\n const partial: Partial<VarlinkResponse> = { parameters: response.parameters };\n\n if (response.error !== undefined) {\n partial.error = response.error;\n }\n\n if (response.continues === true) {\n partial.continues = response.continues;\n }\n\n return new TextEncoder().encode(JSON.stringify(response));\n}\n\nexport function deserializeVarlinkResponse(\n buffer: Uint8Array,\n): VarlinkResponse {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkResponse;\n if (partial.error === undefined) {\n partial.continues ||= false;\n }\n\n return partial;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACYO,IAAM,gBAAN,MAIL;AAAA,EACA,YACS,MACU,cACA,eACjB;AAHO;AACU;AACA;AAAA,EAChB;AACL;AASO,IAAM,uBAAN,cAAmC,cAIxC;AAAA,EACA,YAAY,MAAc;AACxB,UAAM,MAAM,CAAC,GAAG,CAAC,CAAC;AAAA,EACpB;AACF;;;ADrCA,IAAM,QAAQ,IAAI,qBAAqB,iCAAiC;AACxE,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,MAAM,IAAI,qBAAqB,+BAA+B;AAE7D,IAAM,0BAA0B;AAAA,EACrC,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;","names":[]}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { VarlinkDynamicMethod } from '../protocol/protocol.cjs';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkCertification: {
|
|
4
|
+
interface: string;
|
|
5
|
+
Start: VarlinkDynamicMethod;
|
|
6
|
+
Test01: VarlinkDynamicMethod;
|
|
7
|
+
Test02: VarlinkDynamicMethod;
|
|
8
|
+
Test03: VarlinkDynamicMethod;
|
|
9
|
+
Test04: VarlinkDynamicMethod;
|
|
10
|
+
Test05: VarlinkDynamicMethod;
|
|
11
|
+
Test06: VarlinkDynamicMethod;
|
|
12
|
+
Test07: VarlinkDynamicMethod;
|
|
13
|
+
Test08: VarlinkDynamicMethod;
|
|
14
|
+
Test09: VarlinkDynamicMethod;
|
|
15
|
+
Test10: VarlinkDynamicMethod;
|
|
16
|
+
Test11: VarlinkDynamicMethod;
|
|
17
|
+
End: VarlinkDynamicMethod;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export { OrgVarlinkCertification };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { VarlinkDynamicMethod } from '../protocol/protocol.js';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkCertification: {
|
|
4
|
+
interface: string;
|
|
5
|
+
Start: VarlinkDynamicMethod;
|
|
6
|
+
Test01: VarlinkDynamicMethod;
|
|
7
|
+
Test02: VarlinkDynamicMethod;
|
|
8
|
+
Test03: VarlinkDynamicMethod;
|
|
9
|
+
Test04: VarlinkDynamicMethod;
|
|
10
|
+
Test05: VarlinkDynamicMethod;
|
|
11
|
+
Test06: VarlinkDynamicMethod;
|
|
12
|
+
Test07: VarlinkDynamicMethod;
|
|
13
|
+
Test08: VarlinkDynamicMethod;
|
|
14
|
+
Test09: VarlinkDynamicMethod;
|
|
15
|
+
Test10: VarlinkDynamicMethod;
|
|
16
|
+
Test11: VarlinkDynamicMethod;
|
|
17
|
+
End: VarlinkDynamicMethod;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
export { OrgVarlinkCertification };
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import {
|
|
2
|
+
VarlinkDynamicMethod
|
|
3
|
+
} from "../chunk-XDPGXLHF.js";
|
|
4
|
+
|
|
5
|
+
// src/schemas/org.varlink.certification.varlink.ts
|
|
6
|
+
var Start = new VarlinkDynamicMethod("org.varlink.certification.Start");
|
|
7
|
+
var Test01 = new VarlinkDynamicMethod("org.varlink.certification.Test01");
|
|
8
|
+
var Test02 = new VarlinkDynamicMethod("org.varlink.certification.Test02");
|
|
9
|
+
var Test03 = new VarlinkDynamicMethod("org.varlink.certification.Test03");
|
|
10
|
+
var Test04 = new VarlinkDynamicMethod("org.varlink.certification.Test04");
|
|
11
|
+
var Test05 = new VarlinkDynamicMethod("org.varlink.certification.Test05");
|
|
12
|
+
var Test06 = new VarlinkDynamicMethod("org.varlink.certification.Test06");
|
|
13
|
+
var Test07 = new VarlinkDynamicMethod("org.varlink.certification.Test07");
|
|
14
|
+
var Test08 = new VarlinkDynamicMethod("org.varlink.certification.Test08");
|
|
15
|
+
var Test09 = new VarlinkDynamicMethod("org.varlink.certification.Test09");
|
|
16
|
+
var Test10 = new VarlinkDynamicMethod("org.varlink.certification.Test10");
|
|
17
|
+
var Test11 = new VarlinkDynamicMethod("org.varlink.certification.Test11");
|
|
18
|
+
var End = new VarlinkDynamicMethod("org.varlink.certification.End");
|
|
19
|
+
var OrgVarlinkCertification = {
|
|
20
|
+
interface: "org.varlink.certification",
|
|
21
|
+
Start,
|
|
22
|
+
Test01,
|
|
23
|
+
Test02,
|
|
24
|
+
Test03,
|
|
25
|
+
Test04,
|
|
26
|
+
Test05,
|
|
27
|
+
Test06,
|
|
28
|
+
Test07,
|
|
29
|
+
Test08,
|
|
30
|
+
Test09,
|
|
31
|
+
Test10,
|
|
32
|
+
Test11,
|
|
33
|
+
End
|
|
34
|
+
};
|
|
35
|
+
export {
|
|
36
|
+
OrgVarlinkCertification
|
|
37
|
+
};
|
|
38
|
+
//# sourceMappingURL=org.varlink.certification.varlink.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.certification.varlink.ts"],"sourcesContent":["import { VarlinkDynamicMethod } from \"../protocol/protocol\";\n\nconst Start = new VarlinkDynamicMethod(\"org.varlink.certification.Start\");\nconst Test01 = new VarlinkDynamicMethod(\"org.varlink.certification.Test01\");\nconst Test02 = new VarlinkDynamicMethod(\"org.varlink.certification.Test02\");\nconst Test03 = new VarlinkDynamicMethod(\"org.varlink.certification.Test03\");\nconst Test04 = new VarlinkDynamicMethod(\"org.varlink.certification.Test04\");\nconst Test05 = new VarlinkDynamicMethod(\"org.varlink.certification.Test05\");\nconst Test06 = new VarlinkDynamicMethod(\"org.varlink.certification.Test06\");\nconst Test07 = new VarlinkDynamicMethod(\"org.varlink.certification.Test07\");\nconst Test08 = new VarlinkDynamicMethod(\"org.varlink.certification.Test08\");\nconst Test09 = new VarlinkDynamicMethod(\"org.varlink.certification.Test09\");\nconst Test10 = new VarlinkDynamicMethod(\"org.varlink.certification.Test10\");\nconst Test11 = new VarlinkDynamicMethod(\"org.varlink.certification.Test11\");\nconst End = new VarlinkDynamicMethod(\"org.varlink.certification.End\");\n\nexport const OrgVarlinkCertification = {\n interface: \"org.varlink.certification\",\n Start,\n Test01,\n Test02,\n Test03,\n Test04,\n Test05,\n Test06,\n Test07,\n Test08,\n Test09,\n Test10,\n Test11,\n End,\n};\n"],"mappings":";;;;;AAEA,IAAM,QAAQ,IAAI,qBAAqB,iCAAiC;AACxE,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,SAAS,IAAI,qBAAqB,kCAAkC;AAC1E,IAAM,MAAM,IAAI,qBAAqB,+BAA+B;AAE7D,IAAM,0BAA0B;AAAA,EACrC,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;","names":[]}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/schemas/org.varlink.resolver.varlink.ts
|
|
21
|
+
var org_varlink_resolver_varlink_exports = {};
|
|
22
|
+
__export(org_varlink_resolver_varlink_exports, {
|
|
23
|
+
OrgVarlinkResolver: () => OrgVarlinkResolver
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(org_varlink_resolver_varlink_exports);
|
|
26
|
+
|
|
27
|
+
// src/protocol/protocol.ts
|
|
28
|
+
var VarlinkMethod = class {
|
|
29
|
+
constructor(name, inputPhantom, outputPhantom) {
|
|
30
|
+
this.name = name;
|
|
31
|
+
this.inputPhantom = inputPhantom;
|
|
32
|
+
this.outputPhantom = outputPhantom;
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
// src/schemas/org.varlink.resolver.varlink.ts
|
|
37
|
+
var GetInfo = new VarlinkMethod(
|
|
38
|
+
"org.varlink.resolver.GetInfo",
|
|
39
|
+
{},
|
|
40
|
+
{}
|
|
41
|
+
);
|
|
42
|
+
var Resolve = new VarlinkMethod(
|
|
43
|
+
"org.varlink.resolver.Resolve",
|
|
44
|
+
{},
|
|
45
|
+
{}
|
|
46
|
+
);
|
|
47
|
+
var OrgVarlinkResolver = {
|
|
48
|
+
interface: "org.varlink.resolver",
|
|
49
|
+
GetInfo,
|
|
50
|
+
Resolve
|
|
51
|
+
};
|
|
52
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
53
|
+
0 && (module.exports = {
|
|
54
|
+
OrgVarlinkResolver
|
|
55
|
+
});
|
|
56
|
+
//# sourceMappingURL=org.varlink.resolver.varlink.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.resolver.varlink.ts","../../src/protocol/protocol.ts"],"sourcesContent":["import { VarlinkMethod } from \"../protocol/protocol\";\n\nconst GetInfo = new VarlinkMethod(\n \"org.varlink.resolver.GetInfo\",\n {} as object,\n {} as {\n interfaces: string[];\n vendor: string;\n product: string;\n version: string;\n url: string;\n },\n);\n\nconst Resolve = new VarlinkMethod(\n \"org.varlink.resolver.Resolve\",\n {} as { interface: string },\n {} as { address: string },\n);\n\nexport const OrgVarlinkResolver = {\n interface: \"org.varlink.resolver\",\n GetInfo,\n Resolve,\n};\n","export type VarlinkDictionary = Record<string, any>;\n\nexport class VarlinkError extends Error {\n constructor(\n public type_: string,\n public parameters: VarlinkDictionary,\n ) {\n super(`${type_} ${JSON.stringify(parameters)}`);\n this.name = this.constructor.name;\n }\n}\n\nexport class VarlinkMethod<\n Name extends string,\n Input extends VarlinkDictionary,\n Output extends VarlinkDictionary,\n> {\n constructor(\n public name: Name,\n private readonly inputPhantom: Input,\n private readonly outputPhantom: Output,\n ) {}\n}\n\nexport type VarlinkMethodGetName<M> =\n M extends VarlinkMethod<infer Name, any, any> ? Name : never;\nexport type VarlinkMethodGetInput<M> =\n M extends VarlinkMethod<any, infer Input, any> ? Input : never;\nexport type VarlinkMethodGetOutput<M> =\n M extends VarlinkMethod<any, any, infer Output> ? Output : never;\n\nexport class VarlinkDynamicMethod extends VarlinkMethod<\n string,\n VarlinkDictionary,\n VarlinkDictionary\n> {\n constructor(name: string) {\n super(name, {}, {});\n }\n}\n\nexport interface VarlinkRequest {\n method: string;\n parameters: VarlinkDictionary;\n oneway: boolean;\n more: boolean;\n upgrade: boolean;\n}\n\nexport function serializeVarlinkRequest(request: VarlinkRequest): Uint8Array {\n const partial: Partial<VarlinkRequest> = { method: request.method };\n\n if (Object.keys(request.parameters).length > 0) {\n partial.parameters = request.parameters;\n }\n\n if (request.oneway) {\n partial.oneway = request.oneway;\n }\n\n if (request.more) {\n partial.more = request.more;\n }\n\n if (request.upgrade) {\n partial.upgrade = request.upgrade;\n }\n\n return new TextEncoder().encode(JSON.stringify(partial));\n}\n\nexport function deserializeVarlinkRequest(buffer: Uint8Array): VarlinkRequest {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkRequest;\n partial.parameters ||= {};\n partial.oneway ||= false;\n partial.more ||= false;\n partial.upgrade ||= false;\n return partial;\n}\n\nexport interface VarlinkSuccessResponse {\n error: undefined;\n parameters: VarlinkDictionary;\n continues: boolean;\n}\n\nexport interface VarlinkErrorResponse {\n error: string;\n parameters: VarlinkDictionary;\n continues: undefined;\n}\n\nexport type VarlinkResponse = VarlinkSuccessResponse | VarlinkErrorResponse;\n\nexport function serializeVarlinkResponse(\n response: VarlinkResponse,\n): Uint8Array {\n const partial: Partial<VarlinkResponse> = { parameters: response.parameters };\n\n if (response.error !== undefined) {\n partial.error = response.error;\n }\n\n if (response.continues === true) {\n partial.continues = response.continues;\n }\n\n return new TextEncoder().encode(JSON.stringify(response));\n}\n\nexport function deserializeVarlinkResponse(\n buffer: Uint8Array,\n): VarlinkResponse {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkResponse;\n if (partial.error === undefined) {\n partial.continues ||= false;\n }\n\n return partial;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACYO,IAAM,gBAAN,MAIL;AAAA,EACA,YACS,MACU,cACA,eACjB;AAHO;AACU;AACA;AAAA,EAChB;AACL;;;ADpBA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AAOH;AAEA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AACH;AAEO,IAAM,qBAAqB;AAAA,EAChC,WAAW;AAAA,EACX;AAAA,EACA;AACF;","names":[]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { VarlinkMethod } from '../protocol/protocol.cjs';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkResolver: {
|
|
4
|
+
interface: string;
|
|
5
|
+
GetInfo: VarlinkMethod<"org.varlink.resolver.GetInfo", object, {
|
|
6
|
+
interfaces: string[];
|
|
7
|
+
vendor: string;
|
|
8
|
+
product: string;
|
|
9
|
+
version: string;
|
|
10
|
+
url: string;
|
|
11
|
+
}>;
|
|
12
|
+
Resolve: VarlinkMethod<"org.varlink.resolver.Resolve", {
|
|
13
|
+
interface: string;
|
|
14
|
+
}, {
|
|
15
|
+
address: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export { OrgVarlinkResolver };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { VarlinkMethod } from '../protocol/protocol.js';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkResolver: {
|
|
4
|
+
interface: string;
|
|
5
|
+
GetInfo: VarlinkMethod<"org.varlink.resolver.GetInfo", object, {
|
|
6
|
+
interfaces: string[];
|
|
7
|
+
vendor: string;
|
|
8
|
+
product: string;
|
|
9
|
+
version: string;
|
|
10
|
+
url: string;
|
|
11
|
+
}>;
|
|
12
|
+
Resolve: VarlinkMethod<"org.varlink.resolver.Resolve", {
|
|
13
|
+
interface: string;
|
|
14
|
+
}, {
|
|
15
|
+
address: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export { OrgVarlinkResolver };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import {
|
|
2
|
+
VarlinkMethod
|
|
3
|
+
} from "../chunk-XDPGXLHF.js";
|
|
4
|
+
|
|
5
|
+
// src/schemas/org.varlink.resolver.varlink.ts
|
|
6
|
+
var GetInfo = new VarlinkMethod(
|
|
7
|
+
"org.varlink.resolver.GetInfo",
|
|
8
|
+
{},
|
|
9
|
+
{}
|
|
10
|
+
);
|
|
11
|
+
var Resolve = new VarlinkMethod(
|
|
12
|
+
"org.varlink.resolver.Resolve",
|
|
13
|
+
{},
|
|
14
|
+
{}
|
|
15
|
+
);
|
|
16
|
+
var OrgVarlinkResolver = {
|
|
17
|
+
interface: "org.varlink.resolver",
|
|
18
|
+
GetInfo,
|
|
19
|
+
Resolve
|
|
20
|
+
};
|
|
21
|
+
export {
|
|
22
|
+
OrgVarlinkResolver
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=org.varlink.resolver.varlink.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.resolver.varlink.ts"],"sourcesContent":["import { VarlinkMethod } from \"../protocol/protocol\";\n\nconst GetInfo = new VarlinkMethod(\n \"org.varlink.resolver.GetInfo\",\n {} as object,\n {} as {\n interfaces: string[];\n vendor: string;\n product: string;\n version: string;\n url: string;\n },\n);\n\nconst Resolve = new VarlinkMethod(\n \"org.varlink.resolver.Resolve\",\n {} as { interface: string },\n {} as { address: string },\n);\n\nexport const OrgVarlinkResolver = {\n interface: \"org.varlink.resolver\",\n GetInfo,\n Resolve,\n};\n"],"mappings":";;;;;AAEA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AAOH;AAEA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AACH;AAEO,IAAM,qBAAqB;AAAA,EAChC,WAAW;AAAA,EACX;AAAA,EACA;AACF;","names":[]}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
|
|
20
|
+
// src/schemas/org.varlink.service.varlink.ts
|
|
21
|
+
var org_varlink_service_varlink_exports = {};
|
|
22
|
+
__export(org_varlink_service_varlink_exports, {
|
|
23
|
+
OrgVarlinkService: () => OrgVarlinkService
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(org_varlink_service_varlink_exports);
|
|
26
|
+
|
|
27
|
+
// src/protocol/protocol.ts
|
|
28
|
+
var VarlinkMethod = class {
|
|
29
|
+
constructor(name, inputPhantom, outputPhantom) {
|
|
30
|
+
this.name = name;
|
|
31
|
+
this.inputPhantom = inputPhantom;
|
|
32
|
+
this.outputPhantom = outputPhantom;
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
// src/schemas/org.varlink.service.varlink.ts
|
|
37
|
+
var GetInfo = new VarlinkMethod(
|
|
38
|
+
"org.varlink.service.GetInfo",
|
|
39
|
+
{},
|
|
40
|
+
{}
|
|
41
|
+
);
|
|
42
|
+
var GetInterfaceDescription = new VarlinkMethod(
|
|
43
|
+
"org.varlink.service.GetInterfaceDescription",
|
|
44
|
+
{},
|
|
45
|
+
{}
|
|
46
|
+
);
|
|
47
|
+
var OrgVarlinkService = {
|
|
48
|
+
interface: "org.varlink.service",
|
|
49
|
+
GetInfo,
|
|
50
|
+
GetInterfaceDescription
|
|
51
|
+
};
|
|
52
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
53
|
+
0 && (module.exports = {
|
|
54
|
+
OrgVarlinkService
|
|
55
|
+
});
|
|
56
|
+
//# sourceMappingURL=org.varlink.service.varlink.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.service.varlink.ts","../../src/protocol/protocol.ts"],"sourcesContent":["import { VarlinkMethod } from \"../protocol/protocol\";\n\nconst GetInfo = new VarlinkMethod(\n \"org.varlink.service.GetInfo\",\n {} as object,\n {} as {\n interfaces: string[];\n vendor: string;\n product: string;\n version: string;\n url: string;\n },\n);\n\nconst GetInterfaceDescription = new VarlinkMethod(\n \"org.varlink.service.GetInterfaceDescription\",\n {} as { interface: string },\n {} as { description: string },\n);\n\nexport const OrgVarlinkService = {\n interface: \"org.varlink.service\",\n GetInfo,\n GetInterfaceDescription,\n};\n","export type VarlinkDictionary = Record<string, any>;\n\nexport class VarlinkError extends Error {\n constructor(\n public type_: string,\n public parameters: VarlinkDictionary,\n ) {\n super(`${type_} ${JSON.stringify(parameters)}`);\n this.name = this.constructor.name;\n }\n}\n\nexport class VarlinkMethod<\n Name extends string,\n Input extends VarlinkDictionary,\n Output extends VarlinkDictionary,\n> {\n constructor(\n public name: Name,\n private readonly inputPhantom: Input,\n private readonly outputPhantom: Output,\n ) {}\n}\n\nexport type VarlinkMethodGetName<M> =\n M extends VarlinkMethod<infer Name, any, any> ? Name : never;\nexport type VarlinkMethodGetInput<M> =\n M extends VarlinkMethod<any, infer Input, any> ? Input : never;\nexport type VarlinkMethodGetOutput<M> =\n M extends VarlinkMethod<any, any, infer Output> ? Output : never;\n\nexport class VarlinkDynamicMethod extends VarlinkMethod<\n string,\n VarlinkDictionary,\n VarlinkDictionary\n> {\n constructor(name: string) {\n super(name, {}, {});\n }\n}\n\nexport interface VarlinkRequest {\n method: string;\n parameters: VarlinkDictionary;\n oneway: boolean;\n more: boolean;\n upgrade: boolean;\n}\n\nexport function serializeVarlinkRequest(request: VarlinkRequest): Uint8Array {\n const partial: Partial<VarlinkRequest> = { method: request.method };\n\n if (Object.keys(request.parameters).length > 0) {\n partial.parameters = request.parameters;\n }\n\n if (request.oneway) {\n partial.oneway = request.oneway;\n }\n\n if (request.more) {\n partial.more = request.more;\n }\n\n if (request.upgrade) {\n partial.upgrade = request.upgrade;\n }\n\n return new TextEncoder().encode(JSON.stringify(partial));\n}\n\nexport function deserializeVarlinkRequest(buffer: Uint8Array): VarlinkRequest {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkRequest;\n partial.parameters ||= {};\n partial.oneway ||= false;\n partial.more ||= false;\n partial.upgrade ||= false;\n return partial;\n}\n\nexport interface VarlinkSuccessResponse {\n error: undefined;\n parameters: VarlinkDictionary;\n continues: boolean;\n}\n\nexport interface VarlinkErrorResponse {\n error: string;\n parameters: VarlinkDictionary;\n continues: undefined;\n}\n\nexport type VarlinkResponse = VarlinkSuccessResponse | VarlinkErrorResponse;\n\nexport function serializeVarlinkResponse(\n response: VarlinkResponse,\n): Uint8Array {\n const partial: Partial<VarlinkResponse> = { parameters: response.parameters };\n\n if (response.error !== undefined) {\n partial.error = response.error;\n }\n\n if (response.continues === true) {\n partial.continues = response.continues;\n }\n\n return new TextEncoder().encode(JSON.stringify(response));\n}\n\nexport function deserializeVarlinkResponse(\n buffer: Uint8Array,\n): VarlinkResponse {\n const partial = JSON.parse(\n new TextDecoder().decode(buffer),\n ) as VarlinkResponse;\n if (partial.error === undefined) {\n partial.continues ||= false;\n }\n\n return partial;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACYO,IAAM,gBAAN,MAIL;AAAA,EACA,YACS,MACU,cACA,eACjB;AAHO;AACU;AACA;AAAA,EAChB;AACL;;;ADpBA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AAOH;AAEA,IAAM,0BAA0B,IAAI;AAAA,EAClC;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AACH;AAEO,IAAM,oBAAoB;AAAA,EAC/B,WAAW;AAAA,EACX;AAAA,EACA;AACF;","names":[]}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { VarlinkMethod } from '../protocol/protocol.cjs';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkService: {
|
|
4
|
+
interface: string;
|
|
5
|
+
GetInfo: VarlinkMethod<"org.varlink.service.GetInfo", object, {
|
|
6
|
+
interfaces: string[];
|
|
7
|
+
vendor: string;
|
|
8
|
+
product: string;
|
|
9
|
+
version: string;
|
|
10
|
+
url: string;
|
|
11
|
+
}>;
|
|
12
|
+
GetInterfaceDescription: VarlinkMethod<"org.varlink.service.GetInterfaceDescription", {
|
|
13
|
+
interface: string;
|
|
14
|
+
}, {
|
|
15
|
+
description: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export { OrgVarlinkService };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { VarlinkMethod } from '../protocol/protocol.js';
|
|
2
|
+
|
|
3
|
+
declare const OrgVarlinkService: {
|
|
4
|
+
interface: string;
|
|
5
|
+
GetInfo: VarlinkMethod<"org.varlink.service.GetInfo", object, {
|
|
6
|
+
interfaces: string[];
|
|
7
|
+
vendor: string;
|
|
8
|
+
product: string;
|
|
9
|
+
version: string;
|
|
10
|
+
url: string;
|
|
11
|
+
}>;
|
|
12
|
+
GetInterfaceDescription: VarlinkMethod<"org.varlink.service.GetInterfaceDescription", {
|
|
13
|
+
interface: string;
|
|
14
|
+
}, {
|
|
15
|
+
description: string;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export { OrgVarlinkService };
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import {
|
|
2
|
+
VarlinkMethod
|
|
3
|
+
} from "../chunk-XDPGXLHF.js";
|
|
4
|
+
|
|
5
|
+
// src/schemas/org.varlink.service.varlink.ts
|
|
6
|
+
var GetInfo = new VarlinkMethod(
|
|
7
|
+
"org.varlink.service.GetInfo",
|
|
8
|
+
{},
|
|
9
|
+
{}
|
|
10
|
+
);
|
|
11
|
+
var GetInterfaceDescription = new VarlinkMethod(
|
|
12
|
+
"org.varlink.service.GetInterfaceDescription",
|
|
13
|
+
{},
|
|
14
|
+
{}
|
|
15
|
+
);
|
|
16
|
+
var OrgVarlinkService = {
|
|
17
|
+
interface: "org.varlink.service",
|
|
18
|
+
GetInfo,
|
|
19
|
+
GetInterfaceDescription
|
|
20
|
+
};
|
|
21
|
+
export {
|
|
22
|
+
OrgVarlinkService
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=org.varlink.service.varlink.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/schemas/org.varlink.service.varlink.ts"],"sourcesContent":["import { VarlinkMethod } from \"../protocol/protocol\";\n\nconst GetInfo = new VarlinkMethod(\n \"org.varlink.service.GetInfo\",\n {} as object,\n {} as {\n interfaces: string[];\n vendor: string;\n product: string;\n version: string;\n url: string;\n },\n);\n\nconst GetInterfaceDescription = new VarlinkMethod(\n \"org.varlink.service.GetInterfaceDescription\",\n {} as { interface: string },\n {} as { description: string },\n);\n\nexport const OrgVarlinkService = {\n interface: \"org.varlink.service\",\n GetInfo,\n GetInterfaceDescription,\n};\n"],"mappings":";;;;;AAEA,IAAM,UAAU,IAAI;AAAA,EAClB;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AAOH;AAEA,IAAM,0BAA0B,IAAI;AAAA,EAClC;AAAA,EACA,CAAC;AAAA,EACD,CAAC;AACH;AAEO,IAAM,oBAAoB;AAAA,EAC/B,WAAW;AAAA,EACX;AAAA,EACA;AACF;","names":[]}
|