@flock/wirespec 0.19.4 → 0.19.6

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.
Files changed (42) hide show
  1. package/clikt-clikt-mordant.mjs +78 -78
  2. package/clikt-clikt.mjs +1312 -1312
  3. package/clikt-clikt.mjs.map +1 -1
  4. package/colormath-root-colormath.mjs +426 -426
  5. package/kotlin-kotlin-stdlib.mjs +78 -77
  6. package/kotlin-kotlin-stdlib.mjs.map +1 -1
  7. package/kotlin-openapi-bindings.mjs +9632 -9632
  8. package/kotlin-rgxgen.mjs +1759 -1759
  9. package/kotlinx-io-kotlinx-io-core.mjs +403 -403
  10. package/kotlinx-serialization-kotlinx-serialization-core.mjs +1729 -1729
  11. package/kotlinx-serialization-kotlinx-serialization-json.mjs +1467 -1467
  12. package/mordant-mordant.mjs +1157 -1157
  13. package/package.json +1 -1
  14. package/wirespec-src-compiler-core.mjs +13 -1
  15. package/wirespec-src-compiler-core.mjs.map +1 -1
  16. package/wirespec-src-compiler-emitters-java.mjs +311 -340
  17. package/wirespec-src-compiler-emitters-java.mjs.map +1 -1
  18. package/wirespec-src-compiler-emitters-kotlin.mjs +143 -143
  19. package/wirespec-src-compiler-emitters-kotlin.mjs.map +1 -1
  20. package/wirespec-src-compiler-emitters-python.mjs +204 -196
  21. package/wirespec-src-compiler-emitters-python.mjs.map +1 -1
  22. package/wirespec-src-compiler-emitters-rust.mjs +349 -349
  23. package/wirespec-src-compiler-emitters-rust.mjs.map +1 -1
  24. package/wirespec-src-compiler-emitters-scala.mjs +123 -123
  25. package/wirespec-src-compiler-emitters-scala.mjs.map +1 -1
  26. package/wirespec-src-compiler-emitters-typescript.mjs +194 -194
  27. package/wirespec-src-compiler-emitters-typescript.mjs.map +1 -1
  28. package/wirespec-src-compiler-emitters-wirespec.mjs +22 -22
  29. package/wirespec-src-compiler-emitters-wirespec.mjs.map +1 -1
  30. package/wirespec-src-compiler-ir.mjs +3584 -3460
  31. package/wirespec-src-compiler-ir.mjs.map +1 -1
  32. package/wirespec-src-compiler-lib.mjs +227 -58
  33. package/wirespec-src-compiler-lib.mjs.map +1 -1
  34. package/wirespec-src-converter-avro.mjs +473 -473
  35. package/wirespec-src-converter-openapi.mjs +342 -342
  36. package/wirespec-src-ide-lsp.mjs +1346 -1346
  37. package/wirespec-src-plugin-arguments.mjs +131 -131
  38. package/wirespec-src-plugin-cli.mjs +87 -87
  39. package/wirespec-src-plugin-npm.d.mts +39 -2
  40. package/wirespec-src-plugin-npm.mjs +21 -21
  41. package/wirespec-src-plugin-npm.mjs.map +1 -1
  42. package/wirespec-src-tools-generator.mjs +2 -2
