@flock/wirespec 0.10.4 → 0.10.8
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/arrow-arrow-atomic.js +2 -2
- package/arrow-arrow-continuations.js +1 -1
- package/arrow-arrow-core.js +18 -18
- package/clikt-clikt.js +1244 -1244
- package/colormath-root-colormath.js +458 -458
- package/kotlin-kotlin-stdlib.js +248 -244
- package/kotlin-kotlin-stdlib.js.map +1 -1
- package/kotlin-openapi-bindings.js +26 -26
- package/kotlin-rgxgen.js +1818 -1818
- package/kotlinx-serialization-kotlinx-serialization-core.js +74 -74
- package/kotlinx-serialization-kotlinx-serialization-json.js +78 -78
- package/markdown.js +1927 -1927
- package/mordant-mordant.js +1713 -1713
- package/package.json +1 -1
- package/wirespec-src-compiler-core.js +2613 -2151
- package/wirespec-src-compiler-core.js.map +1 -1
- package/wirespec-src-compiler-lib.js +286 -286
- package/wirespec-src-converter-openapi.js +311 -311
- package/wirespec-src-plugin-arguments.js +98 -98
- package/wirespec-src-plugin-cli.js +144 -144
- package/wirespec-src-plugin-npm.js +11 -11
- package/wirespec-src-tools-generator.js +26 -26
|
@@ -32,30 +32,30 @@
|
|
|
32
32
|
//region block: imports
|
|
33
33
|
var Unit_instance = kotlin_kotlin.$_$.g4;
|
|
34
34
|
var subcommands = kotlin_clikt_clikt.$_$.c;
|
|
35
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
36
|
-
var initMetadataForCompanion = kotlin_kotlin.$_$.
|
|
35
|
+
var protoOf = kotlin_kotlin.$_$.xa;
|
|
36
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.y9;
|
|
37
37
|
var NoOpCliktCommand = kotlin_clikt_clikt.$_$.b;
|
|
38
38
|
var VOID = kotlin_kotlin.$_$.g;
|
|
39
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
39
|
+
var initMetadataForClass = kotlin_kotlin.$_$.x9;
|
|
40
40
|
var option = kotlin_clikt_clikt.$_$.h;
|
|
41
41
|
var Companion_instance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.x;
|
|
42
42
|
var choice = kotlin_clikt_clikt.$_$.j;
|
|
43
43
|
var multiple = kotlin_clikt_clikt.$_$.g;
|
|
44
44
|
var Compile_instance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.y;
|
|
45
45
|
var Companion_instance_0 = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.z;
|
|
46
|
-
var toSet = kotlin_kotlin.$_$.
|
|
46
|
+
var toSet = kotlin_kotlin.$_$.q8;
|
|
47
47
|
var _PackageName___init__impl__s13tbs = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.t;
|
|
48
48
|
var CompilerArguments = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.a;
|
|
49
49
|
var argument = kotlin_clikt_clikt.$_$.d;
|
|
50
50
|
var values = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.c;
|
|
51
|
-
var mapCapacity = kotlin_kotlin.$_$.
|
|
52
|
-
var coerceAtLeast = kotlin_kotlin.$_$.
|
|
51
|
+
var mapCapacity = kotlin_kotlin.$_$.j7;
|
|
52
|
+
var coerceAtLeast = kotlin_kotlin.$_$.ib;
|
|
53
53
|
var LinkedHashMap_init_$Create$ = kotlin_kotlin.$_$.t;
|
|
54
54
|
var choice_0 = kotlin_clikt_clikt.$_$.i;
|
|
55
55
|
var Language_Wirespec_getInstance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.p;
|
|
56
|
-
var listOf = kotlin_kotlin.$_$.
|
|
56
|
+
var listOf = kotlin_kotlin.$_$.h7;
|
|
57
57
|
var Convert = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.g;
|
|
58
|
-
var setOf = kotlin_kotlin.$_$.
|
|
58
|
+
var setOf = kotlin_kotlin.$_$.v7;
|
|
59
59
|
var CliktCommand = kotlin_clikt_clikt.$_$.a;
|
|
60
60
|
var default_0 = kotlin_clikt_clikt.$_$.e;
|
|
61
61
|
var Companion_instance_1 = kotlin_community_flock_wirespec_compiler_core.$_$.g2;
|
|
@@ -64,22 +64,22 @@
|
|
|
64
64
|
var Companion_instance_2 = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.w;
|
|
65
65
|
var FullDirPath = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.d;
|
|
66
66
|
var Console_instance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.v;
|
|
67
|
-
var toString = kotlin_kotlin.$_$.
|
|
67
|
+
var toString = kotlin_kotlin.$_$.bb;
|
|
68
68
|
var IllegalStateException_init_$Create$ = kotlin_kotlin.$_$.l1;
|
|
69
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
70
|
-
var isCharSequence = kotlin_kotlin.$_$.
|
|
71
|
-
var trim = kotlin_kotlin.$_$.
|
|
69
|
+
var THROW_CCE = kotlin_kotlin.$_$.if;
|
|
70
|
+
var isCharSequence = kotlin_kotlin.$_$.ha;
|
|
71
|
+
var trim = kotlin_kotlin.$_$.pe;
|
|
72
72
|
var Level_DEBUG_getInstance = kotlin_community_flock_wirespec_compiler_core.$_$.x1;
|
|
73
73
|
var Level_INFO_getInstance = kotlin_community_flock_wirespec_compiler_core.$_$.z1;
|
|
74
74
|
var Level_WARN_getInstance = kotlin_community_flock_wirespec_compiler_core.$_$.a2;
|
|
75
|
-
var Enum = kotlin_kotlin.$_$.
|
|
76
|
-
var KProperty1 = kotlin_kotlin.$_$.
|
|
77
|
-
var getPropertyCallableRef = kotlin_kotlin.$_$.
|
|
78
|
-
var numberRangeToNumber = kotlin_kotlin.$_$.
|
|
75
|
+
var Enum = kotlin_kotlin.$_$.ye;
|
|
76
|
+
var KProperty1 = kotlin_kotlin.$_$.sb;
|
|
77
|
+
var getPropertyCallableRef = kotlin_kotlin.$_$.u9;
|
|
78
|
+
var numberRangeToNumber = kotlin_kotlin.$_$.ra;
|
|
79
79
|
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.l;
|
|
80
80
|
var copyToArray = kotlin_kotlin.$_$.x5;
|
|
81
81
|
var Logger = kotlin_community_flock_wirespec_compiler_core.$_$.j1;
|
|
82
|
-
var noWhenBranchMatchedException = kotlin_kotlin.$_$.
|
|
82
|
+
var noWhenBranchMatchedException = kotlin_kotlin.$_$.eg;
|
|
83
83
|
var FileExtension_Wirespec_getInstance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.o;
|
|
84
84
|
var FullFilePath = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.e;
|
|
85
85
|
var Console = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.b;
|
|
@@ -88,15 +88,15 @@
|
|
|
88
88
|
var OpenApiV3Parser_instance = kotlin_community_flock_wirespec_converter_openapi.$_$.d;
|
|
89
89
|
var collectionSizeOrDefault = kotlin_kotlin.$_$.i5;
|
|
90
90
|
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.k;
|
|
91
|
-
var to = kotlin_kotlin.$_$.
|
|
91
|
+
var to = kotlin_kotlin.$_$.hg;
|
|
92
92
|
var _FileName___get_value__impl__3u4cz6 = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.r;
|
|
93
|
-
var charSequenceLength = kotlin_kotlin.$_$.
|
|
94
|
-
var charSequenceGet = kotlin_kotlin.$_$.
|
|
93
|
+
var charSequenceLength = kotlin_kotlin.$_$.m9;
|
|
94
|
+
var charSequenceGet = kotlin_kotlin.$_$.l9;
|
|
95
95
|
var toString_0 = kotlin_kotlin.$_$.z1;
|
|
96
96
|
var first = kotlin_kotlin.$_$.h6;
|
|
97
97
|
var Emitted = kotlin_community_flock_wirespec_compiler_core.$_$.a;
|
|
98
98
|
var _FileName___init__impl__nzn12e = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.q;
|
|
99
|
-
var print = kotlin_kotlin.$_$.
|
|
99
|
+
var print = kotlin_kotlin.$_$.e9;
|
|
100
100
|
var PackageName = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.i;
|
|
101
101
|
var component1 = kotlin_community_flock_wirespec_compiler_core.$_$.h1;
|
|
102
102
|
var JavaEmitter = kotlin_community_flock_wirespec_compiler_core.$_$.b;
|
|
@@ -115,35 +115,35 @@
|
|
|
115
115
|
var Left = kotlin_io_arrow_kt_arrow_core.$_$.d;
|
|
116
116
|
var Companion_getInstance = kotlin_community_flock_wirespec_compiler_core.$_$.d2;
|
|
117
117
|
var Right = kotlin_io_arrow_kt_arrow_core.$_$.e;
|
|
118
|
-
var println = kotlin_kotlin.$_$.
|
|
118
|
+
var println = kotlin_kotlin.$_$.c9;
|
|
119
119
|
var Output = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.h;
|
|
120
|
-
var ensureNotNull = kotlin_kotlin.$_$.
|
|
120
|
+
var ensureNotNull = kotlin_kotlin.$_$.yf;
|
|
121
121
|
var _Output___get_value__impl__a8kw1g = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.s;
|
|
122
122
|
var _PackageName___get_value__impl__2zr98c = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.u;
|
|
123
123
|
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.v1;
|
|
124
|
-
var charArrayOf = kotlin_kotlin.$_$.
|
|
125
|
-
var split = kotlin_kotlin.$_$.
|
|
124
|
+
var charArrayOf = kotlin_kotlin.$_$.j9;
|
|
125
|
+
var split = kotlin_kotlin.$_$.nd;
|
|
126
126
|
var joinToString = kotlin_kotlin.$_$.s6;
|
|
127
127
|
var FileExtension_Json_getInstance = kotlin_community_flock_wirespec_plugin_arguments_arguments.$_$.k;
|
|
128
128
|
var parse = kotlin_community_flock_wirespec_compiler_core.$_$.i1;
|
|
129
129
|
var get_noLogger = kotlin_community_flock_wirespec_compiler_core.$_$.k1;
|
|
130
130
|
var Definition = kotlin_community_flock_wirespec_compiler_core.$_$.k;
|
|
131
|
-
var isInterface = kotlin_kotlin.$_$.
|
|
131
|
+
var isInterface = kotlin_kotlin.$_$.la;
|
|
132
132
|
var produce = kotlin_community_flock_wirespec_compiler_lib.$_$.e;
|
|
133
|
-
var endsWith = kotlin_kotlin.$_$.
|
|
134
|
-
var dropLast = kotlin_kotlin.$_$.
|
|
135
|
-
var iterator = kotlin_kotlin.$_$.
|
|
136
|
-
var asSequence = kotlin_kotlin.$_$.
|
|
137
|
-
var map = kotlin_kotlin.$_$.
|
|
138
|
-
var filter = kotlin_kotlin.$_$.
|
|
139
|
-
var toSet_0 = kotlin_kotlin.$_$.
|
|
140
|
-
var split_0 = kotlin_kotlin.$_$.
|
|
133
|
+
var endsWith = kotlin_kotlin.$_$.nc;
|
|
134
|
+
var dropLast = kotlin_kotlin.$_$.kc;
|
|
135
|
+
var iterator = kotlin_kotlin.$_$.oa;
|
|
136
|
+
var asSequence = kotlin_kotlin.$_$.ub;
|
|
137
|
+
var map = kotlin_kotlin.$_$.zb;
|
|
138
|
+
var filter = kotlin_kotlin.$_$.vb;
|
|
139
|
+
var toSet_0 = kotlin_kotlin.$_$.bc;
|
|
140
|
+
var split_0 = kotlin_kotlin.$_$.od;
|
|
141
141
|
var Companion_instance_3 = kotlin_kotlin.$_$.b4;
|
|
142
142
|
var _Result___init__impl__xyqfz8 = kotlin_kotlin.$_$.a2;
|
|
143
|
-
var createFailure = kotlin_kotlin.$_$.
|
|
143
|
+
var createFailure = kotlin_kotlin.$_$.xf;
|
|
144
144
|
var _Result___get_value__impl__bjfvqg = kotlin_kotlin.$_$.d2;
|
|
145
145
|
var _Result___get_isFailure__impl__jpiriv = kotlin_kotlin.$_$.b2;
|
|
146
|
-
var isArray = kotlin_kotlin.$_$.
|
|
146
|
+
var isArray = kotlin_kotlin.$_$.da;
|
|
147
147
|
//endregion
|
|
148
148
|
//region block: pre-declaration
|
|
149
149
|
initMetadataForCompanion(Companion);
|
|
@@ -163,7 +163,7 @@
|
|
|
163
163
|
//endregion
|
|
164
164
|
function WirespecCli$main$ref($boundThis) {
|
|
165
165
|
var l = function (p0) {
|
|
166
|
-
$boundThis.
|
|
166
|
+
$boundThis.e3v(p0);
|
|
167
167
|
return Unit_instance;
|
|
168
168
|
};
|
|
169
169
|
l.callableName = 'main';
|
|
@@ -171,7 +171,7 @@
|
|
|
171
171
|
}
|
|
172
172
|
function Companion() {
|
|
173
173
|
}
|
|
174
|
-
protoOf(Companion).
|
|
174
|
+
protoOf(Companion).j47 = function (compile, convert) {
|
|
175
175
|
return WirespecCli$main$ref(subcommands(new WirespecCli(), [new Compile_0(compile), new Convert_0(convert)]));
|
|
176
176
|
};
|
|
177
177
|
var Companion_instance_4;
|
|
@@ -182,28 +182,28 @@
|
|
|
182
182
|
NoOpCliktCommand.call(this, VOID, VOID, 'wirespec');
|
|
183
183
|
}
|
|
184
184
|
function _get_languages__ojonze($this) {
|
|
185
|
-
return $this.
|
|
185
|
+
return $this.j48_1.q44($this, languages$factory_0());
|
|
186
186
|
}
|
|
187
187
|
function Compile_0(block) {
|
|
188
188
|
CommonOptions.call(this);
|
|
189
|
-
this.
|
|
190
|
-
this.
|
|
189
|
+
this.i48_1 = block;
|
|
190
|
+
this.j48_1 = multiple(choice(option(this, Options_Language_getInstance().m48_1.slice(), 'Language'), Companion_instance.j2f()), VOID, true).b45(this, languages$factory());
|
|
191
191
|
}
|
|
192
|
-
protoOf(Compile_0).
|
|
192
|
+
protoOf(Compile_0).f3v = function () {
|
|
193
193
|
// Inline function 'kotlin.let' call
|
|
194
|
-
var this_0 = new CompilerArguments(Compile_instance, this.
|
|
194
|
+
var this_0 = new CompilerArguments(Compile_instance, this.m49(this.l49()), Companion_instance_0.k2f(this.n49()), toSet(_get_languages__ojonze(this)), _PackageName___init__impl__s13tbs(this.o49()), this.q49(this.p49()), this.r49(), this.s49());
|
|
195
195
|
// Inline function 'kotlin.contracts.contract' call
|
|
196
|
-
this.
|
|
196
|
+
this.i48_1(this_0);
|
|
197
197
|
};
|
|
198
198
|
function _get_format__qlarck($this) {
|
|
199
|
-
return $this.
|
|
199
|
+
return $this.s4a_1.q44($this, format$factory_0());
|
|
200
200
|
}
|
|
201
201
|
function _get_languages__ojonze_0($this) {
|
|
202
|
-
return $this.
|
|
202
|
+
return $this.t4a_1.q44($this, languages$factory_2());
|
|
203
203
|
}
|
|
204
204
|
function Convert_0(block) {
|
|
205
205
|
CommonOptions.call(this);
|
|
206
|
-
this.
|
|
206
|
+
this.r4a_1 = block;
|
|
207
207
|
var tmp = this;
|
|
208
208
|
// Inline function 'com.github.ajalt.clikt.parameters.types.enum' call
|
|
209
209
|
var this_0 = argument(this, VOID, 'Input format');
|
|
@@ -223,21 +223,21 @@
|
|
|
223
223
|
var tmp$ret$2 = element.p2_1;
|
|
224
224
|
destination.m2(tmp$ret$2, element);
|
|
225
225
|
}
|
|
226
|
-
tmp.
|
|
227
|
-
this.
|
|
226
|
+
tmp.s4a_1 = choice_0(this_0, destination, true).w43(this, format$factory());
|
|
227
|
+
this.t4a_1 = multiple(choice(option(this, Options_Language_getInstance().m48_1.slice(), 'Language'), Companion_instance.j2f(), VOID, true), listOf(Language_Wirespec_getInstance())).b45(this, languages$factory_1());
|
|
228
228
|
}
|
|
229
|
-
protoOf(Convert_0).
|
|
230
|
-
if (this.
|
|
229
|
+
protoOf(Convert_0).f3v = function () {
|
|
230
|
+
if (this.l49() == null)
|
|
231
231
|
null;
|
|
232
232
|
else {
|
|
233
233
|
// Inline function 'kotlin.let' call
|
|
234
234
|
// Inline function 'kotlin.contracts.contract' call
|
|
235
|
-
this.
|
|
235
|
+
this.y3u('To convert, please specify a file', VOID, true);
|
|
236
236
|
}
|
|
237
237
|
// Inline function 'kotlin.let' call
|
|
238
238
|
var tmp = new Convert(_get_format__qlarck(this));
|
|
239
|
-
var tmp_0 = this.
|
|
240
|
-
var tmp_1 = Companion_instance_0.
|
|
239
|
+
var tmp_0 = this.m49(null);
|
|
240
|
+
var tmp_1 = Companion_instance_0.k2f(this.n49());
|
|
241
241
|
// Inline function 'kotlin.collections.ifEmpty' call
|
|
242
242
|
var this_0 = toSet(_get_languages__ojonze_0(this));
|
|
243
243
|
// Inline function 'kotlin.contracts.contract' call
|
|
@@ -249,42 +249,42 @@
|
|
|
249
249
|
tmp_2 = this_0;
|
|
250
250
|
}
|
|
251
251
|
var tmp$ret$2 = tmp_2;
|
|
252
|
-
var this_1 = new CompilerArguments(tmp, tmp_0, tmp_1, tmp$ret$2, _PackageName___init__impl__s13tbs(this.
|
|
252
|
+
var this_1 = new CompilerArguments(tmp, tmp_0, tmp_1, tmp$ret$2, _PackageName___init__impl__s13tbs(this.o49()), this.q49(this.p49()), this.r49(), this.s49());
|
|
253
253
|
// Inline function 'kotlin.contracts.contract' call
|
|
254
|
-
this.
|
|
254
|
+
this.r4a_1(this_1);
|
|
255
255
|
};
|
|
256
256
|
function _get_inputFile__x1bqj($this) {
|
|
257
|
-
return $this.
|
|
257
|
+
return $this.e49_1.q44($this, inputFile$factory_0());
|
|
258
258
|
}
|
|
259
259
|
function CommonOptions() {
|
|
260
260
|
CliktCommand.call(this);
|
|
261
|
-
this.
|
|
262
|
-
this.
|
|
263
|
-
this.
|
|
264
|
-
this.
|
|
265
|
-
this.
|
|
266
|
-
this.
|
|
267
|
-
this.
|
|
268
|
-
}
|
|
269
|
-
protoOf(CommonOptions).
|
|
270
|
-
return this.
|
|
261
|
+
this.e49_1 = option(this, Options_InputFile_getInstance().m48_1.slice(), 'Input file').b45(this, inputFile$factory());
|
|
262
|
+
this.f49_1 = option(this, Options_InputDir_getInstance().m48_1.slice(), 'Input directory').b45(this, inputDir$factory());
|
|
263
|
+
this.g49_1 = option(this, Options_OutputDir_getInstance().m48_1.slice(), 'Output directory').b45(this, outputDir$factory());
|
|
264
|
+
this.h49_1 = default_0(option(this, Options_PackageName_getInstance().m48_1.slice(), 'Package name'), 'community.flock.wirespec.generated').b45(this, packageName$factory());
|
|
265
|
+
this.i49_1 = default_0(option(this, Options_LogLevel_getInstance().m48_1.slice(), 'Log level: ' + Companion_instance_1.toString()), Level_ERROR_getInstance().toString()).b45(this, logLevel$factory());
|
|
266
|
+
this.j49_1 = flag(option(this, Options_Shared_getInstance().m48_1.slice(), 'Generate shared wirespec code'), [], false).b45(this, shared$factory());
|
|
267
|
+
this.k49_1 = flag(option(this, Options_Strict_getInstance().m48_1.slice(), 'Strict mode'), []).b45(this, strict$factory());
|
|
268
|
+
}
|
|
269
|
+
protoOf(CommonOptions).l49 = function () {
|
|
270
|
+
return this.f49_1.q44(this, inputDir$factory_0());
|
|
271
271
|
};
|
|
272
|
-
protoOf(CommonOptions).
|
|
273
|
-
return this.
|
|
272
|
+
protoOf(CommonOptions).n49 = function () {
|
|
273
|
+
return this.g49_1.q44(this, outputDir$factory_0());
|
|
274
274
|
};
|
|
275
|
-
protoOf(CommonOptions).
|
|
276
|
-
return this.
|
|
275
|
+
protoOf(CommonOptions).o49 = function () {
|
|
276
|
+
return this.h49_1.q44(this, packageName$factory_0());
|
|
277
277
|
};
|
|
278
|
-
protoOf(CommonOptions).
|
|
279
|
-
return this.
|
|
278
|
+
protoOf(CommonOptions).p49 = function () {
|
|
279
|
+
return this.i49_1.q44(this, logLevel$factory_0());
|
|
280
280
|
};
|
|
281
|
-
protoOf(CommonOptions).
|
|
282
|
-
return this.
|
|
281
|
+
protoOf(CommonOptions).r49 = function () {
|
|
282
|
+
return this.j49_1.q44(this, shared$factory_0());
|
|
283
283
|
};
|
|
284
|
-
protoOf(CommonOptions).
|
|
285
|
-
return this.
|
|
284
|
+
protoOf(CommonOptions).s49 = function () {
|
|
285
|
+
return this.k49_1.q44(this, strict$factory_0());
|
|
286
286
|
};
|
|
287
|
-
protoOf(CommonOptions).
|
|
287
|
+
protoOf(CommonOptions).m49 = function (inputDir) {
|
|
288
288
|
var tmp;
|
|
289
289
|
if (!(inputDir == null) && !(_get_inputFile__x1bqj(this) == null)) {
|
|
290
290
|
var message = 'Choose either a file or a directory. Not Both.';
|
|
@@ -297,7 +297,7 @@
|
|
|
297
297
|
} else {
|
|
298
298
|
// Inline function 'kotlin.let' call
|
|
299
299
|
// Inline function 'kotlin.contracts.contract' call
|
|
300
|
-
tmp_0 = Companion_instance_2.
|
|
300
|
+
tmp_0 = Companion_instance_2.y2e(tmp0_safe_receiver);
|
|
301
301
|
}
|
|
302
302
|
var tmp0_elvis_lhs = tmp_0;
|
|
303
303
|
var tmp_1;
|
|
@@ -319,7 +319,7 @@
|
|
|
319
319
|
}
|
|
320
320
|
return tmp;
|
|
321
321
|
};
|
|
322
|
-
protoOf(CommonOptions).
|
|
322
|
+
protoOf(CommonOptions).q49 = function (_this__u8e3s4) {
|
|
323
323
|
// Inline function 'kotlin.text.uppercase' call
|
|
324
324
|
// Inline function 'kotlin.text.trim' call
|
|
325
325
|
// Inline function 'kotlin.js.asDynamic' call
|
|
@@ -367,7 +367,7 @@
|
|
|
367
367
|
}
|
|
368
368
|
function Options(name, ordinal, flags) {
|
|
369
369
|
Enum.call(this, name, ordinal);
|
|
370
|
-
this.
|
|
370
|
+
this.m48_1 = flags;
|
|
371
371
|
}
|
|
372
372
|
function Options_InputDir_getInstance() {
|
|
373
373
|
Options_initEntries();
|
|
@@ -438,32 +438,32 @@
|
|
|
438
438
|
}
|
|
439
439
|
function inputDir$factory() {
|
|
440
440
|
return getPropertyCallableRef('inputDir', 1, KProperty1, function (receiver) {
|
|
441
|
-
return receiver.
|
|
441
|
+
return receiver.l49();
|
|
442
442
|
}, null);
|
|
443
443
|
}
|
|
444
444
|
function outputDir$factory() {
|
|
445
445
|
return getPropertyCallableRef('outputDir', 1, KProperty1, function (receiver) {
|
|
446
|
-
return receiver.
|
|
446
|
+
return receiver.n49();
|
|
447
447
|
}, null);
|
|
448
448
|
}
|
|
449
449
|
function packageName$factory() {
|
|
450
450
|
return getPropertyCallableRef('packageName', 1, KProperty1, function (receiver) {
|
|
451
|
-
return receiver.
|
|
451
|
+
return receiver.o49();
|
|
452
452
|
}, null);
|
|
453
453
|
}
|
|
454
454
|
function logLevel$factory() {
|
|
455
455
|
return getPropertyCallableRef('logLevel', 1, KProperty1, function (receiver) {
|
|
456
|
-
return receiver.
|
|
456
|
+
return receiver.p49();
|
|
457
457
|
}, null);
|
|
458
458
|
}
|
|
459
459
|
function shared$factory() {
|
|
460
460
|
return getPropertyCallableRef('shared', 1, KProperty1, function (receiver) {
|
|
461
|
-
return receiver.
|
|
461
|
+
return receiver.r49();
|
|
462
462
|
}, null);
|
|
463
463
|
}
|
|
464
464
|
function strict$factory() {
|
|
465
465
|
return getPropertyCallableRef('strict', 1, KProperty1, function (receiver) {
|
|
466
|
-
return receiver.
|
|
466
|
+
return receiver.s49();
|
|
467
467
|
}, null);
|
|
468
468
|
}
|
|
469
469
|
function inputFile$factory_0() {
|
|
@@ -473,32 +473,32 @@
|
|
|
473
473
|
}
|
|
474
474
|
function inputDir$factory_0() {
|
|
475
475
|
return getPropertyCallableRef('inputDir', 1, KProperty1, function (receiver) {
|
|
476
|
-
return receiver.
|
|
476
|
+
return receiver.l49();
|
|
477
477
|
}, null);
|
|
478
478
|
}
|
|
479
479
|
function outputDir$factory_0() {
|
|
480
480
|
return getPropertyCallableRef('outputDir', 1, KProperty1, function (receiver) {
|
|
481
|
-
return receiver.
|
|
481
|
+
return receiver.n49();
|
|
482
482
|
}, null);
|
|
483
483
|
}
|
|
484
484
|
function packageName$factory_0() {
|
|
485
485
|
return getPropertyCallableRef('packageName', 1, KProperty1, function (receiver) {
|
|
486
|
-
return receiver.
|
|
486
|
+
return receiver.o49();
|
|
487
487
|
}, null);
|
|
488
488
|
}
|
|
489
489
|
function logLevel$factory_0() {
|
|
490
490
|
return getPropertyCallableRef('logLevel', 1, KProperty1, function (receiver) {
|
|
491
|
-
return receiver.
|
|
491
|
+
return receiver.p49();
|
|
492
492
|
}, null);
|
|
493
493
|
}
|
|
494
494
|
function shared$factory_0() {
|
|
495
495
|
return getPropertyCallableRef('shared', 1, KProperty1, function (receiver) {
|
|
496
|
-
return receiver.
|
|
496
|
+
return receiver.r49();
|
|
497
497
|
}, null);
|
|
498
498
|
}
|
|
499
499
|
function strict$factory_0() {
|
|
500
500
|
return getPropertyCallableRef('strict', 1, KProperty1, function (receiver) {
|
|
501
|
-
return receiver.
|
|
501
|
+
return receiver.s49();
|
|
502
502
|
}, null);
|
|
503
503
|
}
|
|
504
504
|
function main(args) {
|
|
@@ -526,27 +526,27 @@
|
|
|
526
526
|
var tmp = Companion_instance_4;
|
|
527
527
|
var tmp_0 = compile$ref();
|
|
528
528
|
// Inline function 'kotlin.contracts.contract' call
|
|
529
|
-
tmp.
|
|
529
|
+
tmp.j47(tmp_0, convert$ref())(this_1);
|
|
530
530
|
}
|
|
531
531
|
function compile_0(arguments_0) {
|
|
532
|
-
var input = arguments_0.
|
|
533
|
-
var output = arguments_0.
|
|
534
|
-
var languages = arguments_0.
|
|
535
|
-
var packageName = arguments_0.
|
|
536
|
-
var logger = new Logger(arguments_0.
|
|
537
|
-
var operation = arguments_0.
|
|
532
|
+
var input = arguments_0.p2e_1;
|
|
533
|
+
var output = arguments_0.q2e_1;
|
|
534
|
+
var languages = arguments_0.r2e_1;
|
|
535
|
+
var packageName = arguments_0.s2e_1;
|
|
536
|
+
var logger = new Logger(arguments_0.t2e_1);
|
|
537
|
+
var operation = arguments_0.o2e_1;
|
|
538
538
|
if (operation instanceof Convert) {
|
|
539
539
|
var fullPath = input instanceof FullFilePath ? input : THROW_CCE();
|
|
540
540
|
var file = new JsonFile(fullPath);
|
|
541
|
-
var strict = arguments_0.
|
|
542
|
-
var format = operation.
|
|
541
|
+
var strict = arguments_0.v2e_1;
|
|
542
|
+
var format = operation.x2e_1;
|
|
543
543
|
var tmp;
|
|
544
544
|
switch (format.q2_1) {
|
|
545
545
|
case 0:
|
|
546
|
-
tmp = OpenApiV2Parser_instance.
|
|
546
|
+
tmp = OpenApiV2Parser_instance.a2g(file.y1a(), !strict);
|
|
547
547
|
break;
|
|
548
548
|
case 1:
|
|
549
|
-
tmp = OpenApiV3Parser_instance.
|
|
549
|
+
tmp = OpenApiV3Parser_instance.a2g(file.y1a(), !strict);
|
|
550
550
|
break;
|
|
551
551
|
default:
|
|
552
552
|
noWhenBranchMatchedException();
|
|
@@ -569,7 +569,7 @@
|
|
|
569
569
|
var tmp_0;
|
|
570
570
|
if (!emitter.n22_1) {
|
|
571
571
|
// Inline function 'kotlin.text.replaceFirstChar' call
|
|
572
|
-
var this_1 = _FileName___get_value__impl__3u4cz6(fullPath.
|
|
572
|
+
var this_1 = _FileName___get_value__impl__3u4cz6(fullPath.d2f_1);
|
|
573
573
|
var tmp_1;
|
|
574
574
|
// Inline function 'kotlin.text.isNotEmpty' call
|
|
575
575
|
if (charSequenceLength(this_1) > 0) {
|
|
@@ -586,7 +586,7 @@
|
|
|
586
586
|
tmp_1 = this_1;
|
|
587
587
|
}
|
|
588
588
|
var tmp$ret$6 = tmp_1;
|
|
589
|
-
tmp_0 = to(listOf(new Emitted(tmp$ret$6, first(results).
|
|
589
|
+
tmp_0 = to(listOf(new Emitted(tmp$ret$6, first(results).j25_1)), file_0);
|
|
590
590
|
} else {
|
|
591
591
|
tmp_0 = to(results, file_0);
|
|
592
592
|
}
|
|
@@ -610,19 +610,19 @@
|
|
|
610
610
|
} else {
|
|
611
611
|
if (input instanceof FullDirPath) {
|
|
612
612
|
// Inline function 'kotlin.collections.forEach' call
|
|
613
|
-
var tmp0_iterator_1 = (new Directory(input.
|
|
613
|
+
var tmp0_iterator_1 = (new Directory(input.i2f_1)).w4a().g();
|
|
614
614
|
while (tmp0_iterator_1.h()) {
|
|
615
615
|
var element = tmp0_iterator_1.i();
|
|
616
616
|
// Inline function 'community.flock.wirespec.plugin.cli.compile.<anonymous>' call
|
|
617
|
-
wirespec(element, languages, packageName, out(element.
|
|
617
|
+
wirespec(element, languages, packageName, out(element.u4a_1, packageName, output), logger);
|
|
618
618
|
}
|
|
619
619
|
} else {
|
|
620
620
|
if (input instanceof FullFilePath)
|
|
621
|
-
if (input.
|
|
621
|
+
if (input.e2f_1.equals(FileExtension_Wirespec_getInstance())) {
|
|
622
622
|
// Inline function 'kotlin.let' call
|
|
623
623
|
// Inline function 'kotlin.contracts.contract' call
|
|
624
624
|
var it = new WirespecFile(input);
|
|
625
|
-
wirespec(it, languages, packageName, out(it.
|
|
625
|
+
wirespec(it, languages, packageName, out(it.u4a_1, packageName, output), logger);
|
|
626
626
|
} else {
|
|
627
627
|
// Inline function 'kotlin.error' call
|
|
628
628
|
var message = 'Path ' + input.toString() + ' is not a Wirespec file';
|
|
@@ -652,7 +652,7 @@
|
|
|
652
652
|
// Inline function 'community.flock.wirespec.plugin.cli.write.<anonymous>' call
|
|
653
653
|
var name = element.od();
|
|
654
654
|
var result = element.pd();
|
|
655
|
-
var tmp16_safe_receiver = file == null ? null : file.
|
|
655
|
+
var tmp16_safe_receiver = file == null ? null : file.x4a(_FileName___init__impl__nzn12e(name));
|
|
656
656
|
var tmp;
|
|
657
657
|
if (tmp16_safe_receiver == null) {
|
|
658
658
|
tmp = null;
|
|
@@ -815,7 +815,7 @@
|
|
|
815
815
|
// Inline function 'arrow.core.Either.map.<anonymous>' call
|
|
816
816
|
// Inline function 'community.flock.wirespec.plugin.cli.wirespec.<anonymous>.<anonymous>.<anonymous>' call
|
|
817
817
|
var it = results.zj_1;
|
|
818
|
-
var tmp$ret$2 = listOf(new Emitted(Companion_getInstance().
|
|
818
|
+
var tmp$ret$2 = listOf(new Emitted(Companion_getInstance().g24(_FileName___get_value__impl__3u4cz6(path(FileExtension_Wirespec_getInstance()).d2f_1)), first(it).j25_1));
|
|
819
819
|
tmp_0 = new Right(tmp$ret$2);
|
|
820
820
|
} else {
|
|
821
821
|
if (results instanceof Left) {
|
|
@@ -870,7 +870,7 @@
|
|
|
870
870
|
function compile$lambda($output) {
|
|
871
871
|
return function (it) {
|
|
872
872
|
var tmp = $output;
|
|
873
|
-
return new FullFilePath(_Output___get_value__impl__a8kw1g(ensureNotNull(tmp == null ? null : new Output(tmp)).
|
|
873
|
+
return new FullFilePath(_Output___get_value__impl__a8kw1g(ensureNotNull(tmp == null ? null : new Output(tmp)).l2f_1), _FileName___init__impl__nzn12e('console'), it);
|
|
874
874
|
};
|
|
875
875
|
}
|
|
876
876
|
function out$lambda($output, $this_out, $packageName) {
|
|
@@ -882,49 +882,49 @@
|
|
|
882
882
|
// Inline function 'kotlin.text.lowercase' call
|
|
883
883
|
// Inline function 'kotlin.js.asDynamic' call
|
|
884
884
|
var tmp$ret$1 = extension.p2_1.toLowerCase();
|
|
885
|
-
tmp = $this_out.
|
|
885
|
+
tmp = $this_out.c2f_1 + '/out/' + tmp$ret$1;
|
|
886
886
|
} else {
|
|
887
887
|
tmp = new Output(tmp0_elvis_lhs);
|
|
888
888
|
}
|
|
889
889
|
var dir = tmp;
|
|
890
|
-
return $this_out.
|
|
890
|
+
return $this_out.g2f(toString(dir) + '/' + joinToString(split(_PackageName___get_value__impl__2zr98c($packageName), charArrayOf([_Char___init__impl__6a9atx(46)])), '/'), VOID, extension);
|
|
891
891
|
};
|
|
892
892
|
}
|
|
893
893
|
function JavaFile(path) {
|
|
894
|
-
File.call(this, path.
|
|
894
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_Java_getInstance()));
|
|
895
895
|
}
|
|
896
|
-
protoOf(JavaFile).
|
|
897
|
-
return new JavaFile(this.
|
|
896
|
+
protoOf(JavaFile).x4a = function (fileName) {
|
|
897
|
+
return new JavaFile(this.u4a_1.g2f(VOID, fileName));
|
|
898
898
|
};
|
|
899
899
|
function JsonFile(path) {
|
|
900
|
-
File.call(this, path.
|
|
900
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_Json_getInstance()));
|
|
901
901
|
}
|
|
902
|
-
protoOf(JsonFile).
|
|
903
|
-
return new JsonFile(this.
|
|
902
|
+
protoOf(JsonFile).x4a = function (fileName) {
|
|
903
|
+
return new JsonFile(this.u4a_1.g2f(VOID, fileName));
|
|
904
904
|
};
|
|
905
905
|
function KotlinFile(path) {
|
|
906
|
-
File.call(this, path.
|
|
906
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_Kotlin_getInstance()));
|
|
907
907
|
}
|
|
908
|
-
protoOf(KotlinFile).
|
|
909
|
-
return new KotlinFile(this.
|
|
908
|
+
protoOf(KotlinFile).x4a = function (fileName) {
|
|
909
|
+
return new KotlinFile(this.u4a_1.g2f(VOID, fileName));
|
|
910
910
|
};
|
|
911
911
|
function ScalaFile(path) {
|
|
912
|
-
File.call(this, path.
|
|
912
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_Scala_getInstance()));
|
|
913
913
|
}
|
|
914
|
-
protoOf(ScalaFile).
|
|
915
|
-
return new ScalaFile(this.
|
|
914
|
+
protoOf(ScalaFile).x4a = function (fileName) {
|
|
915
|
+
return new ScalaFile(this.u4a_1.g2f(VOID, fileName));
|
|
916
916
|
};
|
|
917
917
|
function TypeScriptFile(path) {
|
|
918
|
-
File.call(this, path.
|
|
918
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_TypeScript_getInstance()));
|
|
919
919
|
}
|
|
920
|
-
protoOf(TypeScriptFile).
|
|
921
|
-
return new TypeScriptFile(this.
|
|
920
|
+
protoOf(TypeScriptFile).x4a = function (fileName) {
|
|
921
|
+
return new TypeScriptFile(this.u4a_1.g2f(VOID, fileName));
|
|
922
922
|
};
|
|
923
923
|
function WirespecFile(path) {
|
|
924
|
-
File.call(this, path.
|
|
924
|
+
File.call(this, path.g2f(VOID, VOID, FileExtension_Wirespec_getInstance()));
|
|
925
925
|
}
|
|
926
|
-
protoOf(WirespecFile).
|
|
927
|
-
return new WirespecFile(this.
|
|
926
|
+
protoOf(WirespecFile).x4a = function (fileName) {
|
|
927
|
+
return new WirespecFile(this.u4a_1.g2f(VOID, fileName));
|
|
928
928
|
};
|
|
929
929
|
function cli(args) {
|
|
930
930
|
main(args);
|
|
@@ -987,14 +987,14 @@
|
|
|
987
987
|
return it;
|
|
988
988
|
}
|
|
989
989
|
function Directory$wirespecFiles$lambda_0(it) {
|
|
990
|
-
return endsWith(it, FileExtension_Wirespec_getInstance().
|
|
990
|
+
return endsWith(it, FileExtension_Wirespec_getInstance().b2f_1);
|
|
991
991
|
}
|
|
992
992
|
function Directory$wirespecFiles$lambda_1(it) {
|
|
993
|
-
return dropLast(it, FileExtension_Wirespec_getInstance().
|
|
993
|
+
return dropLast(it, FileExtension_Wirespec_getInstance().b2f_1.length + 1 | 0);
|
|
994
994
|
}
|
|
995
995
|
function Directory$wirespecFiles$lambda_2(this$0) {
|
|
996
996
|
return function (it) {
|
|
997
|
-
return new FullFilePath(this$0.
|
|
997
|
+
return new FullFilePath(this$0.v4a_1, _FileName___init__impl__nzn12e(it));
|
|
998
998
|
};
|
|
999
999
|
}
|
|
1000
1000
|
function WirespecFile$_init_$ref_cj1n5j() {
|
|
@@ -1005,10 +1005,10 @@
|
|
|
1005
1005
|
return l;
|
|
1006
1006
|
}
|
|
1007
1007
|
function Directory(path) {
|
|
1008
|
-
this.
|
|
1008
|
+
this.v4a_1 = path;
|
|
1009
1009
|
}
|
|
1010
|
-
protoOf(Directory).
|
|
1011
|
-
var tmp = asSequence(iterator(get_fs().readdirSync(this.
|
|
1010
|
+
protoOf(Directory).w4a = function () {
|
|
1011
|
+
var tmp = asSequence(iterator(get_fs().readdirSync(this.v4a_1, 'utf-8')));
|
|
1012
1012
|
var tmp_0 = map(tmp, Directory$wirespecFiles$lambda);
|
|
1013
1013
|
var tmp_1 = filter(tmp_0, Directory$wirespecFiles$lambda_0);
|
|
1014
1014
|
var tmp_2 = map(tmp_1, Directory$wirespecFiles$lambda_1);
|
|
@@ -1016,20 +1016,20 @@
|
|
|
1016
1016
|
return toSet_0(map(tmp_3, WirespecFile$_init_$ref_cj1n5j()));
|
|
1017
1017
|
};
|
|
1018
1018
|
function File(path) {
|
|
1019
|
-
this.
|
|
1019
|
+
this.u4a_1 = path;
|
|
1020
1020
|
}
|
|
1021
1021
|
protoOf(File).y1a = function () {
|
|
1022
1022
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
1023
|
-
return get_fs().readFileSync(this.
|
|
1023
|
+
return get_fs().readFileSync(this.u4a_1.toString(), 'utf-8');
|
|
1024
1024
|
};
|
|
1025
1025
|
protoOf(File).s18 = function (text) {
|
|
1026
1026
|
// Inline function 'kotlin.run' call
|
|
1027
1027
|
// Inline function 'kotlin.contracts.contract' call
|
|
1028
1028
|
// Inline function 'community.flock.wirespec.plugin.cli.io.File.write.<anonymous>' call
|
|
1029
|
-
var $this$run = this.
|
|
1029
|
+
var $this$run = this.u4a_1.g2f(joinToString(split_0(this.u4a_1.c2f_1, ['out']), 'out/node'));
|
|
1030
1030
|
// Inline function 'kotlin.js.unsafeCast' call
|
|
1031
|
-
if (!get_fs().existsSync($this$run.
|
|
1032
|
-
get_fs().mkdirSync($this$run.
|
|
1031
|
+
if (!get_fs().existsSync($this$run.c2f_1)) {
|
|
1032
|
+
get_fs().mkdirSync($this$run.c2f_1, {recursive: true});
|
|
1033
1033
|
}
|
|
1034
1034
|
get_fs().writeFileSync($this$run.toString(), text);
|
|
1035
1035
|
};
|