@@ -99,7 +99,6 @@ import {
99
99
  HashSet_init_$Create$33p49hmosnvr4 as HashSet_init_$Create$,
100
100
  Collection1k04j3hzsbod0 as Collection,
101
101
  equals2au1ep9vhcato as equals,
102
- firstOrNull1982767dljvdy as firstOrNull_0,
103
102
  last1vo29oleiqj36 as last,
104
103
  dropLast1vpiyky649o34 as dropLast,
105
104
  to2cs3ny02qtbcb as to,
@@ -183,6 +182,7 @@ import {
183
182
  Assignment3kcxc8wlcbmkn as Assignment,
184
183
  ReturnStatement29qlfkn9kpy10 as ReturnStatement,
185
184
  Wildcard_instance2ga1ytfwj78ra as Wildcard_instance,
185
+ transformChildren2m3cpkz6zusq1 as transformChildren_1,
186
186
  } from './wirespec-src-compiler-ir.mjs';
187
187
  //region block: imports
188
188
  //endregion
@@ -215,10 +215,10 @@ function emit_6(_this__u8e3s4) {
215
215
  function emitRoot(_this__u8e3s4, void_0) {
216
216
  var tmp;
217
217
  if (_this__u8e3s4 instanceof Dict) {
218
- tmp = this.v1w(_this__u8e3s4.so_1);
218
+ tmp = this.x1w(_this__u8e3s4.so_1);
219
219
  } else {
220
220
  if (_this__u8e3s4 instanceof Iterable) {
221
- tmp = this.v1w(_this__u8e3s4.po_1);
221
+ tmp = this.x1w(_this__u8e3s4.po_1);
222
222
  } else {
223
223
  if (_this__u8e3s4 instanceof Unit) {
224
224
  tmp = void_0;
@@ -247,7 +247,7 @@ function emitRoot(_this__u8e3s4, void_0) {
247
247
  }
248
248
  function emitRoot$default(_this__u8e3s4, void_0, $super) {
249
249
  void_0 = void_0 === VOID ? 'void' : void_0;
250
- return $super === VOID ? this.w1w(_this__u8e3s4, void_0) : emitRoot(_this__u8e3s4, void_0);
250
+ return $super === VOID ? this.y1w(_this__u8e3s4, void_0) : emitRoot(_this__u8e3s4, void_0);
251
251
  }
252
252
  function emit_7(_this__u8e3s4) {
253
253
  var tmp;
@@ -290,17 +290,117 @@ function emit_7(_this__u8e3s4) {
290
290
  }
291
291
  initMetadataForInterface(JavaTypeDefinitionEmitter, 'JavaTypeDefinitionEmitter', VOID, VOID, [TypeDefinitionEmitter]);
292
292
  function emit_8(channel) {
293
- return trimMargin('\n |' + emitImports(this, channel) + '\n |\n |@FunctionalInterface\n |public interface ' + this.nr(channel.cp_1) + ' {\n | void invoke(' + emitFullyQualified(this, channel, channel.dp_1) + this.v1w(channel.dp_1) + ' message);\n |}\n |\n ');
293
+ return trimMargin('\n |' + emitImports(this, channel) + '\n |\n |@FunctionalInterface\n |public interface ' + this.nr(channel.cp_1) + ' {\n | void invoke(' + emitFullyQualified(this, channel, channel.dp_1) + this.x1w(channel.dp_1) + ' message);\n |}\n |\n ');
294
294
  }
295
295
  initMetadataForInterface(JavaChannelDefinitionEmitter, 'JavaChannelDefinitionEmitter', VOID, VOID, [JavaTypeDefinitionEmitter]);
296
- function emit_9(endpoint) {
296
+ function emit_9(refined) {
297
+ return trimMargin('\n |public record ' + this.nr(refined.sr_1) + ' (' + this.nq(refined.tr_1) + ' value) implements Wirespec.Refined<' + this.nq(refined.tr_1) + '> {\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public String toString() { return value.toString(); }\n |' + Spacer_instance.toString() + 'public Boolean validate() {\n |' + Spacer_instance.toString() + Spacer_instance.toString() + this.bs(refined) + '\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public ' + this.nq(refined.tr_1) + ' value() { return value; }\n |}\n |\n ');
298
+ }
299
+ function emitValidator(_this__u8e3s4) {
300
+ var defaultReturn = 'return true;';
301
+ var type = _this__u8e3s4.tr_1.fv_1;
302
+ var tmp;
303
+ if (type instanceof Integer) {
304
+ var tmp0_safe_receiver = type.ku_1;
305
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : this.oq(tmp0_safe_receiver);
306
+ tmp = tmp1_elvis_lhs == null ? defaultReturn : tmp1_elvis_lhs;
307
+ } else {
308
+ if (type instanceof Number_0) {
309
+ var tmp2_safe_receiver = type.nu_1;
310
+ var tmp3_elvis_lhs = tmp2_safe_receiver == null ? null : this.oq(tmp2_safe_receiver);
311
+ tmp = tmp3_elvis_lhs == null ? defaultReturn : tmp3_elvis_lhs;
312
+ } else {
313
+ if (type instanceof String_0) {
314
+ var tmp4_safe_receiver = type.hu_1;
315
+ var tmp_0;
316
+ var tmp_1 = tmp4_safe_receiver;
317
+ if ((tmp_1 == null ? null : new RegExp_0(tmp_1)) == null) {
318
+ tmp_0 = null;
319
+ } else {
320
+ tmp_0 = this.oq(new RegExp_0(tmp4_safe_receiver));
321
+ }
322
+ var tmp5_elvis_lhs = tmp_0;
323
+ tmp = tmp5_elvis_lhs == null ? defaultReturn : tmp5_elvis_lhs;
324
+ } else {
325
+ if (equals(type, Boolean_instance)) {
326
+ tmp = defaultReturn;
327
+ } else {
328
+ if (equals(type, Bytes_instance)) {
329
+ tmp = defaultReturn;
330
+ } else {
331
+ noWhenBranchMatchedException();
332
+ }
333
+ }
334
+ }
335
+ }
336
+ }
337
+ return tmp;
338
+ }
339
+ initMetadataForInterface(JavaRefinedTypeDefinitionEmitter, 'JavaRefinedTypeDefinitionEmitter', VOID, VOID, [JavaTypeDefinitionEmitter]);
340
+ function emit_10(identifier) {
341
+ var tmp;
342
+ if (identifier instanceof DefinitionIdentifier) {
343
+ tmp = this.i1x(identifier.l1());
344
+ } else {
345
+ if (identifier instanceof FieldIdentifier) {
346
+ tmp = this.m1x(this.i1x(identifier.l1()));
347
+ } else {
348
+ noWhenBranchMatchedException();
349
+ }
350
+ }
351
+ return tmp;
352
+ }
353
+ function sanitizeSymbol(_this__u8e3s4) {
354
+ // Inline function 'kotlin.collections.mapIndexed' call
355
+ var this_0 = split(_this__u8e3s4, ['.', ' ', '-']);
356
+ // Inline function 'kotlin.collections.mapIndexedTo' call
357
+ var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
358
+ var index = 0;
359
+ var _iterator__ex2g4s = this_0.t();
360
+ while (_iterator__ex2g4s.u()) {
361
+ var item = _iterator__ex2g4s.v();
362
+ var _unary__edvuaz = index;
363
+ index = _unary__edvuaz + 1 | 0;
364
+ var tmp$ret$0 = checkIndexOverflow(_unary__edvuaz) > 0 ? Companion_instance_1.er(item) : item;
365
+ destination.x(tmp$ret$0);
366
+ }
367
+ var tmp = asSequence(joinToString(destination, ''));
368
+ return this.l1x(joinToString_0(filter(tmp, JavaIdentifierEmitter$sanitizeSymbol$lambda), ''));
369
+ }
370
+ function sanitizeFirstIsDigit(_this__u8e3s4) {
371
+ var tmp;
372
+ var tmp0_safe_receiver = firstOrNull(_this__u8e3s4);
373
+ var tmp_0;
374
+ var tmp_1 = tmp0_safe_receiver;
375
+ if ((tmp_1 == null ? null : new Char(tmp_1)) == null) {
376
+ tmp_0 = null;
377
+ } else {
378
+ tmp_0 = isDigit(tmp0_safe_receiver);
379
+ }
380
+ if (tmp_0 === true) {
381
+ tmp = '_' + _this__u8e3s4;
382
+ } else {
383
+ tmp = _this__u8e3s4;
384
+ }
385
+ return tmp;
386
+ }
387
+ function sanitizeKeywords(_this__u8e3s4) {
388
+ return Companion_getInstance_0().o1x_1.u1(_this__u8e3s4) ? '_' + _this__u8e3s4 : _this__u8e3s4;
389
+ }
390
+ initMetadataForInterface(JavaIdentifierEmitter, 'JavaIdentifierEmitter');
391
+ function emit_11(union) {
392
+ var tmp = this.nr(union.gp_1);
393
+ return trimMargin('\n |public sealed interface ' + tmp + ' permits ' + joinToString(union.hp_1, VOID, VOID, VOID, VOID, VOID, JavaUnionDefinitionEmitter$emit$lambda) + ' {}\n |\n ');
394
+ }
395
+ initMetadataForInterface(JavaUnionDefinitionEmitter, 'JavaUnionDefinitionEmitter', VOID, VOID, [JavaIdentifierEmitter]);
396
+ function emit_12(endpoint) {
297
397
  var tmp = emitImports_0(this, endpoint);
298
398
  var tmp_0 = this.nr(endpoint.up_1);
299
399
  var tmp_1 = get_pathParams(endpoint);
300
400
  var tmp_2 = emitObject(this, tmp_1, 'Path', 'Wirespec.Path', JavaEndpointDefinitionEmitter$emit$lambda(this));
301
401
  var tmp_3 = emitObject(this, endpoint.xp_1, 'Queries', 'Wirespec.Queries', JavaEndpointDefinitionEmitter$emit$lambda_0(this));
302
402
  var tmp_4 = emitObject(this, endpoint.yp_1, 'RequestHeaders', 'Wirespec.Request.Headers', JavaEndpointDefinitionEmitter$emit$lambda_1(this));
303
- var tmp_5 = this.h1x(first_0(endpoint.zp_1), endpoint);
403
+ var tmp_5 = this.j1x(first_0(endpoint.zp_1), endpoint);
304
404
  var tmp_6 = Spacer_instance.toString();
305
405
  var tmp_7 = emitStatusInterfaces(this, endpoint);
306
406
  var tmp_8 = emitResponseInterfaces(this, endpoint);
@@ -317,7 +417,7 @@ function emit_9(endpoint) {
317
417
  var tmp_19 = emitFromResponse(this, endpoint);
318
418
  var tmp_20 = Spacer_instance.hs(2);
319
419
  var tmp_21 = Spacer_instance.hs(2);
320
- var tmp_22 = this.l1x(endpoint);
420
+ var tmp_22 = this.n1x(endpoint);
321
421
  var tmp_23 = Spacer_instance.hs(2);
322
422
  var tmp_24 = Spacer_instance.hs(3);
323
423
  return trimMargin('\n |' + tmp + '\n |\n |public interface ' + tmp_0 + ' extends Wirespec.Endpoint {\n |' + tmp_2 + '\n |\n |' + tmp_3 + '\n |\n |' + tmp_4 + '\n |\n |' + tmp_5 + '\n |\n |' + tmp_6 + 'sealed interface Response<T> extends Wirespec.Response<T> {}\n |' + tmp_7 + '\n |' + tmp_8 + '\n |\n |' + tmp_10 + '\n |\n |' + tmp_11 + 'interface Handler extends Wirespec.Handler {\n |\n |' + tmp_12 + '\n |\n |' + tmp_13 + 'static Wirespec.RawResponse toResponse(Wirespec.Serializer serialization, Response<?> response) {\n |' + tmp_15 + '\n |' + tmp_16 + 'else { throw new IllegalStateException("Cannot match response with status: " + response.status());}\n |' + tmp_17 + '}\n |\n |' + tmp_18 + 'static Response<?> fromResponse(Wirespec.Deserializer serialization, Wirespec.RawResponse response) {\n |' + tmp_19 + '\n |' + tmp_20 + '}\n |\n |' + tmp_21 + tmp_22 + '\n |' + tmp_23 + 'class Handlers implements Wirespec.Server<Request, Response<?>>, Wirespec.Client<Request, Response<?>> {\n |' + tmp_24 + '@Override public String getPathTemplate() { return "/' + joinToString(endpoint.wp_1, '/', VOID, VOID, VOID, VOID, JavaEndpointDefinitionEmitter$emit$lambda_4) + '"; }\n |' + Spacer_instance.hs(3) + '@Override public String getMethod() { return "' + endpoint.vp_1.toString() + '"; }\n |' + Spacer_instance.hs(3) + '@Override public Wirespec.ServerEdge<Request, Response<?>> getServer(Wirespec.Serialization serialization) {\n |' + Spacer_instance.hs(4) + 'return new Wirespec.ServerEdge<>() {\n |' + Spacer_instance.hs(5) + '@Override public Request from(Wirespec.RawRequest request) { return fromRequest(serialization, request); }\n |' + Spacer_instance.hs(5) + '@Override public Wirespec.RawResponse to(Response<?> response) { return toResponse(serialization, response); }\n |' + Spacer_instance.hs(4) + '};\n |' + Spacer_instance.hs(3) + '}\n |' + Spacer_instance.hs(3) + '@Override public Wirespec.ClientEdge<Request, Response<?>> getClient(Wirespec.Serialization serialization) {\n |' + Spacer_instance.hs(4) + 'return new Wirespec.ClientEdge<>() {\n |' + Spacer_instance.hs(5) + '@Override public Wirespec.RawRequest to(Request request) { return toRequest(serialization, request); }\n |' + Spacer_instance.hs(5) + '@Override public Response<?> from(Wirespec.RawResponse response) { return fromResponse(serialization, response); }\n |' + Spacer_instance.hs(4) + '};\n |' + Spacer_instance.hs(3) + '}\n |' + Spacer_instance.hs(2) + '}\n |' + Spacer_instance.toString() + '}\n |}\n |\n ');
@@ -325,10 +425,10 @@ function emit_9(endpoint) {
325
425
  function emitHandleFunction(endpoint) {
326
426
  return 'java.util.concurrent.CompletableFuture<Response<?>> ' + Companion_instance_1.fr(this.nr(endpoint.up_1)) + '(Request request);';
327
427
  }
328
- function emit_10(_this__u8e3s4, endpoint) {
428
+ function emit_13(_this__u8e3s4, endpoint) {
329
429
  return trimMargin('\n |' + Spacer_instance.toString() + 'record Request (\n |' + Spacer_instance.hs(2) + 'Path path,\n |' + Spacer_instance.hs(2) + 'Wirespec.Method method,\n |' + Spacer_instance.hs(2) + 'Queries queries,\n |' + Spacer_instance.hs(2) + 'RequestHeaders headers,\n |' + Spacer_instance.hs(2) + emit_16(this, _this__u8e3s4.dq_1) + ' body\n |' + Spacer_instance.toString() + ') implements Wirespec.Request<' + emit_16(this, _this__u8e3s4.dq_1) + '> {\n |' + Spacer_instance.hs(2) + emitConstructor(this, _this__u8e3s4, endpoint) + '\n |' + Spacer_instance.toString() + '}\n ');
330
430
  }
331
- function emit_11(_this__u8e3s4) {
431
+ function emit_14(_this__u8e3s4) {
332
432
  var tmp = Spacer_instance.toString();
333
433
  var tmp_0 = Companion_instance_1.er(_this__u8e3s4.gq_1);
334
434
  var tmp_1 = Spacer_instance.hs(2);
@@ -361,112 +461,12 @@ function emit_11(_this__u8e3s4) {
361
461
  return trimMargin('\n |' + tmp + 'record Response' + tmp_0 + '(\n |' + tmp_1 + 'Integer status,\n |' + tmp_2 + 'Headers headers,\n |' + tmp_3 + tmp_4 + ' body\n |' + tmp_5 + ') implements Response' + tmp_6 + 'XX<' + tmp_7 + '>, Response' + tmp_8 + ' {\n |' + tmp_9 + 'public Response' + tmp_10 + '(' + tmp_13 + ') {\n |' + tmp_14 + 'this(' + tmp_15 + ', ' + tmp_16 + ', ' + tmp_17 + ');\n |' + tmp_18 + '}\n |' + tmp_19 + emitObject(this, _this__u8e3s4.hq_1, 'Headers', 'Wirespec.Response.Headers', JavaEndpointDefinitionEmitter$emit$lambda_7(this)) + '\n |' + Spacer_instance.toString() + '}\n ');
362
462
  }
363
463
  initMetadataForInterface(JavaEndpointDefinitionEmitter, 'JavaEndpointDefinitionEmitter', VOID, VOID, [JavaTypeDefinitionEmitter]);
364
- function emit_12(identifier) {
365
- var tmp;
366
- if (identifier instanceof DefinitionIdentifier) {
367
- tmp = this.g1x(identifier.l1());
368
- } else {
369
- if (identifier instanceof FieldIdentifier) {
370
- tmp = this.k1x(this.g1x(identifier.l1()));
371
- } else {
372
- noWhenBranchMatchedException();
373
- }
374
- }
375
- return tmp;
376
- }
377
- function sanitizeSymbol(_this__u8e3s4) {
378
- // Inline function 'kotlin.collections.mapIndexed' call
379
- var this_0 = split(_this__u8e3s4, ['.', ' ', '-']);
380
- // Inline function 'kotlin.collections.mapIndexedTo' call
381
- var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
382
- var index = 0;
383
- var _iterator__ex2g4s = this_0.t();
384
- while (_iterator__ex2g4s.u()) {
385
- var item = _iterator__ex2g4s.v();
386
- var _unary__edvuaz = index;
387
- index = _unary__edvuaz + 1 | 0;
388
- var tmp$ret$0 = checkIndexOverflow(_unary__edvuaz) > 0 ? Companion_instance_1.er(item) : item;
389
- destination.x(tmp$ret$0);
390
- }
391
- var tmp = asSequence(joinToString(destination, ''));
392
- return this.j1x(joinToString_0(filter(tmp, JavaIdentifierEmitter$sanitizeSymbol$lambda), ''));
393
- }
394
- function sanitizeFirstIsDigit(_this__u8e3s4) {
395
- var tmp;
396
- var tmp0_safe_receiver = firstOrNull(_this__u8e3s4);
397
- var tmp_0;
398
- var tmp_1 = tmp0_safe_receiver;
399
- if ((tmp_1 == null ? null : new Char(tmp_1)) == null) {
400
- tmp_0 = null;
401
- } else {
402
- tmp_0 = isDigit(tmp0_safe_receiver);
403
- }
404
- if (tmp_0 === true) {
405
- tmp = '_' + _this__u8e3s4;
406
- } else {
407
- tmp = _this__u8e3s4;
408
- }
409
- return tmp;
410
- }
411
- function sanitizeKeywords(_this__u8e3s4) {
412
- return Companion_getInstance_0().m1x_1.u1(_this__u8e3s4) ? '_' + _this__u8e3s4 : _this__u8e3s4;
413
- }
414
- initMetadataForInterface(JavaIdentifierEmitter, 'JavaIdentifierEmitter');
415
- function emit_13(union) {
416
- var tmp = this.nr(union.gp_1);
417
- return trimMargin('\n |public sealed interface ' + tmp + ' permits ' + joinToString(union.hp_1, VOID, VOID, VOID, VOID, VOID, JavaUnionDefinitionEmitter$emit$lambda) + ' {}\n |\n ');
418
- }
419
- initMetadataForInterface(JavaUnionDefinitionEmitter, 'JavaUnionDefinitionEmitter', VOID, VOID, [JavaIdentifierEmitter]);
420
- function emit_14(refined) {
421
- return trimMargin('\n |public record ' + this.nr(refined.sr_1) + ' (' + this.nq(refined.tr_1) + ' value) implements Wirespec.Refined<' + this.nq(refined.tr_1) + '> {\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public String toString() { return value.toString(); }\n |' + Spacer_instance.toString() + 'public Boolean validate() {\n |' + Spacer_instance.toString() + Spacer_instance.toString() + this.bs(refined) + '\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public ' + this.nq(refined.tr_1) + ' value() { return value; }\n |}\n |\n ');
422
- }
423
- function emitValidator(_this__u8e3s4) {
424
- var defaultReturn = 'return true;';
425
- var type = _this__u8e3s4.tr_1.fv_1;
426
- var tmp;
427
- if (type instanceof Integer) {
428
- var tmp0_safe_receiver = type.ku_1;
429
- var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : this.oq(tmp0_safe_receiver);
430
- tmp = tmp1_elvis_lhs == null ? defaultReturn : tmp1_elvis_lhs;
431
- } else {
432
- if (type instanceof Number_0) {
433
- var tmp2_safe_receiver = type.nu_1;
434
- var tmp3_elvis_lhs = tmp2_safe_receiver == null ? null : this.oq(tmp2_safe_receiver);
435
- tmp = tmp3_elvis_lhs == null ? defaultReturn : tmp3_elvis_lhs;
436
- } else {
437
- if (type instanceof String_0) {
438
- var tmp4_safe_receiver = type.hu_1;
439
- var tmp_0;
440
- var tmp_1 = tmp4_safe_receiver;
441
- if ((tmp_1 == null ? null : new RegExp_0(tmp_1)) == null) {
442
- tmp_0 = null;
443
- } else {
444
- tmp_0 = this.oq(new RegExp_0(tmp4_safe_receiver));
445
- }
446
- var tmp5_elvis_lhs = tmp_0;
447
- tmp = tmp5_elvis_lhs == null ? defaultReturn : tmp5_elvis_lhs;
448
- } else {
449
- if (equals(type, Boolean_instance)) {
450
- tmp = defaultReturn;
451
- } else {
452
- if (equals(type, Bytes_instance)) {
453
- tmp = defaultReturn;
454
- } else {
455
- noWhenBranchMatchedException();
456
- }
457
- }
458
- }
459
- }
460
- }
461
- return tmp;
462
- }
463
- initMetadataForInterface(JavaRefinedTypeDefinitionEmitter, 'JavaRefinedTypeDefinitionEmitter', VOID, VOID, [JavaTypeDefinitionEmitter]);
464
464
  function emit_15(enum_0, module_0) {
465
465
  var tmp = this.nr(enum_0.xr_1);
466
466
  return trimMargin('\n |public enum ' + tmp + ' implements Wirespec.Enum {\n |' + spacer(joinToString(enum_0.yr_1, ',\n', VOID, VOID, VOID, VOID, JavaEnumDefinitionEmitter$emit$lambda(this))) + ';\n |' + Spacer_instance.toString() + 'public final String label;\n |' + Spacer_instance.toString() + this.nr(enum_0.xr_1) + '(String label) {\n |' + Spacer_instance.hs(2) + 'this.label = label;\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public String toString() {\n |' + Spacer_instance.hs(2) + 'return label;\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + '@Override\n |' + Spacer_instance.toString() + 'public String label() {\n |' + Spacer_instance.hs(2) + 'return label;\n |' + Spacer_instance.toString() + '}\n |}\n |\n ');
467
467
  }
468
468
  initMetadataForInterface(JavaEnumDefinitionEmitter, 'JavaEnumDefinitionEmitter', VOID, VOID, [JavaIdentifierEmitter]);
469
- initMetadataForClass(JavaEmitter, 'JavaEmitter', JavaEmitter, LanguageEmitter, [JavaEndpointDefinitionEmitter, JavaChannelDefinitionEmitter, JavaUnionDefinitionEmitter, JavaRefinedTypeDefinitionEmitter, JavaTypeDefinitionEmitter, JavaIdentifierEmitter, JavaEnumDefinitionEmitter, LanguageEmitter]);
469
+ initMetadataForClass(JavaEmitter, 'JavaEmitter', JavaEmitter, LanguageEmitter, [JavaRefinedTypeDefinitionEmitter, JavaChannelDefinitionEmitter, JavaUnionDefinitionEmitter, JavaEndpointDefinitionEmitter, JavaEnumDefinitionEmitter, JavaTypeDefinitionEmitter, JavaIdentifierEmitter, LanguageEmitter]);
470
470
  initMetadataForCompanion(Companion);
471
471
  initMetadataForCompanion(Companion_0);
472
472
  initMetadataForClass(JavaIrEmitter, 'JavaIrEmitter', JavaIrEmitter, VOID, [IrEmitter]);
@@ -490,7 +490,7 @@ function emitImports($this, _this__u8e3s4) {
490
490
  var _iterator__ex2g4s_0 = destination.t();
491
491
  while (_iterator__ex2g4s_0.u()) {
492
492
  var item = _iterator__ex2g4s_0.v();
493
- var tmp$ret$3 = 'import ' + $this.u1w().ds_1 + '.model.' + item.bv_1 + ';';
493
+ var tmp$ret$3 = 'import ' + $this.w1w().ds_1 + '.model.' + item.bv_1 + ';';
494
494
  destination_0.x(tmp$ret$3);
495
495
  }
496
496
  var tmp = destination_0;
@@ -499,7 +499,7 @@ function emitImports($this, _this__u8e3s4) {
499
499
  function emitFullyQualified($this, _this__u8e3s4, reference) {
500
500
  var tmp;
501
501
  if (_this__u8e3s4.mr().l1() === reference.l1()) {
502
- tmp = $this.u1w().ds_1 + '.model.';
502
+ tmp = $this.w1w().ds_1 + '.model.';
503
503
  } else {
504
504
  tmp = '';
505
505
  }
@@ -515,42 +515,42 @@ function JavaEmitter(packageName, emitShared) {
515
515
  packageName = packageName === VOID ? Companion_instance.cs('community.flock.wirespec.generated') : packageName;
516
516
  emitShared = emitShared === VOID ? Companion_instance_0.wo() : emitShared;
517
517
  LanguageEmitter.call(this);
518
- this.x1w_1 = packageName;
519
- this.y1w_1 = emitShared;
520
- this.z1w_1 = '\nimport community.flock.wirespec.java.Wirespec;\n';
521
- this.a1x_1 = FileExtension_Java_getInstance();
522
- this.b1x_1 = JavaShared_getInstance();
523
- this.c1x_1 = '//';
524
- }
525
- protoOf(JavaEmitter).u1w = function () {
526
- return this.x1w_1;
518
+ this.z1w_1 = packageName;
519
+ this.a1x_1 = emitShared;
520
+ this.b1x_1 = '\nimport community.flock.wirespec.java.Wirespec;\n';
521
+ this.c1x_1 = FileExtension_Java_getInstance();
522
+ this.d1x_1 = JavaShared_getInstance();
523
+ this.e1x_1 = '//';
524
+ }
525
+ protoOf(JavaEmitter).w1w = function () {
526
+ return this.z1w_1;
527
527
  };
528
528
  protoOf(JavaEmitter).uq = function () {
529
- return this.a1x_1;
529
+ return this.c1x_1;
530
530
  };
531
- protoOf(JavaEmitter).d1x = function () {
532
- return this.b1x_1;
531
+ protoOf(JavaEmitter).f1x = function () {
532
+ return this.d1x_1;
533
533
  };
534
534
  protoOf(JavaEmitter).vq = function () {
535
- return this.c1x_1;
535
+ return this.e1x_1;
536
536
  };
537
537
  protoOf(JavaEmitter).kr = function (module_0, logger) {
538
538
  // Inline function 'kotlin.let' call
539
539
  var it = protoOf(LanguageEmitter).kr.call(this, module_0, logger);
540
- return this.y1w_1.xo_1 ? NonEmptyList__plus_impl_xqmb9(it, new Emitted(Companion_instance.cs('community.flock.wirespec.java').fs() + 'Wirespec', this.d1x().f1x_1)) : it;
540
+ return this.a1x_1.xo_1 ? NonEmptyList__plus_impl_xqmb9(it, new Emitted(Companion_instance.cs('community.flock.wirespec.java').fs() + 'Wirespec', this.f1x().h1x_1)) : it;
541
541
  };
542
542
  protoOf(JavaEmitter).lr = function (definition, module_0, logger) {
543
543
  // Inline function 'kotlin.let' call
544
544
  var it = protoOf(LanguageEmitter).lr.call(this, definition, module_0, logger);
545
- var subPackageName = plus(this.u1w(), definition);
546
- var tmp = subPackageName.fs() + this.g1x(it.yo_1);
545
+ var subPackageName = plus(this.w1w(), definition);
546
+ var tmp = subPackageName.fs() + this.i1x(it.yo_1);
547
547
  // Inline function 'kotlin.text.trimStart' call
548
- var this_0 = trimMargin('\n |package ' + subPackageName.toString() + ';\n |' + (Companion_instance_1.gr(module_0) ? this.z1w_1 : '') + '\n |' + it.zo_1 + '\n ');
548
+ var this_0 = trimMargin('\n |package ' + subPackageName.toString() + ';\n |' + (Companion_instance_1.gr(module_0) ? this.b1x_1 : '') + '\n |' + it.zo_1 + '\n ');
549
549
  var tmp$ret$0 = toString(trimStart(isCharSequence(this_0) ? this_0 : THROW_CCE()));
550
550
  return new Emitted(tmp, tmp$ret$0);
551
551
  };
552
552
  function emitGetType($this, _this__u8e3s4) {
553
- return 'Wirespec.getType(' + $this.w1w(_this__u8e3s4, 'Void') + '.class, ' + emitGetTypeRaw($this, _this__u8e3s4) + ')';
553
+ return 'Wirespec.getType(' + $this.y1w(_this__u8e3s4, 'Void') + '.class, ' + emitGetTypeRaw($this, _this__u8e3s4) + ')';
554
554
  }
555
555
  function emitGetTypeRaw($this, _this__u8e3s4) {
556
556
  var tmp;
@@ -705,7 +705,7 @@ function emitImports_0($this, _this__u8e3s4) {
705
705
  var _iterator__ex2g4s_0 = destination.t();
706
706
  while (_iterator__ex2g4s_0.u()) {
707
707
  var item = _iterator__ex2g4s_0.v();
708
- var tmp$ret$3 = 'import ' + $this.u1w().ds_1 + '.model.' + item.bv_1 + ';';
708
+ var tmp$ret$3 = 'import ' + $this.w1w().ds_1 + '.model.' + item.bv_1 + ';';
709
709
  destination_0.x(tmp$ret$3);
710
710
  }
711
711
  var tmp = destination_0;
@@ -826,7 +826,7 @@ function JavaEndpointDefinitionEmitter$emit$lambda_1(this$0) {
826
826
  }
827
827
  function JavaEndpointDefinitionEmitter$emit$lambda_2(this$0) {
828
828
  return function (it) {
829
- return this$0.i1x(it);
829
+ return this$0.k1x(it);
830
830
  };
831
831
  }
832
832
  function JavaEndpointDefinitionEmitter$emit$lambda_3(this$0) {
@@ -958,7 +958,7 @@ function sanitizeNegative($this, _this__u8e3s4) {
958
958
  return startsWith(_this__u8e3s4, '-') ? '__' + substring(_this__u8e3s4, 1) : _this__u8e3s4;
959
959
  }
960
960
  function sanitizeEnum($this, _this__u8e3s4) {
961
- return $this.k1x($this.j1x(joinToString(split(sanitizeNegative($this, _this__u8e3s4), ['-', ', ', '.', ' ', '//']), '_')));
961
+ return $this.m1x($this.l1x(joinToString(split(sanitizeNegative($this, _this__u8e3s4), ['-', ', ', '.', ' ', '//']), '_')));
962
962
  }
963
963
  function JavaEnumDefinitionEmitter$emit$lambda(this$0) {
964
964
  return function (it) {
@@ -969,7 +969,7 @@ function JavaEnumDefinitionEmitter() {
969
969
  }
970
970
  function Companion() {
971
971
  Companion_instance_2 = this;
972
- this.m1x_1 = setOf(['abstract', 'continue', 'for', 'new', 'switch', 'assert', 'default', 'goto', 'package', 'synchronized', 'boolean', 'do', 'if', 'private', 'this', 'break', 'double', 'implements', 'protected', 'throw', 'byte', 'else', 'import', 'public', 'throws', 'case', 'enum', 'instanceof', 'return', 'transient', 'catch', 'extends', 'int', 'short', 'try', 'char', 'final', 'interface', 'static', 'void', 'class', 'finally', 'long', 'strictfp', 'volatile', 'const', 'float', 'native', 'super', 'while', 'true', 'false']);
972
+ this.o1x_1 = setOf(['abstract', 'continue', 'for', 'new', 'switch', 'assert', 'default', 'goto', 'package', 'synchronized', 'boolean', 'do', 'if', 'private', 'this', 'break', 'double', 'implements', 'protected', 'throw', 'byte', 'else', 'import', 'public', 'throws', 'case', 'enum', 'instanceof', 'return', 'transient', 'catch', 'extends', 'int', 'short', 'try', 'char', 'final', 'interface', 'static', 'void', 'class', 'finally', 'long', 'strictfp', 'volatile', 'const', 'float', 'native', 'super', 'while', 'true', 'false']);
973
973
  }
974
974
  var Companion_instance_2;
975
975
  function Companion_getInstance_0() {
@@ -1033,14 +1033,14 @@ function sanitizeFirstIsDigit_0($this, _this__u8e3s4) {
1033
1033
  return tmp;
1034
1034
  }
1035
1035
  function sanitizeKeywords_0($this, _this__u8e3s4) {
1036
- return Companion_getInstance_1().n1x_1.u1(_this__u8e3s4) ? '_' + _this__u8e3s4 : _this__u8e3s4;
1036
+ return Companion_getInstance_1().p1x_1.u1(_this__u8e3s4) ? '_' + _this__u8e3s4 : _this__u8e3s4;
1037
1037
  }
1038
1038
  function sanitizeEnum_0($this, _this__u8e3s4) {
1039
1039
  return sanitizeKeywords_0($this, sanitizeFirstIsDigit_0($this, joinToString(split(_this__u8e3s4, ['-', ', ', '.', ' ', '//']), '_')));
1040
1040
  }
1041
1041
  function Companion_0() {
1042
1042
  Companion_instance_3 = this;
1043
- this.n1x_1 = setOf(['abstract', 'continue', 'for', 'new', 'switch', 'assert', 'default', 'goto', 'package', 'synchronized', 'boolean', 'do', 'if', 'private', 'this', 'break', 'double', 'implements', 'protected', 'throw', 'byte', 'else', 'import', 'public', 'throws', 'case', 'enum', 'instanceof', 'return', 'transient', 'catch', 'extends', 'int', 'short', 'try', 'char', 'final', 'interface', 'static', 'void', 'class', 'finally', 'long', 'strictfp', 'volatile', 'const', 'float', 'native', 'super', 'while', 'true', 'false']);
1043
+ this.p1x_1 = setOf(['abstract', 'continue', 'for', 'new', 'switch', 'assert', 'default', 'goto', 'package', 'synchronized', 'boolean', 'do', 'if', 'private', 'this', 'break', 'double', 'implements', 'protected', 'throw', 'byte', 'else', 'import', 'public', 'throws', 'case', 'enum', 'instanceof', 'return', 'transient', 'catch', 'extends', 'int', 'short', 'try', 'char', 'final', 'interface', 'static', 'void', 'class', 'finally', 'long', 'strictfp', 'volatile', 'const', 'float', 'native', 'super', 'while', 'true', 'false']);
1044
1044
  }
1045
1045
  var Companion_instance_3;
1046
1046
  function Companion_getInstance_1() {
@@ -1052,10 +1052,10 @@ function JavaIrEmitter$sanitizationConfig$lambda(it) {
1052
1052
  return '_' + it;
1053
1053
  }
1054
1054
  function JavaIrEmitter$sanitizationConfig$lambda_0(name) {
1055
- return name.l1h_1.a1() > 1 ? new Name(listOf(name.q1m())) : name;
1055
+ return name.p1h_1.a1() > 1 ? new Name(listOf(name.t1m())) : name;
1056
1056
  }
1057
1057
  function JavaIrEmitter$sanitizationConfig$lambda_1(name) {
1058
- return new Name(listOf(name.q1m()));
1058
+ return new Name(listOf(name.t1m()));
1059
1059
  }
1060
1060
  function JavaIrEmitter$sanitizationConfig$lambda_2(this$0) {
1061
1061
  return function (it) {
@@ -1066,23 +1066,23 @@ function JavaIrEmitter$sanitizationConfig$lambda_3(stmt, tr) {
1066
1066
  var tmp;
1067
1067
  var tmp_0;
1068
1068
  if (stmt instanceof FunctionCall) {
1069
- tmp_0 = stmt.a1n_1.j1j() === 'validate';
1069
+ tmp_0 = stmt.d1n_1.n1j() === 'validate';
1070
1070
  } else {
1071
1071
  tmp_0 = false;
1072
1072
  }
1073
1073
  if (tmp_0) {
1074
- tmp = transformChildren(stmt.e1n(VOID, emptyList()), tr);
1074
+ tmp = transformChildren(stmt.h1n(VOID, emptyList()), tr);
1075
1075
  } else {
1076
1076
  tmp = transformChildren(stmt, tr);
1077
1077
  }
1078
1078
  return tmp;
1079
1079
  }
1080
1080
  function JavaIrEmitter$emitShared$lambda(name) {
1081
- switch (name.j1j()) {
1081
+ switch (name.n1j()) {
1082
1082
  case 'client':
1083
- return Companion_getInstance().n1h('getClient');
1083
+ return Companion_getInstance().r1h('getClient');
1084
1084
  case 'server':
1085
- return Companion_getInstance().n1h('getServer');
1085
+ return Companion_getInstance().r1h('getServer');
1086
1086
  default:
1087
1087
  return null;
1088
1088
  }
@@ -1092,7 +1092,7 @@ function JavaIrEmitter$emitShared$lambda_0($imports) {
1092
1092
  var tmp;
1093
1093
  if (element instanceof File) {
1094
1094
  // Inline function 'kotlin.collections.partition' call
1095
- var this_0 = element.w1n_1;
1095
+ var this_0 = element.z1n_1;
1096
1096
  var first = ArrayList_init_$Create$();
1097
1097
  var second = ArrayList_init_$Create$();
1098
1098
  var _iterator__ex2g4s = this_0.t();
@@ -1107,7 +1107,7 @@ function JavaIrEmitter$emitShared$lambda_0($imports) {
1107
1107
  var _destruct__k2r9zo = new Pair(first, second);
1108
1108
  var packageElements = _destruct__k2r9zo.ve();
1109
1109
  var rest = _destruct__k2r9zo.we();
1110
- tmp = element.z1n(VOID, plus_1(plus_1(packageElements, $imports), rest));
1110
+ tmp = element.c1o(VOID, plus_1(plus_1(packageElements, $imports), rest));
1111
1111
  } else {
1112
1112
  tmp = element;
1113
1113
  }
@@ -1119,11 +1119,11 @@ function JavaIrEmitter$emitShared$lambda_1($clientServer) {
1119
1119
  return function (element, transformer) {
1120
1120
  var tmp;
1121
1121
  if (element instanceof Namespace) {
1122
- var injected = element.b1o_1.equals(Companion_getInstance().n1h('Wirespec')) ? $clientServer : emptyList();
1122
+ var injected = element.e1o_1.equals(Companion_getInstance().r1h('Wirespec')) ? $clientServer : emptyList();
1123
1123
  var tmp_0;
1124
1124
  // Inline function 'kotlin.collections.isNotEmpty' call
1125
1125
  if (!injected.r()) {
1126
- tmp_0 = withElements(element, plus_1(element.x1n(), injected));
1126
+ tmp_0 = withElements(element, plus_1(element.a1o(), injected));
1127
1127
  } else {
1128
1128
  tmp_0 = element;
1129
1129
  }
@@ -1148,7 +1148,7 @@ function JavaIrEmitter$emitGenerator$lambda_1(it) {
1148
1148
  }
1149
1149
  function JavaIrEmitter$emitGenerator$lambda_2(this$0) {
1150
1150
  return function (it) {
1151
- return import_0(this$0.u1w().ds_1 + '.model', it);
1151
+ return import_0(this$0.w1w().ds_1 + '.model', it);
1152
1152
  };
1153
1153
  }
1154
1154
  function JavaIrEmitter$emit$lambda(this$0) {
@@ -1160,37 +1160,37 @@ function JavaIrEmitter$emit$lambda_0(it) {
1160
1160
  return listOf(function_0('label', VOID, VOID, JavaIrEmitter$emit$lambda$lambda));
1161
1161
  }
1162
1162
  function JavaIrEmitter$emit$lambda$lambda($this$function) {
1163
- $this$function.b1i(String_instance);
1164
- $this$function.c1i(new VariableReference(Companion_getInstance().n1h('label')));
1163
+ $this$function.f1i(String_instance);
1164
+ $this$function.g1i(new VariableReference(Companion_getInstance().r1h('label')));
1165
1165
  return Unit_instance;
1166
1166
  }
1167
1167
  function JavaIrEmitter(packageName, emitShared) {
1168
1168
  Companion_getInstance_1();
1169
1169
  packageName = packageName === VOID ? Companion_instance.cs('community.flock.wirespec.generated') : packageName;
1170
1170
  emitShared = emitShared === VOID ? Companion_instance_0.wo() : emitShared;
1171
- this.o1x_1 = packageName;
1172
- this.p1x_1 = emitShared;
1173
- this.q1x_1 = JavaGenerator_getInstance();
1174
- this.r1x_1 = FileExtension_Java_getInstance();
1175
- this.s1x_1 = listOf(import_0('community.flock.wirespec.java', 'Wirespec'));
1171
+ this.q1x_1 = packageName;
1172
+ this.r1x_1 = emitShared;
1173
+ this.s1x_1 = JavaGenerator_getInstance();
1174
+ this.t1x_1 = FileExtension_Java_getInstance();
1175
+ this.u1x_1 = listOf(import_0('community.flock.wirespec.java', 'Wirespec'));
1176
1176
  var tmp = this;
1177
- var tmp_0 = Companion_getInstance_1().n1x_1;
1177
+ var tmp_0 = Companion_getInstance_1().p1x_1;
1178
1178
  var tmp_1 = JavaIrEmitter$sanitizationConfig$lambda;
1179
1179
  var tmp_2 = JavaIrEmitter$sanitizationConfig$lambda_0;
1180
1180
  var tmp_3 = JavaIrEmitter$sanitizationConfig$lambda_1;
1181
1181
  var tmp_4 = JavaIrEmitter$sanitizationConfig$lambda_2(this);
1182
- tmp.t1x_1 = new SanitizationConfig(tmp_0, tmp_1, tmp_2, tmp_3, tmp_4, JavaIrEmitter$sanitizationConfig$lambda_3);
1182
+ tmp.v1x_1 = new SanitizationConfig(tmp_0, tmp_1, tmp_2, tmp_3, tmp_4, JavaIrEmitter$sanitizationConfig$lambda_3);
1183
1183
  }
1184
- protoOf(JavaIrEmitter).u1w = function () {
1185
- return this.o1x_1;
1186
- };
1187
- protoOf(JavaIrEmitter).t1v = function () {
1184
+ protoOf(JavaIrEmitter).w1w = function () {
1188
1185
  return this.q1x_1;
1189
1186
  };
1187
+ protoOf(JavaIrEmitter).v1v = function () {
1188
+ return this.s1x_1;
1189
+ };
1190
1190
  protoOf(JavaIrEmitter).uq = function () {
1191
- return this.r1x_1;
1191
+ return this.t1x_1;
1192
1192
  };
1193
- protoOf(JavaIrEmitter).x1v = function () {
1193
+ protoOf(JavaIrEmitter).z1v = function () {
1194
1194
  var packageName = Companion_instance.cs('community.flock.wirespec.java');
1195
1195
  var imports = listOf_0([import_0('java.lang.reflect', 'Type'), import_0('java.lang.reflect', 'ParameterizedType'), import_0('java.util', 'List'), import_0('java.util', 'Map')]);
1196
1196
  // Inline function 'kotlin.collections.map' call
@@ -1210,28 +1210,28 @@ protoOf(JavaIrEmitter).x1v = function () {
1210
1210
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1211
1211
  var tmp = scope;
1212
1212
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1213
- var this_2 = scope.g1v_1;
1213
+ var this_2 = scope.i1v_1;
1214
1214
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1215
1215
  // Inline function 'kotlin.apply' call
1216
1216
  var this_3 = new TransformerBuilder();
1217
- this_3.x1i(JavaIrEmitter$emitShared$lambda_0(imports));
1218
- var tmp$ret$5 = this_3.y1i();
1219
- tmp.g1v_1 = transform(this_2, tmp$ret$5);
1217
+ this_3.b1j(JavaIrEmitter$emitShared$lambda_0(imports));
1218
+ var tmp$ret$5 = this_3.c1j();
1219
+ tmp.i1v_1 = transform(this_2, tmp$ret$5);
1220
1220
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.injectAfter' call
1221
1221
  var tmp_0 = scope;
1222
1222
  // Inline function 'community.flock.wirespec.ir.core.injectAfter' call
1223
1223
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1224
- var this_4 = scope.g1v_1;
1224
+ var this_4 = scope.i1v_1;
1225
1225
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1226
1226
  // Inline function 'kotlin.apply' call
1227
1227
  var this_5 = new TransformerBuilder();
1228
- this_5.x1i(JavaIrEmitter$emitShared$lambda_1(clientServer));
1229
- var tmp$ret$10 = this_5.y1i();
1230
- tmp_0.g1v_1 = transform(this_4, tmp$ret$10);
1231
- var tmp_1 = scope.g1v_1;
1228
+ this_5.b1j(JavaIrEmitter$emitShared$lambda_1(clientServer));
1229
+ var tmp$ret$10 = this_5.c1j();
1230
+ tmp_0.i1v_1 = transform(this_4, tmp$ret$10);
1231
+ var tmp_1 = scope.i1v_1;
1232
1232
  var wirespecShared = isInterface(tmp_1, Element) ? tmp_1 : THROW_CCE();
1233
1233
  var tmp_2;
1234
- if (this.p1x_1.xo_1) {
1234
+ if (this.r1x_1.xo_1) {
1235
1235
  tmp_2 = wirespecShared;
1236
1236
  } else {
1237
1237
  tmp_2 = null;
@@ -1240,9 +1240,9 @@ protoOf(JavaIrEmitter).x1v = function () {
1240
1240
  };
1241
1241
  protoOf(JavaIrEmitter).lr = function (definition, module_0, logger) {
1242
1242
  var file = emit_0.call(this, definition, module_0, logger);
1243
- var tmp = file.z1n(Companion_getInstance().n1h(sanitizeSymbol_0(this, file.v1n_1.o1h())));
1243
+ var tmp = file.c1o(Companion_getInstance().r1h(sanitizeSymbol_0(this, file.y1n_1.s1h())));
1244
1244
  // Inline function 'kotlin.takeIf' call
1245
- var this_0 = this.s1x_1;
1245
+ var this_0 = this.u1x_1;
1246
1246
  var tmp_0;
1247
1247
  if (Companion_instance_1.hr(module_0)) {
1248
1248
  tmp_0 = this_0;
@@ -1250,9 +1250,9 @@ protoOf(JavaIrEmitter).lr = function (definition, module_0, logger) {
1250
1250
  tmp_0 = null;
1251
1251
  }
1252
1252
  var tmp$ret$1 = tmp_0;
1253
- return placeInPackage(prependImports(tmp, tmp$ret$1), this.u1w(), definition);
1253
+ return placeInPackage(prependImports(tmp, tmp$ret$1), this.w1w(), definition);
1254
1254
  };
1255
- protoOf(JavaIrEmitter).c1w = function (definition, module_0) {
1255
+ protoOf(JavaIrEmitter).e1w = function (definition, module_0) {
1256
1256
  var tmp;
1257
1257
  if (definition instanceof Type) {
1258
1258
  tmp = convertToGenerator_2(definition, module_0);
@@ -1272,33 +1272,33 @@ protoOf(JavaIrEmitter).c1w = function (definition, module_0) {
1272
1272
  }
1273
1273
  }
1274
1274
  var generatorFile = tmp;
1275
- var sanitized = sanitizeNames(generatorFile, this.t1x_1);
1275
+ var sanitized = sanitizeNames(generatorFile, this.v1x_1);
1276
1276
  var generatorOwnName = definition.mr().l1() + 'Generator';
1277
1277
  var tmp_0 = asSequence_0(collectCustomTypeNames(sanitized));
1278
1278
  var tmp_1 = filterNot(tmp_0, JavaIrEmitter$emitGenerator$lambda);
1279
1279
  var tmp_2 = filterNot(tmp_1, JavaIrEmitter$emitGenerator$lambda_0(generatorOwnName));
1280
1280
  var tmp_3 = distinct_0(map(tmp_2, JavaIrEmitter$emitGenerator$lambda_1));
1281
1281
  var modelImports = toList(map(tmp_3, JavaIrEmitter$emitGenerator$lambda_2(this)));
1282
- return placeInPackage_0(prependImports(sanitized, plus_1(this.s1x_1, modelImports)), this.u1w(), 'generator');
1282
+ return placeInPackage_0(prependImports(sanitized, plus_1(this.u1x_1, modelImports)), this.w1w(), 'generator');
1283
1283
  };
1284
1284
  protoOf(JavaIrEmitter).kq = function (type, module_0) {
1285
- return sanitizeNames(convertWithValidation(type, module_0), this.t1x_1);
1285
+ return sanitizeNames(convertWithValidation(type, module_0), this.v1x_1);
1286
1286
  };
1287
1287
  protoOf(JavaIrEmitter).zr = function (enum_0, module_0) {
1288
1288
  var tmp = convert_0(enum_0);
1289
1289
  var tmp_0 = JavaIrEmitter$emit$lambda(this);
1290
- return sanitizeNames(injectEnumLabelField(tmp, tmp_0, JavaIrEmitter$emit$lambda_0), this.t1x_1);
1290
+ return sanitizeNames(injectEnumLabelField(tmp, tmp_0, JavaIrEmitter$emit$lambda_0), this.v1x_1);
1291
1291
  };
1292
1292
  protoOf(JavaIrEmitter).pr = function (union) {
1293
- return sanitizeNames(convert_1(union), this.t1x_1);
1293
+ return sanitizeNames(convert_1(union), this.v1x_1);
1294
1294
  };
1295
1295
  protoOf(JavaIrEmitter).ur = function (refined) {
1296
- return sanitizeNames(applyRefinedStructShape(convert_2(refined), refined), this.t1x_1);
1296
+ return sanitizeNames(applyRefinedStructShape(convert_2(refined), refined), this.v1x_1);
1297
1297
  };
1298
1298
  protoOf(JavaIrEmitter).as = function (endpoint) {
1299
- var tmp = sanitizeNames(transformTypeDescriptors(injectApiField(injectHandleFunction(convert_3(endpoint), endpoint))), this.t1x_1);
1299
+ var tmp = sanitizeNames(transformTypeDescriptors(injectApiField(injectHandleFunction(convert_3(endpoint), endpoint))), this.v1x_1);
1300
1300
  // Inline function 'kotlin.takeIf' call
1301
- var this_0 = buildModelImports(endpoint, this.u1w());
1301
+ var this_0 = buildModelImports(endpoint, this.w1w());
1302
1302
  var tmp_0;
1303
1303
  // Inline function 'kotlin.collections.isNotEmpty' call
1304
1304
  if (!this_0.r()) {
@@ -1312,22 +1312,22 @@ protoOf(JavaIrEmitter).as = function (endpoint) {
1312
1312
  protoOf(JavaIrEmitter).or = function (channel) {
1313
1313
  var tmp;
1314
1314
  if (channel.cp_1.l1() === channel.dp_1.l1()) {
1315
- tmp = this.u1w().ds_1 + '.model.';
1315
+ tmp = this.w1w().ds_1 + '.model.';
1316
1316
  } else {
1317
1317
  tmp = '';
1318
1318
  }
1319
1319
  var fullyQualifiedPrefix = tmp;
1320
- return applyFunctionalInterface(sanitizeNames(convert_4(channel), this.t1x_1), fullyQualifiedPrefix);
1320
+ return qualifyChannelReferences(sanitizeNames(convert_4(channel), this.v1x_1), fullyQualifiedPrefix);
1321
1321
  };
1322
- protoOf(JavaIrEmitter).b1w = function (endpoint) {
1323
- var imports = buildModelImports(endpoint, this.u1w());
1324
- var endpointImport = import_0(this.u1w().ds_1 + '.endpoint', endpoint.up_1.l1());
1322
+ protoOf(JavaIrEmitter).d1w = function (endpoint) {
1323
+ var imports = buildModelImports(endpoint, this.w1w());
1324
+ var endpointImport = import_0(this.w1w().ds_1 + '.endpoint', endpoint.up_1.l1());
1325
1325
  var endpointName = endpoint.up_1.l1();
1326
- var file = wrapAsyncReturnInThenApply(transformTypeDescriptors(sanitizeNames(emitEndpointClient.call(this, endpoint), this.t1x_1)), endpointName);
1327
- var subPackageName = plus_0(this.u1w(), 'client');
1328
- return new File(Companion_getInstance().n1h(subPackageName.fs() + sanitizeSymbol_0(this, file.v1n_1.o1h())), plus_1(plus_1(plus_1(plus_1(listOf(new Package(subPackageName.ds_1)), this.s1x_1), imports), listOf(endpointImport)), file.w1n_1));
1326
+ var file = wrapAsyncReturnInThenApply(transformTypeDescriptors(sanitizeNames(emitEndpointClient.call(this, endpoint), this.v1x_1)), endpointName);
1327
+ var subPackageName = plus_0(this.w1w(), 'client');
1328
+ return new File(Companion_getInstance().r1h(subPackageName.fs() + sanitizeSymbol_0(this, file.y1n_1.s1h())), plus_1(plus_1(plus_1(plus_1(listOf(new Package(subPackageName.ds_1)), this.u1x_1), imports), listOf(endpointImport)), file.z1n_1));
1329
1329
  };
1330
- protoOf(JavaIrEmitter).y1v = function (endpoints, logger) {
1330
+ protoOf(JavaIrEmitter).a1w = function (endpoints, logger) {
1331
1331
  // Inline function 'kotlin.collections.flatMap' call
1332
1332
  // Inline function 'kotlin.collections.flatMapTo' call
1333
1333
  var destination = ArrayList_init_$Create$();
@@ -1387,7 +1387,7 @@ protoOf(JavaIrEmitter).y1v = function (endpoints, logger) {
1387
1387
  var _iterator__ex2g4s_3 = destination_0.t();
1388
1388
  while (_iterator__ex2g4s_3.u()) {
1389
1389
  var item = _iterator__ex2g4s_3.v();
1390
- var tmp$ret$10 = import_0(this.u1w().ds_1 + '.model', item.bv_1);
1390
+ var tmp$ret$10 = import_0(this.w1w().ds_1 + '.model', item.bv_1);
1391
1391
  destination_1.x(tmp$ret$10);
1392
1392
  }
1393
1393
  var imports = destination_1;
@@ -1397,7 +1397,7 @@ protoOf(JavaIrEmitter).y1v = function (endpoints, logger) {
1397
1397
  var _iterator__ex2g4s_4 = endpoints.t();
1398
1398
  while (_iterator__ex2g4s_4.u()) {
1399
1399
  var item_0 = _iterator__ex2g4s_4.v();
1400
- var tmp$ret$13 = import_0(this.u1w().ds_1 + '.endpoint', item_0.up_1.l1());
1400
+ var tmp$ret$13 = import_0(this.w1w().ds_1 + '.endpoint', item_0.up_1.l1());
1401
1401
  destination_2.x(tmp$ret$13);
1402
1402
  }
1403
1403
  var endpointImports = destination_2;
@@ -1407,19 +1407,19 @@ protoOf(JavaIrEmitter).y1v = function (endpoints, logger) {
1407
1407
  var _iterator__ex2g4s_5 = endpoints.t();
1408
1408
  while (_iterator__ex2g4s_5.u()) {
1409
1409
  var item_1 = _iterator__ex2g4s_5.v();
1410
- var tmp$ret$16 = import_0(this.u1w().ds_1 + '.client', item_1.up_1.l1() + 'Client');
1410
+ var tmp$ret$16 = import_0(this.w1w().ds_1 + '.client', item_1.up_1.l1() + 'Client');
1411
1411
  destination_3.x(tmp$ret$16);
1412
1412
  }
1413
1413
  var clientImports = destination_3;
1414
1414
  var allImports = plus_1(plus_1(imports, endpointImports), clientImports);
1415
- var file = sanitizeNames(emitClient.call(this, endpoints, logger), this.t1x_1);
1416
- return new File(Companion_getInstance().n1h(this.u1w().fs() + sanitizeSymbol_0(this, file.v1n_1.o1h())), plus_1(plus_1(plus_1(listOf(new Package(this.u1w().ds_1)), this.s1x_1), allImports), file.w1n_1));
1415
+ var file = sanitizeNames(emitClient.call(this, endpoints, logger), this.v1x_1);
1416
+ return new File(Companion_getInstance().r1h(this.w1w().fs() + sanitizeSymbol_0(this, file.y1n_1.s1h())), plus_1(plus_1(plus_1(listOf(new Package(this.w1w().ds_1)), this.u1x_1), allImports), file.z1n_1));
1417
1417
  };
1418
1418
  function transformTypeDescriptors(_this__u8e3s4) {
1419
1419
  // Inline function 'community.flock.wirespec.ir.core.transform' call
1420
1420
  var scope = new TransformScope(_this__u8e3s4);
1421
- scope.p1v(transformTypeDescriptors$lambda);
1422
- var tmp = scope.g1v_1;
1421
+ scope.r1v(transformTypeDescriptors$lambda);
1422
+ var tmp = scope.i1v_1;
1423
1423
  return isInterface(tmp, Element) ? tmp : THROW_CCE();
1424
1424
  }
1425
1425
  function applyRefinedStructShape(_this__u8e3s4, refined) {
@@ -1428,14 +1428,14 @@ function applyRefinedStructShape(_this__u8e3s4, refined) {
1428
1428
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1429
1429
  var tmp = scope;
1430
1430
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1431
- var this_0 = scope.g1v_1;
1431
+ var this_0 = scope.i1v_1;
1432
1432
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1433
1433
  // Inline function 'kotlin.apply' call
1434
1434
  var this_1 = new TransformerBuilder();
1435
- this_1.x1i(applyRefinedStructShape$lambda(refined));
1436
- var tmp$ret$2 = this_1.y1i();
1437
- tmp.g1v_1 = transform(this_0, tmp$ret$2);
1438
- var tmp_0 = scope.g1v_1;
1435
+ this_1.b1j(applyRefinedStructShape$lambda(refined));
1436
+ var tmp$ret$2 = this_1.c1j();
1437
+ tmp.i1v_1 = transform(this_0, tmp$ret$2);
1438
+ var tmp_0 = scope.i1v_1;
1439
1439
  return isInterface(tmp_0, Element) ? tmp_0 : THROW_CCE();
1440
1440
  }
1441
1441
  function injectApiField(_this__u8e3s4) {
@@ -1445,14 +1445,14 @@ function injectApiField(_this__u8e3s4) {
1445
1445
  var tmp = scope;
1446
1446
  // Inline function 'community.flock.wirespec.ir.core.injectAfter' call
1447
1447
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1448
- var this_0 = scope.g1v_1;
1448
+ var this_0 = scope.i1v_1;
1449
1449
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1450
1450
  // Inline function 'kotlin.apply' call
1451
1451
  var this_1 = new TransformerBuilder();
1452
- this_1.x1i(injectApiField$lambda);
1453
- var tmp$ret$2 = this_1.y1i();
1454
- tmp.g1v_1 = transform(this_0, tmp$ret$2);
1455
- var tmp_0 = scope.g1v_1;
1452
+ this_1.b1j(injectApiField$lambda);
1453
+ var tmp$ret$2 = this_1.c1j();
1454
+ tmp.i1v_1 = transform(this_0, tmp$ret$2);
1455
+ var tmp_0 = scope.i1v_1;
1456
1456
  return isInterface(tmp_0, Element) ? tmp_0 : THROW_CCE();
1457
1457
  }
1458
1458
  function injectHandleFunction(_this__u8e3s4, endpoint) {
@@ -1462,14 +1462,14 @@ function injectHandleFunction(_this__u8e3s4, endpoint) {
1462
1462
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1463
1463
  var tmp = scope;
1464
1464
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1465
- var this_0 = scope.g1v_1;
1465
+ var this_0 = scope.i1v_1;
1466
1466
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1467
1467
  // Inline function 'kotlin.apply' call
1468
1468
  var this_1 = new TransformerBuilder();
1469
- this_1.x1i(injectHandleFunction$lambda(handlersStruct));
1470
- var tmp$ret$2 = this_1.y1i();
1471
- tmp.g1v_1 = transform(this_0, tmp$ret$2);
1472
- var tmp_0 = scope.g1v_1;
1469
+ this_1.b1j(injectHandleFunction$lambda(handlersStruct));
1470
+ var tmp$ret$2 = this_1.c1j();
1471
+ tmp.i1v_1 = transform(this_0, tmp$ret$2);
1472
+ var tmp_0 = scope.i1v_1;
1473
1473
  return isInterface(tmp_0, Element) ? tmp_0 : THROW_CCE();
1474
1474
  }
1475
1475
  function buildModelImports(_this__u8e3s4, packageName) {
@@ -1490,36 +1490,26 @@ function buildModelImports(_this__u8e3s4, packageName) {
1490
1490
  var _iterator__ex2g4s_0 = destination.t();
1491
1491
  while (_iterator__ex2g4s_0.u()) {
1492
1492
  var item = _iterator__ex2g4s_0.v();
1493
- var tmp$ret$3 = import_0(packageName.ds_1 + '.model', Companion_getInstance().n1h(item.bv_1).o1h());
1493
+ var tmp$ret$3 = import_0(packageName.ds_1 + '.model', Companion_getInstance().r1h(item.bv_1).s1h());
1494
1494
  destination_0.x(tmp$ret$3);
1495
1495
  }
1496
1496
  return destination_0;
1497
1497
  }
1498
- function applyFunctionalInterface(_this__u8e3s4, fullyQualifiedPrefix) {
1498
+ function qualifyChannelReferences(_this__u8e3s4, fullyQualifiedPrefix) {
1499
1499
  // Inline function 'community.flock.wirespec.ir.core.transform' call
1500
1500
  var scope = new TransformScope(_this__u8e3s4);
1501
1501
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1502
1502
  var tmp = scope;
1503
1503
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1504
- var this_0 = scope.g1v_1;
1504
+ var this_0 = scope.i1v_1;
1505
1505
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1506
1506
  // Inline function 'kotlin.apply' call
1507
1507
  var this_1 = new TransformerBuilder();
1508
- this_1.x1i(applyFunctionalInterface$lambda(fullyQualifiedPrefix));
1509
- var tmp$ret$2 = this_1.y1i();
1510
- tmp.g1v_1 = transform(this_0, tmp$ret$2);
1511
- // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1512
- var tmp_0 = scope;
1513
- // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1514
- var this_2 = scope.g1v_1;
1515
- // Inline function 'community.flock.wirespec.ir.core.transformer' call
1516
- // Inline function 'kotlin.apply' call
1517
- var this_3 = new TransformerBuilder();
1518
- this_3.x1i(applyFunctionalInterface$lambda_0);
1519
- var tmp$ret$7 = this_3.y1i();
1520
- tmp_0.g1v_1 = transform(this_2, tmp$ret$7);
1521
- var tmp_1 = scope.g1v_1;
1522
- return isInterface(tmp_1, Element) ? tmp_1 : THROW_CCE();
1508
+ this_1.b1j(qualifyChannelReferences$lambda(fullyQualifiedPrefix));
1509
+ var tmp$ret$2 = this_1.c1j();
1510
+ tmp.i1v_1 = transform(this_0, tmp$ret$2);
1511
+ var tmp_0 = scope.i1v_1;
1512
+ return isInterface(tmp_0, Element) ? tmp_0 : THROW_CCE();
1523
1513
  }
1524
1514
  function wrapAsyncReturnInThenApply(_this__u8e3s4, endpointName) {
1525
1515
  // Inline function 'community.flock.wirespec.ir.core.transform' call
@@ -1527,26 +1517,26 @@ function wrapAsyncReturnInThenApply(_this__u8e3s4, endpointName) {
1527
1517
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.matchingElements' call
1528
1518
  var tmp = scope;
1529
1519
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1530
- var this_0 = scope.g1v_1;
1520
+ var this_0 = scope.i1v_1;
1531
1521
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1532
1522
  // Inline function 'kotlin.apply' call
1533
1523
  var this_1 = new TransformerBuilder();
1534
- this_1.x1i(wrapAsyncReturnInThenApply$lambda(endpointName));
1535
- var tmp$ret$2 = this_1.y1i();
1536
- tmp.g1v_1 = transform(this_0, tmp$ret$2);
1537
- var tmp_0 = scope.g1v_1;
1524
+ this_1.b1j(wrapAsyncReturnInThenApply$lambda(endpointName));
1525
+ var tmp$ret$2 = this_1.c1j();
1526
+ tmp.i1v_1 = transform(this_0, tmp$ret$2);
1527
+ var tmp_0 = scope.i1v_1;
1538
1528
  return isInterface(tmp_0, Element) ? tmp_0 : THROW_CCE();
1539
1529
  }
1540
1530
  function findRoot(_this__u8e3s4) {
1541
1531
  var tmp;
1542
1532
  if (_this__u8e3s4 instanceof Nullable) {
1543
- tmp = findRoot(_this__u8e3s4.f1j_1);
1533
+ tmp = findRoot(_this__u8e3s4.j1j_1);
1544
1534
  } else {
1545
1535
  if (_this__u8e3s4 instanceof Array_0) {
1546
- tmp = findRoot(_this__u8e3s4.g1j_1);
1536
+ tmp = findRoot(_this__u8e3s4.k1j_1);
1547
1537
  } else {
1548
1538
  if (_this__u8e3s4 instanceof Dict_0) {
1549
- tmp = findRoot(_this__u8e3s4.j1n_1);
1539
+ tmp = findRoot(_this__u8e3s4.m1n_1);
1550
1540
  } else {
1551
1541
  tmp = _this__u8e3s4;
1552
1542
  }
@@ -1575,7 +1565,7 @@ function toJavaName(_this__u8e3s4) {
1575
1565
  var tmp;
1576
1566
  if (_this__u8e3s4 instanceof Integer_0) {
1577
1567
  var tmp_0;
1578
- switch (_this__u8e3s4.f1n_1.b3_1) {
1568
+ switch (_this__u8e3s4.i1n_1.b3_1) {
1579
1569
  case 0:
1580
1570
  tmp_0 = 'Integer';
1581
1571
  break;
@@ -1590,7 +1580,7 @@ function toJavaName(_this__u8e3s4) {
1590
1580
  } else {
1591
1581
  if (_this__u8e3s4 instanceof Number_1) {
1592
1582
  var tmp_1;
1593
- switch (_this__u8e3s4.g1n_1.b3_1) {
1583
+ switch (_this__u8e3s4.j1n_1.b3_1) {
1594
1584
  case 0:
1595
1585
  tmp_1 = 'Float';
1596
1586
  break;
@@ -1619,7 +1609,7 @@ function toJavaName(_this__u8e3s4) {
1619
1609
  tmp = 'Void';
1620
1610
  } else {
1621
1611
  if (_this__u8e3s4 instanceof Custom_0) {
1622
- tmp = _this__u8e3s4.h1j_1.o1h();
1612
+ tmp = _this__u8e3s4.l1j_1.s1h();
1623
1613
  } else {
1624
1614
  tmp = 'Object';
1625
1615
  }
@@ -1642,9 +1632,17 @@ function withFullyQualifiedPrefix(_this__u8e3s4, prefix) {
1642
1632
  if (charSequenceLength(prefix) > 0) {
1643
1633
  // Inline function 'community.flock.wirespec.ir.core.transform' call
1644
1634
  var scope = new TransformScope(_this__u8e3s4);
1645
- var tmp_0 = withFullyQualifiedPrefix$lambda;
1646
- scope.j1v(tmp_0, withFullyQualifiedPrefix$lambda_0(prefix));
1647
- var tmp_1 = scope.g1v_1;
1635
+ // Inline function 'community.flock.wirespec.ir.core.TransformScope.matching' call
1636
+ var tmp_0 = scope;
1637
+ // Inline function 'community.flock.wirespec.ir.core.transformMatching' call
1638
+ var this_0 = scope.i1v_1;
1639
+ // Inline function 'community.flock.wirespec.ir.core.transformer' call
1640
+ // Inline function 'kotlin.apply' call
1641
+ var this_1 = new TransformerBuilder();
1642
+ this_1.o1v(withFullyQualifiedPrefix$lambda(prefix));
1643
+ var tmp$ret$3 = this_1.c1j();
1644
+ tmp_0.i1v_1 = transform(this_0, tmp$ret$3);
1645
+ var tmp_1 = scope.i1v_1;
1648
1646
  tmp = isInterface(tmp_1, Element) ? tmp_1 : THROW_CCE();
1649
1647
  } else {
1650
1648
  tmp = _this__u8e3s4;
@@ -1654,8 +1652,8 @@ function withFullyQualifiedPrefix(_this__u8e3s4, prefix) {
1654
1652
  function transformTypeDescriptors$lambda(stmt, tr) {
1655
1653
  var tmp;
1656
1654
  if (stmt instanceof TypeDescriptor) {
1657
- var rootType = findRoot(stmt.l1p_1);
1658
- var containerStr = rawContainerClass(stmt.l1p_1);
1655
+ var rootType = findRoot(stmt.o1p_1);
1656
+ var containerStr = rawContainerClass(stmt.o1p_1);
1659
1657
  var rootStr = toJavaName(rootType) + '.class';
1660
1658
  var tmp_0;
1661
1659
  if (containerStr == null) {
@@ -1674,8 +1672,8 @@ function transformTypeDescriptors$lambda(stmt, tr) {
1674
1672
  }
1675
1673
  function applyRefinedStructShape$lambda$lambda($refined) {
1676
1674
  return function ($this$function) {
1677
- $this$function.b1i(convert_5($refined.tr_1));
1678
- $this$function.c1i(new VariableReference(Companion_getInstance().n1h('value')));
1675
+ $this$function.f1i(convert_5($refined.tr_1));
1676
+ $this$function.g1i(new VariableReference(Companion_getInstance().r1h('value')));
1679
1677
  return Unit_instance;
1680
1678
  };
1681
1679
  }
@@ -1685,18 +1683,18 @@ function applyRefinedStructShape$lambda($refined) {
1685
1683
  if (element instanceof Struct) {
1686
1684
  var tmp_0 = listOf(Custom_init_$Create$('Wirespec.Refined'));
1687
1685
  // Inline function 'kotlin.collections.map' call
1688
- var this_0 = element.k1o_1;
1686
+ var this_0 = element.n1o_1;
1689
1687
  // Inline function 'kotlin.collections.mapTo' call
1690
1688
  var destination = ArrayList_init_$Create$_0(collectionSizeOrDefault(this_0, 10));
1691
1689
  var _iterator__ex2g4s = this_0.t();
1692
1690
  while (_iterator__ex2g4s.u()) {
1693
1691
  var item = _iterator__ex2g4s.v();
1694
1692
  var tmp0_safe_receiver = item instanceof Function ? item : null;
1695
- var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.l1l(VOID, VOID, VOID, VOID, VOID, VOID, VOID, true);
1693
+ var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.p1l(VOID, VOID, VOID, VOID, VOID, VOID, VOID, true);
1696
1694
  var tmp$ret$0 = tmp1_elvis_lhs == null ? item : tmp1_elvis_lhs;
1697
1695
  destination.x(tmp$ret$0);
1698
1696
  }
1699
- var tmp_1 = element.n1o(VOID, VOID, VOID, tmp_0, destination);
1697
+ var tmp_1 = element.q1o(VOID, VOID, VOID, tmp_0, destination);
1700
1698
  tmp = plus_3(tmp_1, function_0('value', VOID, true, applyRefinedStructShape$lambda$lambda($refined)));
1701
1699
  } else {
1702
1700
  tmp = element;
@@ -1712,7 +1710,7 @@ function injectApiField$lambda(element, transformer) {
1712
1710
  var tmp_0;
1713
1711
  // Inline function 'kotlin.collections.isNotEmpty' call
1714
1712
  if (!injected.r()) {
1715
- tmp_0 = withElements(element, plus_1(element.x1n(), injected));
1713
+ tmp_0 = withElements(element, plus_1(element.a1o(), injected));
1716
1714
  } else {
1717
1715
  tmp_0 = element;
1718
1716
  }
@@ -1731,7 +1729,7 @@ function injectHandleFunction$lambda$lambda($handlersStruct) {
1731
1729
  var tmp_0;
1732
1730
  // Inline function 'kotlin.collections.isNotEmpty' call
1733
1731
  if (!injected.r()) {
1734
- tmp_0 = withElements(element, plus_1(element.x1n(), injected));
1732
+ tmp_0 = withElements(element, plus_1(element.a1o(), injected));
1735
1733
  } else {
1736
1734
  tmp_0 = element;
1737
1735
  }
@@ -1748,21 +1746,21 @@ function injectHandleFunction$lambda($handlersStruct) {
1748
1746
  var tmp;
1749
1747
  if (element instanceof Interface) {
1750
1748
  var tmp_0;
1751
- if (element.p1o_1.equals(Companion_getInstance().n1h('Handler'))) {
1749
+ if (element.s1o_1.equals(Companion_getInstance().r1h('Handler'))) {
1752
1750
  // Inline function 'community.flock.wirespec.ir.core.transform' call
1753
1751
  var scope = new TransformScope(element);
1754
1752
  // Inline function 'community.flock.wirespec.ir.core.TransformScope.injectAfter' call
1755
1753
  var tmp_1 = scope;
1756
1754
  // Inline function 'community.flock.wirespec.ir.core.injectAfter' call
1757
1755
  // Inline function 'community.flock.wirespec.ir.core.transformMatchingElements' call
1758
- var this_0 = scope.g1v_1;
1756
+ var this_0 = scope.i1v_1;
1759
1757
  // Inline function 'community.flock.wirespec.ir.core.transformer' call
1760
1758
  // Inline function 'kotlin.apply' call
1761
1759
  var this_1 = new TransformerBuilder();
1762
- this_1.x1i(injectHandleFunction$lambda$lambda($handlersStruct));
1763
- var tmp$ret$2 = this_1.y1i();
1764
- tmp_1.g1v_1 = transform(this_0, tmp$ret$2);
1765
- var tmp_2 = scope.g1v_1;
1760
+ this_1.b1j(injectHandleFunction$lambda$lambda($handlersStruct));
1761
+ var tmp$ret$2 = this_1.c1j();
1762
+ tmp_1.i1v_1 = transform(this_0, tmp$ret$2);
1763
+ var tmp_2 = scope.i1v_1;
1766
1764
  tmp_0 = isInterface(tmp_2, Element) ? tmp_2 : THROW_CCE();
1767
1765
  } else {
1768
1766
  tmp_0 = element;
@@ -1775,7 +1773,7 @@ function injectHandleFunction$lambda($handlersStruct) {
1775
1773
  return transformChildren_0(transformed, transformer);
1776
1774
  };
1777
1775
  }
1778
- function applyFunctionalInterface$lambda($fullyQualifiedPrefix) {
1776
+ function qualifyChannelReferences$lambda($fullyQualifiedPrefix) {
1779
1777
  return function (element, transformer) {
1780
1778
  var tmp;
1781
1779
  if (element instanceof Interface) {
@@ -1787,41 +1785,17 @@ function applyFunctionalInterface$lambda($fullyQualifiedPrefix) {
1787
1785
  return transformChildren_0(transformed, transformer);
1788
1786
  };
1789
1787
  }
1790
- function applyFunctionalInterface$lambda_0(element, transformer) {
1791
- var tmp;
1792
- if (element instanceof File) {
1793
- // Inline function 'community.flock.wirespec.ir.core.findElement' call
1794
- // Inline function 'kotlin.collections.filterIsInstance' call
1795
- var tmp0 = element.x1n();
1796
- // Inline function 'kotlin.collections.filterIsInstanceTo' call
1797
- var destination = ArrayList_init_$Create$();
1798
- var _iterator__ex2g4s = tmp0.t();
1799
- while (_iterator__ex2g4s.u()) {
1800
- var element_0 = _iterator__ex2g4s.v();
1801
- if (element_0 instanceof Interface) {
1802
- destination.x(element_0);
1803
- }
1804
- }
1805
- var tmp$ret$2 = firstOrNull_0(destination);
1806
- var interfaceElement = ensureNotNull(tmp$ret$2);
1807
- tmp = element.z1n(VOID, listOf_0([new RawElement('@FunctionalInterface\n'), interfaceElement]));
1808
- } else {
1809
- tmp = element;
1810
- }
1811
- var transformed = tmp;
1812
- return transformChildren_0(transformed, transformer);
1813
- }
1814
1788
  function wrapAsyncReturnInThenApply$lambda($endpointName) {
1815
1789
  return function (element, transformer) {
1816
1790
  var tmp;
1817
1791
  if (element instanceof Function) {
1818
1792
  var tmp$ret$0;
1819
1793
  $l$block_1: {
1820
- if (!element.i1l_1 || element.h1l_1.a1() < 2) {
1794
+ if (!element.m1l_1 || element.l1l_1.a1() < 2) {
1821
1795
  tmp$ret$0 = element;
1822
1796
  break $l$block_1;
1823
1797
  }
1824
- var tmp_0 = element.h1l_1.b1(element.h1l_1.a1() - 2 | 0);
1798
+ var tmp_0 = element.l1l_1.b1(element.l1l_1.a1() - 2 | 0);
1825
1799
  var tmp0_elvis_lhs = tmp_0 instanceof Assignment ? tmp_0 : null;
1826
1800
  var tmp_1;
1827
1801
  if (tmp0_elvis_lhs == null) {
@@ -1831,16 +1805,16 @@ function wrapAsyncReturnInThenApply$lambda($endpointName) {
1831
1805
  tmp_1 = tmp0_elvis_lhs;
1832
1806
  }
1833
1807
  var transportAssign = tmp_1;
1834
- var tmp_2 = last(element.h1l_1);
1808
+ var tmp_2 = last(element.l1l_1);
1835
1809
  if (!(tmp_2 instanceof ReturnStatement)) {
1836
1810
  tmp$ret$0 = element;
1837
1811
  break $l$block_1;
1838
1812
  }
1839
- var tmp_3 = dropLast(element.h1l_1, 2);
1840
- var tmp1_name = Companion_getInstance().n1h('thenApply');
1841
- var tmp2_receiver = transportAssign.o1p_1;
1842
- var tmp3_arguments = mapOf(to(Companion_getInstance().n1h('mapper'), new RawExpression('rawResponse -> ' + $endpointName + '.fromRawResponse(serialization(), rawResponse)')));
1843
- tmp$ret$0 = element.l1l(VOID, VOID, VOID, VOID, plus_2(tmp_3, new ReturnStatement(new FunctionCall(tmp2_receiver, VOID, tmp1_name, tmp3_arguments))));
1813
+ var tmp_3 = dropLast(element.l1l_1, 2);
1814
+ var tmp1_name = Companion_getInstance().r1h('thenApply');
1815
+ var tmp2_receiver = transportAssign.r1p_1;
1816
+ var tmp3_arguments = mapOf(to(Companion_getInstance().r1h('mapper'), new RawExpression('rawResponse -> ' + $endpointName + '.fromRawResponse(serialization(), rawResponse)')));
1817
+ tmp$ret$0 = element.p1l(VOID, VOID, VOID, VOID, plus_2(tmp_3, new ReturnStatement(new FunctionCall(tmp2_receiver, VOID, tmp1_name, tmp3_arguments))));
1844
1818
  }
1845
1819
  tmp = tmp$ret$0;
1846
1820
  } else {
@@ -1865,62 +1839,59 @@ function buildHandlersStruct$lambda(it) {
1865
1839
  }
1866
1840
  function buildHandlersStruct$lambda$lambda($pathTemplate) {
1867
1841
  return function ($this$function) {
1868
- $this$function.b1i(String_instance);
1869
- $this$function.c1i($this$function.l1u($pathTemplate));
1842
+ $this$function.f1i(String_instance);
1843
+ $this$function.g1i($this$function.o1u($pathTemplate));
1870
1844
  return Unit_instance;
1871
1845
  };
1872
1846
  }
1873
1847
  function buildHandlersStruct$lambda$lambda_0($this_buildHandlersStruct) {
1874
1848
  return function ($this$function) {
1875
- $this$function.b1i(String_instance);
1876
- $this$function.c1i($this$function.l1u($this_buildHandlersStruct.vp_1.a3_1));
1849
+ $this$function.f1i(String_instance);
1850
+ $this$function.g1i($this$function.o1u($this_buildHandlersStruct.vp_1.a3_1));
1877
1851
  return Unit_instance;
1878
1852
  };
1879
1853
  }
1880
1854
  function buildHandlersStruct$lambda$lambda_1($this$function) {
1881
- $this$function.b1i($this$function.p1h('Wirespec.ServerEdge', [$this$function.p1h('Request', []), $this$function.p1h('Response', [Wildcard_instance])]));
1882
- $this$function.y1h('serialization', $this$function.p1h('Wirespec.Serialization', []));
1883
- $this$function.c1i(new RawExpression('new Wirespec.ServerEdge<>() {\n@Override public Request from(Wirespec.RawRequest request) {\n return fromRawRequest(serialization, request);\n}\n@Override public Wirespec.RawResponse to(Response<?> response) {\n return toRawResponse(serialization, response);\n}\n}'));
1855
+ $this$function.f1i($this$function.t1h('Wirespec.ServerEdge', [$this$function.t1h('Request', []), $this$function.t1h('Response', [Wildcard_instance])]));
1856
+ $this$function.c1i('serialization', $this$function.t1h('Wirespec.Serialization', []));
1857
+ $this$function.g1i(new RawExpression('new Wirespec.ServerEdge<>() {\n@Override public Request from(Wirespec.RawRequest request) {\n return fromRawRequest(serialization, request);\n}\n@Override public Wirespec.RawResponse to(Response<?> response) {\n return toRawResponse(serialization, response);\n}\n}'));
1884
1858
  return Unit_instance;
1885
1859
  }
1886
1860
  function buildHandlersStruct$lambda$lambda_2($this$function) {
1887
- $this$function.b1i($this$function.p1h('Wirespec.ClientEdge', [$this$function.p1h('Request', []), $this$function.p1h('Response', [Wildcard_instance])]));
1888
- $this$function.y1h('serialization', $this$function.p1h('Wirespec.Serialization', []));
1889
- $this$function.c1i(new RawExpression('new Wirespec.ClientEdge<>() {\n@Override public Wirespec.RawRequest to(Request request) {\n return toRawRequest(serialization, request);\n}\n@Override public Response<?> from(Wirespec.RawResponse response) {\n return fromRawResponse(serialization, response);\n}\n}'));
1861
+ $this$function.f1i($this$function.t1h('Wirespec.ClientEdge', [$this$function.t1h('Request', []), $this$function.t1h('Response', [Wildcard_instance])]));
1862
+ $this$function.c1i('serialization', $this$function.t1h('Wirespec.Serialization', []));
1863
+ $this$function.g1i(new RawExpression('new Wirespec.ClientEdge<>() {\n@Override public Wirespec.RawRequest to(Request request) {\n return toRawRequest(serialization, request);\n}\n@Override public Response<?> from(Wirespec.RawResponse response) {\n return fromRawResponse(serialization, response);\n}\n}'));
1890
1864
  return Unit_instance;
1891
1865
  }
1892
1866
  function buildHandlersStruct$lambda_0($pathTemplate, $this_buildHandlersStruct) {
1893
1867
  return function ($this$struct) {
1894
- $this$struct.u1k($this$struct.p1h('Wirespec.Server', [$this$struct.p1h('Request', []), $this$struct.p1h('Response', [Wildcard_instance])]));
1895
- $this$struct.u1k($this$struct.p1h('Wirespec.Client', [$this$struct.p1h('Request', []), $this$struct.p1h('Response', [Wildcard_instance])]));
1896
- $this$struct.d1i('getPathTemplate', VOID, true, buildHandlersStruct$lambda$lambda($pathTemplate));
1897
- $this$struct.d1i('getMethod', VOID, true, buildHandlersStruct$lambda$lambda_0($this_buildHandlersStruct));
1898
- $this$struct.d1i('getServer', VOID, true, buildHandlersStruct$lambda$lambda_1);
1899
- $this$struct.d1i('getClient', VOID, true, buildHandlersStruct$lambda$lambda_2);
1868
+ $this$struct.y1k($this$struct.t1h('Wirespec.Server', [$this$struct.t1h('Request', []), $this$struct.t1h('Response', [Wildcard_instance])]));
1869
+ $this$struct.y1k($this$struct.t1h('Wirespec.Client', [$this$struct.t1h('Request', []), $this$struct.t1h('Response', [Wildcard_instance])]));
1870
+ $this$struct.h1i('getPathTemplate', VOID, true, buildHandlersStruct$lambda$lambda($pathTemplate));
1871
+ $this$struct.h1i('getMethod', VOID, true, buildHandlersStruct$lambda$lambda_0($this_buildHandlersStruct));
1872
+ $this$struct.h1i('getServer', VOID, true, buildHandlersStruct$lambda$lambda_1);
1873
+ $this$struct.h1i('getClient', VOID, true, buildHandlersStruct$lambda$lambda_2);
1900
1874
  return Unit_instance;
1901
1875
  };
1902
1876
  }
1903
- function withFullyQualifiedPrefix$lambda(it) {
1904
- return it.y1p_1.equals(Companion_getInstance().n1h('message'));
1905
- }
1906
- function withFullyQualifiedPrefix$lambda_0($prefix) {
1907
- return function (param) {
1908
- var t = param.z1p_1;
1877
+ function withFullyQualifiedPrefix$lambda($prefix) {
1878
+ return function (type, transformer) {
1909
1879
  var tmp;
1910
- if (t instanceof Custom_0) {
1911
- tmp = param.b1q(VOID, t.m1n(Companion_getInstance().n1h($prefix + t.h1j_1.o1h())));
1880
+ if (type instanceof Custom_0) {
1881
+ tmp = type.p1n(new Name(listOf($prefix + type.l1j_1.s1h())));
1912
1882
  } else {
1913
- tmp = param;
1883
+ tmp = type;
1914
1884
  }
1915
- return tmp;
1885
+ var transformed = tmp;
1886
+ return transformChildren_1(transformed, transformer);
1916
1887
  };
1917
1888
  }
1918
1889
  function JavaRefinedTypeDefinitionEmitter() {
1919
1890
  }
1920
1891
  function JavaShared() {
1921
1892
  JavaShared_instance = this;
1922
- this.e1x_1 = 'community.flock.wirespec.java';
1923
- this.f1x_1 = trimMargin('\n |package ' + this.e1x_1 + ';\n |\n |import java.lang.reflect.Type;\n |import java.lang.reflect.ParameterizedType;\n |import java.util.List;\n |import java.util.Map;\n |import java.util.Optional;\n |\n |public interface Wirespec {\n |' + Spacer_instance.toString() + 'interface Enum { String label(); }\n |' + Spacer_instance.toString() + 'interface Endpoint {}\n |' + Spacer_instance.toString() + 'interface Refined<T> { T value(); }\n |' + Spacer_instance.toString() + 'interface Path {}\n |' + Spacer_instance.toString() + 'interface Queries {}\n |' + Spacer_instance.toString() + 'interface Headers {}\n |' + Spacer_instance.toString() + 'interface Handler {}\n |' + Spacer_instance.toString() + 'interface ServerEdge<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'Req from(RawRequest request);\n |' + Spacer_instance.hs(2) + 'RawResponse to(Res response);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface ClientEdge<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'RawRequest to(Req request);\n |' + Spacer_instance.hs(2) + 'Res from(RawResponse response);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface Client<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'String getPathTemplate();\n |' + Spacer_instance.hs(2) + 'String getMethod();\n |' + Spacer_instance.hs(2) + 'ClientEdge<Req, Res> getClient(Serialization serialization);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface Server<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'String getPathTemplate();\n |' + Spacer_instance.hs(2) + 'String getMethod();\n |' + Spacer_instance.hs(2) + 'ServerEdge<Req, Res> getServer(Serialization serialization);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'enum Method { GET, PUT, POST, DELETE, OPTIONS, HEAD, PATCH, TRACE }\n |' + Spacer_instance.toString() + 'interface Request<T> { Path path(); Method method(); Queries queries(); Headers headers(); T body(); interface Headers extends Wirespec.Headers {} }\n |' + Spacer_instance.toString() + 'interface Response<T> { Integer status(); Headers headers(); T body(); interface Headers extends Wirespec.Headers {} }\n |' + Spacer_instance.toString() + 'interface Serialization extends Serializer, Deserializer {}\n |' + Spacer_instance.toString() + 'interface Serializer extends BodySerializer, PathSerializer, ParamSerializer {}\n |' + Spacer_instance.toString() + 'interface Deserializer extends BodyDeserializer, PathDeserializer, ParamDeserializer {}\n |' + Spacer_instance.toString() + 'interface BodySerialization extends BodySerializer, BodyDeserializer {}\n |' + Spacer_instance.toString() + 'interface BodySerializer { <T> byte[] serializeBody(T t, Type type); }\n |' + Spacer_instance.toString() + 'interface BodyDeserializer { <T> T deserializeBody(byte[] raw, Type type); }\n |' + Spacer_instance.toString() + 'interface PathSerialization extends PathSerializer, PathDeserializer {}\n |' + Spacer_instance.toString() + 'interface PathSerializer { <T> String serializePath(T t, Type type); }\n |' + Spacer_instance.toString() + 'interface PathDeserializer { <T> T deserializePath(String raw, Type type); }\n |' + Spacer_instance.toString() + 'interface ParamSerialization extends ParamSerializer, ParamDeserializer {}\n |' + Spacer_instance.toString() + 'interface ParamSerializer { <T> List<String> serializeParam(T value, Type type); }\n |' + Spacer_instance.toString() + 'interface ParamDeserializer { <T> T deserializeParam(List<String> values, Type type); }\n |' + Spacer_instance.toString() + 'record RawRequest(String method, List<String> path, Map<String, List<String>> queries, Map<String, List<String>> headers, Optional<byte[]> body) {}\n |' + Spacer_instance.toString() + 'record RawResponse(int statusCode, Map<String, List<String>> headers, Optional<byte[]> body) {}\n |' + Spacer_instance.toString() + 'static Type getType(final Class<?> actualTypeArguments, final Class<?> rawType) {\n |' + Spacer_instance.hs(2) + 'if(rawType != null) {\n |' + Spacer_instance.hs(3) + 'return new ParameterizedType() {\n |' + Spacer_instance.hs(4) + 'public Type getRawType() { return rawType; }\n |' + Spacer_instance.hs(4) + 'public Type[] getActualTypeArguments() { return new Class<?>[]{actualTypeArguments}; }\n |' + Spacer_instance.hs(4) + 'public Type getOwnerType() { return null; }\n |' + Spacer_instance.hs(3) + '};\n |' + Spacer_instance.hs(2) + '}\n |' + Spacer_instance.hs(2) + 'else { return actualTypeArguments; }\n |' + Spacer_instance.toString() + '}\n |}\n |\n ');
1893
+ this.g1x_1 = 'community.flock.wirespec.java';
1894
+ this.h1x_1 = trimMargin('\n |package ' + this.g1x_1 + ';\n |\n |import java.lang.reflect.Type;\n |import java.lang.reflect.ParameterizedType;\n |import java.util.List;\n |import java.util.Map;\n |import java.util.Optional;\n |\n |public interface Wirespec {\n |' + Spacer_instance.toString() + 'interface Enum { String label(); }\n |' + Spacer_instance.toString() + 'interface Endpoint {}\n |' + Spacer_instance.toString() + 'interface Refined<T> { T value(); }\n |' + Spacer_instance.toString() + 'interface Path {}\n |' + Spacer_instance.toString() + 'interface Queries {}\n |' + Spacer_instance.toString() + 'interface Headers {}\n |' + Spacer_instance.toString() + 'interface Handler {}\n |' + Spacer_instance.toString() + 'interface ServerEdge<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'Req from(RawRequest request);\n |' + Spacer_instance.hs(2) + 'RawResponse to(Res response);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface ClientEdge<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'RawRequest to(Req request);\n |' + Spacer_instance.hs(2) + 'Res from(RawResponse response);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface Client<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'String getPathTemplate();\n |' + Spacer_instance.hs(2) + 'String getMethod();\n |' + Spacer_instance.hs(2) + 'ClientEdge<Req, Res> getClient(Serialization serialization);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'interface Server<Req extends Request<?>, Res extends Response<?>> {\n |' + Spacer_instance.hs(2) + 'String getPathTemplate();\n |' + Spacer_instance.hs(2) + 'String getMethod();\n |' + Spacer_instance.hs(2) + 'ServerEdge<Req, Res> getServer(Serialization serialization);\n |' + Spacer_instance.toString() + '}\n |' + Spacer_instance.toString() + 'enum Method { GET, PUT, POST, DELETE, OPTIONS, HEAD, PATCH, TRACE }\n |' + Spacer_instance.toString() + 'interface Request<T> { Path path(); Method method(); Queries queries(); Headers headers(); T body(); interface Headers extends Wirespec.Headers {} }\n |' + Spacer_instance.toString() + 'interface Response<T> { Integer status(); Headers headers(); T body(); interface Headers extends Wirespec.Headers {} }\n |' + Spacer_instance.toString() + 'interface Serialization extends Serializer, Deserializer {}\n |' + Spacer_instance.toString() + 'interface Serializer extends BodySerializer, PathSerializer, ParamSerializer {}\n |' + Spacer_instance.toString() + 'interface Deserializer extends BodyDeserializer, PathDeserializer, ParamDeserializer {}\n |' + Spacer_instance.toString() + 'interface BodySerialization extends BodySerializer, BodyDeserializer {}\n |' + Spacer_instance.toString() + 'interface BodySerializer { <T> byte[] serializeBody(T t, Type type); }\n |' + Spacer_instance.toString() + 'interface BodyDeserializer { <T> T deserializeBody(byte[] raw, Type type); }\n |' + Spacer_instance.toString() + 'interface PathSerialization extends PathSerializer, PathDeserializer {}\n |' + Spacer_instance.toString() + 'interface PathSerializer { <T> String serializePath(T t, Type type); }\n |' + Spacer_instance.toString() + 'interface PathDeserializer { <T> T deserializePath(String raw, Type type); }\n |' + Spacer_instance.toString() + 'interface ParamSerialization extends ParamSerializer, ParamDeserializer {}\n |' + Spacer_instance.toString() + 'interface ParamSerializer { <T> List<String> serializeParam(T value, Type type); }\n |' + Spacer_instance.toString() + 'interface ParamDeserializer { <T> T deserializeParam(List<String> values, Type type); }\n |' + Spacer_instance.toString() + 'record RawRequest(String method, List<String> path, Map<String, List<String>> queries, Map<String, List<String>> headers, Optional<byte[]> body) {}\n |' + Spacer_instance.toString() + 'record RawResponse(int statusCode, Map<String, List<String>> headers, Optional<byte[]> body) {}\n |' + Spacer_instance.toString() + 'static Type getType(final Class<?> actualTypeArguments, final Class<?> rawType) {\n |' + Spacer_instance.hs(2) + 'if(rawType != null) {\n |' + Spacer_instance.hs(3) + 'return new ParameterizedType() {\n |' + Spacer_instance.hs(4) + 'public Type getRawType() { return rawType; }\n |' + Spacer_instance.hs(4) + 'public Type[] getActualTypeArguments() { return new Class<?>[]{actualTypeArguments}; }\n |' + Spacer_instance.hs(4) + 'public Type getOwnerType() { return null; }\n |' + Spacer_instance.hs(3) + '};\n |' + Spacer_instance.hs(2) + '}\n |' + Spacer_instance.hs(2) + 'else { return actualTypeArguments; }\n |' + Spacer_instance.toString() + '}\n |}\n |\n ');
1924
1895
  }
1925
1896
  protoOf(JavaShared).toString = function () {
1926
1897
  return 'JavaShared';
@@ -2038,30 +2009,30 @@ function JavaUnionDefinitionEmitter$emit$lambda(it) {
2038
2009
  function JavaUnionDefinitionEmitter() {
2039
2010
  }
2040
2011
  //region block: post-declaration
2041
- protoOf(JavaEmitter).nr = emit_12;
2012
+ protoOf(JavaEmitter).nr = emit_10;
2042
2013
  protoOf(JavaEmitter).kq = emit_3;
2043
2014
  protoOf(JavaEmitter).lq = emit_4;
2044
2015
  protoOf(JavaEmitter).mq = emit_5;
2045
2016
  protoOf(JavaEmitter).nq = emit_6;
2046
2017
  protoOf(JavaEmitter).oq = emit_7;
2047
- protoOf(JavaEmitter).as = emit_9;
2048
- protoOf(JavaEmitter).h1x = emit_10;
2049
- protoOf(JavaEmitter).i1x = emit_11;
2018
+ protoOf(JavaEmitter).as = emit_12;
2019
+ protoOf(JavaEmitter).j1x = emit_13;
2020
+ protoOf(JavaEmitter).k1x = emit_14;
2050
2021
  protoOf(JavaEmitter).or = emit_8;
2051
2022
  protoOf(JavaEmitter).zr = emit_15;
2052
- protoOf(JavaEmitter).pr = emit_13;
2053
- protoOf(JavaEmitter).ur = emit_14;
2054
- protoOf(JavaEmitter).g1x = sanitizeSymbol;
2055
- protoOf(JavaEmitter).j1x = sanitizeFirstIsDigit;
2056
- protoOf(JavaEmitter).k1x = sanitizeKeywords;
2057
- protoOf(JavaEmitter).w1w = emitRoot;
2058
- protoOf(JavaEmitter).v1w = emitRoot$default;
2059
- protoOf(JavaEmitter).l1x = emitHandleFunction;
2023
+ protoOf(JavaEmitter).pr = emit_11;
2024
+ protoOf(JavaEmitter).ur = emit_9;
2025
+ protoOf(JavaEmitter).i1x = sanitizeSymbol;
2026
+ protoOf(JavaEmitter).l1x = sanitizeFirstIsDigit;
2027
+ protoOf(JavaEmitter).m1x = sanitizeKeywords;
2028
+ protoOf(JavaEmitter).y1w = emitRoot;
2029
+ protoOf(JavaEmitter).x1w = emitRoot$default;
2030
+ protoOf(JavaEmitter).n1x = emitHandleFunction;
2060
2031
  protoOf(JavaEmitter).bs = emitValidator;
2061
- protoOf(JavaIrEmitter).v1v = get_extensions;
2032
+ protoOf(JavaIrEmitter).x1v = get_extensions;
2062
2033
  protoOf(JavaIrEmitter).eo = emit_1;
2063
- protoOf(JavaIrEmitter).w1v = emit_2;
2064
- protoOf(JavaIrEmitter).a1w = beforeGenerate;
2034
+ protoOf(JavaIrEmitter).y1v = emit_2;
2035
+ protoOf(JavaIrEmitter).c1w = beforeGenerate;
2065
2036
  //endregion
2066
2037
  //region block: exports
2067
2038
  export {