@adviser/cement 0.3.3 → 0.3.5

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 (546) hide show
  1. package/{base-sys-abstraction-CR_Z-Ceg.d.ts → base-sys-abstraction-CKI4xiRR.d.ts} +4 -4
  2. package/{base-sys-abstraction-DWtPI7Kg.d.cts → base-sys-abstraction-DLnSeH4s.d.cts} +4 -4
  3. package/cf/index.cjs +298 -284
  4. package/cf/index.cjs.map +1 -1
  5. package/cf/index.d.cts +4 -18
  6. package/cf/index.d.ts +4 -18
  7. package/cf/index.js +39 -6
  8. package/cf/index.js.map +1 -1
  9. package/{chunk-P6LDM7PY.js → chunk-4QRZPFED.js} +112 -506
  10. package/chunk-4QRZPFED.js.map +1 -0
  11. package/{chunk-HFP74WLI.js → chunk-4U6TAOIU.js} +5 -4
  12. package/chunk-4U6TAOIU.js.map +1 -0
  13. package/{chunk-PRCFKZR7.js → chunk-6AG3MRNY.js} +22 -170
  14. package/chunk-6AG3MRNY.js.map +1 -0
  15. package/{chunk-A7OPSHUV.js → chunk-LRJXXDF5.js} +11 -4
  16. package/chunk-LRJXXDF5.js.map +1 -0
  17. package/chunk-OIIUVSUX.js +88 -0
  18. package/chunk-OIIUVSUX.js.map +1 -0
  19. package/chunk-QDDO6NOK.js +194 -0
  20. package/chunk-QDDO6NOK.js.map +1 -0
  21. package/deno/index.cjs +274 -166
  22. package/deno/index.cjs.map +1 -1
  23. package/deno/index.d.cts +4 -24
  24. package/deno/index.d.ts +4 -24
  25. package/deno/index.js +174 -8
  26. package/deno/index.js.map +1 -1
  27. package/get-params-result-Bhy5997x.d.cts +61 -0
  28. package/get-params-result-Bhy5997x.d.ts +61 -0
  29. package/{index-CfSl8Gmj.d.ts → index-1R-hTV11.d.ts} +5 -50
  30. package/{index-BfZxTAe_.d.cts → index-98HXQB3i.d.cts} +5 -50
  31. package/{index-Q3phXzYr.d.cts → index-BMCdndbY.d.cts} +28 -23
  32. package/{index-tIGZMHTc.d.ts → index-IrV5jK1W.d.ts} +28 -23
  33. package/index.cjs +327 -430
  34. package/index.cjs.map +1 -1
  35. package/index.d.cts +13 -11
  36. package/index.d.ts +13 -11
  37. package/index.js +18 -12
  38. package/index.js.map +1 -1
  39. package/node/index.cjs +247 -139
  40. package/node/index.cjs.map +1 -1
  41. package/node/index.d.cts +4 -17
  42. package/node/index.d.ts +4 -17
  43. package/node/index.js +183 -12
  44. package/node/index.js.map +1 -1
  45. package/package.json +1 -1
  46. package/src/base-sys-abstraction.ts +8 -6
  47. package/src/cf/cf-env-actions.ts +53 -0
  48. package/src/cf/cf-sys-abstraction.ts +1 -53
  49. package/src/cf-test-main.ts +5 -0
  50. package/src/deno/deno-env-actions.ts +57 -0
  51. package/src/deno/deno-file-service.ts +1 -1
  52. package/src/deno/deno-sys-abstraction.ts +1 -57
  53. package/src/http_header.ts +1 -1
  54. package/src/index.ts +3 -0
  55. package/src/jsr.json +1 -1
  56. package/src/log-writer-impl.ts +10 -5
  57. package/src/logger-impl.ts +9 -8
  58. package/src/logger.ts +4 -5
  59. package/src/node/mock-file-service.ts +4 -4
  60. package/src/node/node-env-actions.ts +45 -0
  61. package/src/node/node-sys-abstraction.ts +1 -45
  62. package/src/resolve-once.ts +6 -5
  63. package/src/runtime.ts +3 -3
  64. package/src/sys-env.ts +64 -4
  65. package/src/test/log-write-stream.ts +2 -1
  66. package/src/tracer.ts +4 -6
  67. package/src/uri.ts +4 -69
  68. package/src/utils/console-write-stream.ts +4 -3
  69. package/src/utils/fanout-write-stream.ts +1 -1
  70. package/src/utils/get-params-result.ts +71 -0
  71. package/src/utils/index.ts +1 -0
  72. package/src/utils/rebuffer.ts +27 -21
  73. package/src/utils/relative-path.ts +1 -1
  74. package/src/utils/stream2string.ts +2 -2
  75. package/src/utils/stripper.ts +2 -2
  76. package/src/version.ts +2 -2
  77. package/src/web/web-env-actions.ts +41 -0
  78. package/src/web/web-sys-abstraction.ts +2 -42
  79. package/{sys-abstraction-GNnBj2sz.d.cts → sys-abstraction-BRDT_TIU.d.cts} +8 -1
  80. package/{sys-abstraction-GNnBj2sz.d.ts → sys-abstraction-Bd0EzwO6.d.ts} +8 -1
  81. package/test/index.cjs +460 -578
  82. package/test/index.cjs.map +1 -1
  83. package/test/index.d.cts +3 -3
  84. package/test/index.d.ts +3 -3
  85. package/test/index.js +5 -4
  86. package/ts/smoke/smoke.d.ts +2 -0
  87. package/ts/smoke/smoke.d.ts.map +1 -0
  88. package/ts/smoke/smoke.js +33 -0
  89. package/ts/smoke/smoke.js.map +1 -0
  90. package/ts/{base-sys-abstraction.d.ts → src/base-sys-abstraction.d.ts} +2 -2
  91. package/ts/src/base-sys-abstraction.d.ts.map +1 -0
  92. package/ts/{base-sys-abstraction.js → src/base-sys-abstraction.js} +4 -2
  93. package/ts/src/base-sys-abstraction.js.map +1 -0
  94. package/ts/src/base-sys-abstraction.test.d.ts.map +1 -0
  95. package/ts/src/base-sys-abstraction.test.js.map +1 -0
  96. package/ts/src/bin2text.d.ts.map +1 -0
  97. package/ts/src/bin2text.js.map +1 -0
  98. package/ts/{bin2text.test.d.ts.map → src/bin2text.test.d.ts.map} +1 -1
  99. package/ts/src/bin2text.test.js.map +1 -0
  100. package/ts/src/cf/cf-env-actions.d.ts +16 -0
  101. package/ts/src/cf/cf-env-actions.d.ts.map +1 -0
  102. package/ts/{cf/cf-sys-abstraction.js → src/cf/cf-env-actions.js} +1 -30
  103. package/ts/src/cf/cf-env-actions.js.map +1 -0
  104. package/ts/src/cf/cf-sys-abstraction.d.ts +11 -0
  105. package/ts/src/cf/cf-sys-abstraction.d.ts.map +1 -0
  106. package/ts/src/cf/cf-sys-abstraction.js +30 -0
  107. package/ts/src/cf/cf-sys-abstraction.js.map +1 -0
  108. package/ts/src/cf/index.d.ts.map +1 -0
  109. package/ts/src/cf/index.js.map +1 -0
  110. package/ts/src/cf-test-main.d.ts +5 -0
  111. package/ts/src/cf-test-main.d.ts.map +1 -0
  112. package/ts/src/cf-test-main.js +6 -0
  113. package/ts/src/cf-test-main.js.map +1 -0
  114. package/ts/src/crypto.d.ts.map +1 -0
  115. package/ts/src/crypto.js.map +1 -0
  116. package/ts/{crypto.test.d.ts.map → src/crypto.test.d.ts.map} +1 -1
  117. package/ts/{crypto.test.js → src/crypto.test.js} +8 -1
  118. package/ts/src/crypto.test.js.map +1 -0
  119. package/ts/src/deno/deno-env-actions.d.ts +23 -0
  120. package/ts/src/deno/deno-env-actions.d.ts.map +1 -0
  121. package/ts/src/deno/deno-env-actions.js +46 -0
  122. package/ts/src/deno/deno-env-actions.js.map +1 -0
  123. package/ts/src/deno/deno-file-service.d.ts.map +1 -0
  124. package/ts/src/deno/deno-file-service.js.map +1 -0
  125. package/ts/{deno → src/deno}/deno-sys-abstraction.d.ts +1 -22
  126. package/ts/src/deno/deno-sys-abstraction.d.ts.map +1 -0
  127. package/ts/{deno → src/deno}/deno-sys-abstraction.js +0 -45
  128. package/ts/src/deno/deno-sys-abstraction.js.map +1 -0
  129. package/ts/src/deno/index.d.ts.map +1 -0
  130. package/ts/src/deno/index.js.map +1 -0
  131. package/ts/src/file-service.d.ts.map +1 -0
  132. package/ts/{file-service.js.map → src/file-service.js.map} +1 -1
  133. package/ts/src/future.d.ts.map +1 -0
  134. package/ts/src/future.js.map +1 -0
  135. package/ts/{future.test.d.ts.map → src/future.test.d.ts.map} +1 -1
  136. package/ts/src/future.test.js.map +1 -0
  137. package/ts/src/http_header.d.ts.map +1 -0
  138. package/ts/src/http_header.js.map +1 -0
  139. package/ts/src/http_header.test.d.ts.map +1 -0
  140. package/ts/src/http_header.test.js.map +1 -0
  141. package/ts/{index.d.ts → src/index.d.ts} +2 -0
  142. package/ts/src/index.d.ts.map +1 -0
  143. package/ts/{index.js → src/index.js} +2 -0
  144. package/ts/src/index.js.map +1 -0
  145. package/ts/src/log-level-impl.d.ts.map +1 -0
  146. package/ts/src/log-level-impl.js.map +1 -0
  147. package/ts/src/log-writer-impl.d.ts.map +1 -0
  148. package/ts/{log-writer-impl.js → src/log-writer-impl.js} +4 -2
  149. package/ts/src/log-writer-impl.js.map +1 -0
  150. package/ts/{logger-impl.d.ts → src/logger-impl.d.ts} +1 -1
  151. package/ts/src/logger-impl.d.ts.map +1 -0
  152. package/ts/{logger-impl.js → src/logger-impl.js} +2 -3
  153. package/ts/src/logger-impl.js.map +1 -0
  154. package/ts/{logger.d.ts → src/logger.d.ts} +1 -1
  155. package/ts/src/logger.d.ts.map +1 -0
  156. package/ts/src/logger.js.map +1 -0
  157. package/ts/{logger.test.d.ts.map → src/logger.test.d.ts.map} +1 -1
  158. package/ts/{logger.test.js → src/logger.test.js} +4 -4
  159. package/ts/src/logger.test.js.map +1 -0
  160. package/ts/src/node/index.d.ts.map +1 -0
  161. package/ts/src/node/index.js.map +1 -0
  162. package/ts/src/node/mock-file-service.d.ts.map +1 -0
  163. package/ts/{node → src/node}/mock-file-service.js +4 -4
  164. package/ts/src/node/mock-file-service.js.map +1 -0
  165. package/ts/src/node/mock-file-service.test.d.ts.map +1 -0
  166. package/ts/src/node/mock-file-service.test.js.map +1 -0
  167. package/ts/src/node/node-env-actions.d.ts +15 -0
  168. package/ts/src/node/node-env-actions.d.ts.map +1 -0
  169. package/ts/src/node/node-env-actions.js +44 -0
  170. package/ts/src/node/node-env-actions.js.map +1 -0
  171. package/ts/src/node/node-file-service.d.ts.map +1 -0
  172. package/ts/src/node/node-file-service.js.map +1 -0
  173. package/ts/{node → src/node}/node-sys-abstraction.d.ts +1 -14
  174. package/ts/src/node/node-sys-abstraction.d.ts.map +1 -0
  175. package/ts/{node → src/node}/node-sys-abstraction.js +0 -43
  176. package/ts/src/node/node-sys-abstraction.js.map +1 -0
  177. package/ts/src/node/node-sys-abstraction.test.d.ts.map +1 -0
  178. package/ts/src/node/node-sys-abstraction.test.js.map +1 -0
  179. package/ts/src/option.d.ts.map +1 -0
  180. package/ts/src/option.js.map +1 -0
  181. package/ts/{resolve-once.d.ts → src/resolve-once.d.ts} +1 -1
  182. package/ts/src/resolve-once.d.ts.map +1 -0
  183. package/ts/{resolve-once.js → src/resolve-once.js} +5 -4
  184. package/ts/src/resolve-once.js.map +1 -0
  185. package/ts/src/resolve-once.test.d.ts.map +1 -0
  186. package/ts/{resolve-once.test.js → src/resolve-once.test.js} +20 -24
  187. package/ts/src/resolve-once.test.js.map +1 -0
  188. package/ts/src/result.d.ts.map +1 -0
  189. package/ts/src/result.js.map +1 -0
  190. package/ts/{result.test.d.ts.map → src/result.test.d.ts.map} +1 -1
  191. package/ts/{result.test.js → src/result.test.js} +2 -4
  192. package/ts/src/result.test.js.map +1 -0
  193. package/ts/src/runtime.d.ts.map +1 -0
  194. package/ts/src/runtime.js.map +1 -0
  195. package/ts/src/sys-abstraction.d.ts.map +1 -0
  196. package/ts/src/sys-abstraction.js.map +1 -0
  197. package/ts/{sys-env.d.ts → src/sys-env.d.ts} +7 -0
  198. package/ts/src/sys-env.d.ts.map +1 -0
  199. package/ts/{sys-env.js → src/sys-env.js} +57 -4
  200. package/ts/src/sys-env.js.map +1 -0
  201. package/ts/{sys-env.test.d.ts.map → src/sys-env.test.d.ts.map} +1 -1
  202. package/ts/{sys-env.test.js → src/sys-env.test.js} +70 -2
  203. package/ts/src/sys-env.test.js.map +1 -0
  204. package/ts/src/test/index.d.ts.map +1 -0
  205. package/ts/src/test/index.js.map +1 -0
  206. package/ts/src/test/log-write-stream.d.ts.map +1 -0
  207. package/ts/src/test/log-write-stream.js.map +1 -0
  208. package/ts/src/test/mock-logger.d.ts.map +1 -0
  209. package/ts/src/test/mock-logger.js.map +1 -0
  210. package/ts/src/test/mock-logger.test.d.ts.map +1 -0
  211. package/ts/src/test/mock-logger.test.js.map +1 -0
  212. package/ts/src/test/test-exit-handler.d.ts.map +1 -0
  213. package/ts/{test → src/test}/test-exit-handler.js +8 -3
  214. package/ts/src/test/test-exit-handler.js.map +1 -0
  215. package/ts/src/time.d.ts.map +1 -0
  216. package/ts/src/time.js.map +1 -0
  217. package/ts/src/tracer.d.ts.map +1 -0
  218. package/ts/src/tracer.js.map +1 -0
  219. package/ts/{tracer.test.d.ts.map → src/tracer.test.d.ts.map} +1 -1
  220. package/ts/{tracer.test.js → src/tracer.test.js} +5 -5
  221. package/ts/src/tracer.test.js.map +1 -0
  222. package/ts/src/txt-en-decoder.d.ts.map +1 -0
  223. package/ts/src/txt-en-decoder.js.map +1 -0
  224. package/ts/{uri.d.ts → src/uri.d.ts} +2 -13
  225. package/ts/src/uri.d.ts.map +1 -0
  226. package/ts/{uri.js → src/uri.js} +2 -56
  227. package/ts/src/uri.js.map +1 -0
  228. package/ts/{uri.test.d.ts.map → src/uri.test.d.ts.map} +1 -1
  229. package/ts/{uri.test.js → src/uri.test.js} +7 -7
  230. package/ts/src/uri.test.js.map +1 -0
  231. package/ts/{utils → src/utils}/console-write-stream.d.ts +1 -1
  232. package/ts/src/utils/console-write-stream.d.ts.map +1 -0
  233. package/ts/{utils → src/utils}/console-write-stream.js +4 -3
  234. package/ts/src/utils/console-write-stream.js.map +1 -0
  235. package/ts/{utils → src/utils}/fanout-write-stream.d.ts +1 -1
  236. package/ts/src/utils/fanout-write-stream.d.ts.map +1 -0
  237. package/ts/src/utils/fanout-write-stream.js.map +1 -0
  238. package/ts/src/utils/get-params-result.d.ts +19 -0
  239. package/ts/src/utils/get-params-result.d.ts.map +1 -0
  240. package/ts/src/utils/get-params-result.js +58 -0
  241. package/ts/src/utils/get-params-result.js.map +1 -0
  242. package/ts/{utils → src/utils}/index.d.ts +1 -0
  243. package/ts/src/utils/index.d.ts.map +1 -0
  244. package/ts/{utils → src/utils}/index.js +1 -0
  245. package/ts/src/utils/index.js.map +1 -0
  246. package/ts/src/utils/rebuffer.d.ts.map +1 -0
  247. package/ts/{utils → src/utils}/rebuffer.js +7 -1
  248. package/ts/src/utils/rebuffer.js.map +1 -0
  249. package/ts/src/utils/rebuffer.test.d.ts.map +1 -0
  250. package/ts/src/utils/rebuffer.test.js.map +1 -0
  251. package/ts/src/utils/relative-path.d.ts.map +1 -0
  252. package/ts/src/utils/relative-path.js.map +1 -0
  253. package/ts/src/utils/relative-path.test.d.ts.map +1 -0
  254. package/ts/src/utils/relative-path.test.js.map +1 -0
  255. package/ts/src/utils/stream-map.d.ts.map +1 -0
  256. package/ts/src/utils/stream-map.js.map +1 -0
  257. package/ts/src/utils/stream-map.test.d.ts.map +1 -0
  258. package/ts/src/utils/stream-map.test.js.map +1 -0
  259. package/ts/src/utils/stream-test-helper.d.ts.map +1 -0
  260. package/ts/{utils → src/utils}/stream-test-helper.js +18 -10
  261. package/ts/src/utils/stream-test-helper.js.map +1 -0
  262. package/ts/src/utils/stream2string.d.ts.map +1 -0
  263. package/ts/src/utils/stream2string.js.map +1 -0
  264. package/ts/src/utils/stream2string.test.d.ts.map +1 -0
  265. package/ts/src/utils/stream2string.test.js.map +1 -0
  266. package/ts/src/utils/string2stream.d.ts.map +1 -0
  267. package/ts/src/utils/string2stream.js.map +1 -0
  268. package/ts/src/utils/string2stream.test.d.ts.map +1 -0
  269. package/ts/src/utils/string2stream.test.js.map +1 -0
  270. package/ts/src/utils/stripper.d.ts +3 -0
  271. package/ts/src/utils/stripper.d.ts.map +1 -0
  272. package/ts/src/utils/stripper.js.map +1 -0
  273. package/ts/src/utils/stripper.test.d.ts.map +1 -0
  274. package/ts/src/utils/stripper.test.js.map +1 -0
  275. package/ts/src/version.d.ts.map +1 -0
  276. package/ts/src/version.js.map +1 -0
  277. package/ts/src/web/index.d.ts.map +1 -0
  278. package/ts/src/web/index.js.map +1 -0
  279. package/ts/src/web/web-env-actions.d.ts +14 -0
  280. package/ts/src/web/web-env-actions.d.ts.map +1 -0
  281. package/ts/src/web/web-env-actions.js +35 -0
  282. package/ts/src/web/web-env-actions.js.map +1 -0
  283. package/ts/{web → src/web}/web-sys-abstraction.d.ts +1 -14
  284. package/ts/src/web/web-sys-abstraction.d.ts.map +1 -0
  285. package/ts/{web → src/web}/web-sys-abstraction.js +0 -34
  286. package/ts/src/web/web-sys-abstraction.js.map +1 -0
  287. package/ts/vitest.browser.config.d.ts +3 -0
  288. package/ts/vitest.browser.config.d.ts.map +1 -0
  289. package/ts/vitest.browser.config.js +17 -0
  290. package/ts/vitest.browser.config.js.map +1 -0
  291. package/ts/vitest.cf-runtime.config.d.ts +3 -0
  292. package/ts/vitest.cf-runtime.config.d.ts.map +1 -0
  293. package/ts/vitest.cf-runtime.config.js +16 -0
  294. package/ts/vitest.cf-runtime.config.js.map +1 -0
  295. package/ts/vitest.config.d.ts +3 -0
  296. package/ts/vitest.config.d.ts.map +1 -0
  297. package/ts/vitest.config.js +8 -0
  298. package/ts/vitest.config.js.map +1 -0
  299. package/ts/vitest.node.config.d.ts +3 -0
  300. package/ts/vitest.node.config.d.ts.map +1 -0
  301. package/ts/vitest.node.config.js +11 -0
  302. package/ts/vitest.node.config.js.map +1 -0
  303. package/ts/vitest.workspace.d.ts +3 -0
  304. package/ts/vitest.workspace.d.ts.map +1 -0
  305. package/ts/vitest.workspace.js +6 -0
  306. package/ts/vitest.workspace.js.map +1 -0
  307. package/utils/index.cjs +150 -3
  308. package/utils/index.cjs.map +1 -1
  309. package/utils/index.d.cts +2 -2
  310. package/utils/index.d.ts +2 -2
  311. package/utils/index.js +8 -3
  312. package/web/index.cjs +251 -239
  313. package/web/index.cjs.map +1 -1
  314. package/web/index.d.cts +5 -17
  315. package/web/index.d.ts +5 -17
  316. package/web/index.js +3 -4
  317. package/chunk-A7OPSHUV.js.map +0 -1
  318. package/chunk-HFP74WLI.js.map +0 -1
  319. package/chunk-P6LDM7PY.js.map +0 -1
  320. package/chunk-PPS4L4VW.js +0 -38
  321. package/chunk-PPS4L4VW.js.map +0 -1
  322. package/chunk-PRCFKZR7.js.map +0 -1
  323. package/ts/base-sys-abstraction.d.ts.map +0 -1
  324. package/ts/base-sys-abstraction.js.map +0 -1
  325. package/ts/base-sys-abstraction.test.d.ts.map +0 -1
  326. package/ts/base-sys-abstraction.test.js.map +0 -1
  327. package/ts/bin2text.d.ts.map +0 -1
  328. package/ts/bin2text.js.map +0 -1
  329. package/ts/bin2text.test.js.map +0 -1
  330. package/ts/cf/cf-sys-abstraction.d.ts +0 -25
  331. package/ts/cf/cf-sys-abstraction.d.ts.map +0 -1
  332. package/ts/cf/cf-sys-abstraction.js.map +0 -1
  333. package/ts/cf/index.d.ts.map +0 -1
  334. package/ts/cf/index.js.map +0 -1
  335. package/ts/crypto.d.ts.map +0 -1
  336. package/ts/crypto.js.map +0 -1
  337. package/ts/crypto.test.js.map +0 -1
  338. package/ts/deno/deno-file-service.d.ts.map +0 -1
  339. package/ts/deno/deno-file-service.js.map +0 -1
  340. package/ts/deno/deno-sys-abstraction.d.ts.map +0 -1
  341. package/ts/deno/deno-sys-abstraction.js.map +0 -1
  342. package/ts/deno/index.d.ts.map +0 -1
  343. package/ts/deno/index.js.map +0 -1
  344. package/ts/file-service.d.ts.map +0 -1
  345. package/ts/future.d.ts.map +0 -1
  346. package/ts/future.js.map +0 -1
  347. package/ts/future.test.js.map +0 -1
  348. package/ts/http_header.d.ts.map +0 -1
  349. package/ts/http_header.js.map +0 -1
  350. package/ts/http_header.test.d.ts.map +0 -1
  351. package/ts/http_header.test.js.map +0 -1
  352. package/ts/index.d.ts.map +0 -1
  353. package/ts/index.js.map +0 -1
  354. package/ts/log-level-impl.d.ts.map +0 -1
  355. package/ts/log-level-impl.js.map +0 -1
  356. package/ts/log-writer-impl.d.ts.map +0 -1
  357. package/ts/log-writer-impl.js.map +0 -1
  358. package/ts/logger-impl.d.ts.map +0 -1
  359. package/ts/logger-impl.js.map +0 -1
  360. package/ts/logger.d.ts.map +0 -1
  361. package/ts/logger.js.map +0 -1
  362. package/ts/logger.test.js.map +0 -1
  363. package/ts/node/index.d.ts.map +0 -1
  364. package/ts/node/index.js.map +0 -1
  365. package/ts/node/mock-file-service.d.ts.map +0 -1
  366. package/ts/node/mock-file-service.js.map +0 -1
  367. package/ts/node/mock-file-service.test.d.ts.map +0 -1
  368. package/ts/node/mock-file-service.test.js.map +0 -1
  369. package/ts/node/node-file-service.d.ts.map +0 -1
  370. package/ts/node/node-file-service.js.map +0 -1
  371. package/ts/node/node-sys-abstraction.d.ts.map +0 -1
  372. package/ts/node/node-sys-abstraction.js.map +0 -1
  373. package/ts/node/node-sys-abstraction.test.d.ts.map +0 -1
  374. package/ts/node/node-sys-abstraction.test.js.map +0 -1
  375. package/ts/option.d.ts.map +0 -1
  376. package/ts/option.js.map +0 -1
  377. package/ts/resolve-once.d.ts.map +0 -1
  378. package/ts/resolve-once.js.map +0 -1
  379. package/ts/resolve-once.test.d.ts.map +0 -1
  380. package/ts/resolve-once.test.js.map +0 -1
  381. package/ts/result.d.ts.map +0 -1
  382. package/ts/result.js.map +0 -1
  383. package/ts/result.test.js.map +0 -1
  384. package/ts/runtime.d.ts.map +0 -1
  385. package/ts/runtime.js.map +0 -1
  386. package/ts/sys-abstraction.d.ts.map +0 -1
  387. package/ts/sys-abstraction.js.map +0 -1
  388. package/ts/sys-env.d.ts.map +0 -1
  389. package/ts/sys-env.js.map +0 -1
  390. package/ts/sys-env.test.js.map +0 -1
  391. package/ts/test/index.d.ts.map +0 -1
  392. package/ts/test/index.js.map +0 -1
  393. package/ts/test/log-write-stream.d.ts.map +0 -1
  394. package/ts/test/log-write-stream.js.map +0 -1
  395. package/ts/test/mock-logger.d.ts.map +0 -1
  396. package/ts/test/mock-logger.js.map +0 -1
  397. package/ts/test/mock-logger.test.d.ts.map +0 -1
  398. package/ts/test/mock-logger.test.js.map +0 -1
  399. package/ts/test/test-exit-handler.d.ts.map +0 -1
  400. package/ts/test/test-exit-handler.js.map +0 -1
  401. package/ts/time.d.ts.map +0 -1
  402. package/ts/time.js.map +0 -1
  403. package/ts/tracer.d.ts.map +0 -1
  404. package/ts/tracer.js.map +0 -1
  405. package/ts/tracer.test.js.map +0 -1
  406. package/ts/txt-en-decoder.d.ts.map +0 -1
  407. package/ts/txt-en-decoder.js.map +0 -1
  408. package/ts/uri.d.ts.map +0 -1
  409. package/ts/uri.js.map +0 -1
  410. package/ts/uri.test.js.map +0 -1
  411. package/ts/utils/console-write-stream.d.ts.map +0 -1
  412. package/ts/utils/console-write-stream.js.map +0 -1
  413. package/ts/utils/fanout-write-stream.d.ts.map +0 -1
  414. package/ts/utils/fanout-write-stream.js.map +0 -1
  415. package/ts/utils/index.d.ts.map +0 -1
  416. package/ts/utils/index.js.map +0 -1
  417. package/ts/utils/rebuffer.d.ts.map +0 -1
  418. package/ts/utils/rebuffer.js.map +0 -1
  419. package/ts/utils/rebuffer.test.d.ts.map +0 -1
  420. package/ts/utils/rebuffer.test.js.map +0 -1
  421. package/ts/utils/relative-path.d.ts.map +0 -1
  422. package/ts/utils/relative-path.js.map +0 -1
  423. package/ts/utils/relative-path.test.d.ts.map +0 -1
  424. package/ts/utils/relative-path.test.js.map +0 -1
  425. package/ts/utils/stream-map.d.ts.map +0 -1
  426. package/ts/utils/stream-map.js.map +0 -1
  427. package/ts/utils/stream-map.test.d.ts.map +0 -1
  428. package/ts/utils/stream-map.test.js.map +0 -1
  429. package/ts/utils/stream-test-helper.d.ts.map +0 -1
  430. package/ts/utils/stream-test-helper.js.map +0 -1
  431. package/ts/utils/stream2string.d.ts.map +0 -1
  432. package/ts/utils/stream2string.js.map +0 -1
  433. package/ts/utils/stream2string.test.d.ts.map +0 -1
  434. package/ts/utils/stream2string.test.js.map +0 -1
  435. package/ts/utils/string2stream.d.ts.map +0 -1
  436. package/ts/utils/string2stream.js.map +0 -1
  437. package/ts/utils/string2stream.test.d.ts.map +0 -1
  438. package/ts/utils/string2stream.test.js.map +0 -1
  439. package/ts/utils/stripper.d.ts +0 -3
  440. package/ts/utils/stripper.d.ts.map +0 -1
  441. package/ts/utils/stripper.js.map +0 -1
  442. package/ts/utils/stripper.test.d.ts.map +0 -1
  443. package/ts/utils/stripper.test.js.map +0 -1
  444. package/ts/version.d.ts.map +0 -1
  445. package/ts/version.js.map +0 -1
  446. package/ts/web/index.d.ts.map +0 -1
  447. package/ts/web/index.js.map +0 -1
  448. package/ts/web/web-sys-abstraction.d.ts.map +0 -1
  449. package/ts/web/web-sys-abstraction.js.map +0 -1
  450. package/txt-en-decoder-CZYJUju2.d.cts +0 -11
  451. package/txt-en-decoder-CZYJUju2.d.ts +0 -11
  452. /package/ts/{base-sys-abstraction.test.d.ts → src/base-sys-abstraction.test.d.ts} +0 -0
  453. /package/ts/{base-sys-abstraction.test.js → src/base-sys-abstraction.test.js} +0 -0
  454. /package/ts/{bin2text.d.ts → src/bin2text.d.ts} +0 -0
  455. /package/ts/{bin2text.js → src/bin2text.js} +0 -0
  456. /package/ts/{bin2text.test.d.ts → src/bin2text.test.d.ts} +0 -0
  457. /package/ts/{bin2text.test.js → src/bin2text.test.js} +0 -0
  458. /package/ts/{cf → src/cf}/index.d.ts +0 -0
  459. /package/ts/{cf → src/cf}/index.js +0 -0
  460. /package/ts/{crypto.d.ts → src/crypto.d.ts} +0 -0
  461. /package/ts/{crypto.js → src/crypto.js} +0 -0
  462. /package/ts/{crypto.test.d.ts → src/crypto.test.d.ts} +0 -0
  463. /package/ts/{deno → src/deno}/deno-file-service.d.ts +0 -0
  464. /package/ts/{deno → src/deno}/deno-file-service.js +0 -0
  465. /package/ts/{deno → src/deno}/index.d.ts +0 -0
  466. /package/ts/{deno → src/deno}/index.js +0 -0
  467. /package/ts/{file-service.d.ts → src/file-service.d.ts} +0 -0
  468. /package/ts/{file-service.js → src/file-service.js} +0 -0
  469. /package/ts/{future.d.ts → src/future.d.ts} +0 -0
  470. /package/ts/{future.js → src/future.js} +0 -0
  471. /package/ts/{future.test.d.ts → src/future.test.d.ts} +0 -0
  472. /package/ts/{future.test.js → src/future.test.js} +0 -0
  473. /package/ts/{http_header.d.ts → src/http_header.d.ts} +0 -0
  474. /package/ts/{http_header.js → src/http_header.js} +0 -0
  475. /package/ts/{http_header.test.d.ts → src/http_header.test.d.ts} +0 -0
  476. /package/ts/{http_header.test.js → src/http_header.test.js} +0 -0
  477. /package/ts/{log-level-impl.d.ts → src/log-level-impl.d.ts} +0 -0
  478. /package/ts/{log-level-impl.js → src/log-level-impl.js} +0 -0
  479. /package/ts/{log-writer-impl.d.ts → src/log-writer-impl.d.ts} +0 -0
  480. /package/ts/{logger.js → src/logger.js} +0 -0
  481. /package/ts/{logger.test.d.ts → src/logger.test.d.ts} +0 -0
  482. /package/ts/{node → src/node}/index.d.ts +0 -0
  483. /package/ts/{node → src/node}/index.js +0 -0
  484. /package/ts/{node → src/node}/mock-file-service.d.ts +0 -0
  485. /package/ts/{node → src/node}/mock-file-service.test.d.ts +0 -0
  486. /package/ts/{node → src/node}/mock-file-service.test.js +0 -0
  487. /package/ts/{node → src/node}/node-file-service.d.ts +0 -0
  488. /package/ts/{node → src/node}/node-file-service.js +0 -0
  489. /package/ts/{node → src/node}/node-sys-abstraction.test.d.ts +0 -0
  490. /package/ts/{node → src/node}/node-sys-abstraction.test.js +0 -0
  491. /package/ts/{option.d.ts → src/option.d.ts} +0 -0
  492. /package/ts/{option.js → src/option.js} +0 -0
  493. /package/ts/{resolve-once.test.d.ts → src/resolve-once.test.d.ts} +0 -0
  494. /package/ts/{result.d.ts → src/result.d.ts} +0 -0
  495. /package/ts/{result.js → src/result.js} +0 -0
  496. /package/ts/{result.test.d.ts → src/result.test.d.ts} +0 -0
  497. /package/ts/{runtime.d.ts → src/runtime.d.ts} +0 -0
  498. /package/ts/{runtime.js → src/runtime.js} +0 -0
  499. /package/ts/{sys-abstraction.d.ts → src/sys-abstraction.d.ts} +0 -0
  500. /package/ts/{sys-abstraction.js → src/sys-abstraction.js} +0 -0
  501. /package/ts/{sys-env.test.d.ts → src/sys-env.test.d.ts} +0 -0
  502. /package/ts/{test → src/test}/index.d.ts +0 -0
  503. /package/ts/{test → src/test}/index.js +0 -0
  504. /package/ts/{test → src/test}/log-write-stream.d.ts +0 -0
  505. /package/ts/{test → src/test}/log-write-stream.js +0 -0
  506. /package/ts/{test → src/test}/mock-logger.d.ts +0 -0
  507. /package/ts/{test → src/test}/mock-logger.js +0 -0
  508. /package/ts/{test → src/test}/mock-logger.test.d.ts +0 -0
  509. /package/ts/{test → src/test}/mock-logger.test.js +0 -0
  510. /package/ts/{test → src/test}/test-exit-handler.d.ts +0 -0
  511. /package/ts/{time.d.ts → src/time.d.ts} +0 -0
  512. /package/ts/{time.js → src/time.js} +0 -0
  513. /package/ts/{tracer.d.ts → src/tracer.d.ts} +0 -0
  514. /package/ts/{tracer.js → src/tracer.js} +0 -0
  515. /package/ts/{tracer.test.d.ts → src/tracer.test.d.ts} +0 -0
  516. /package/ts/{txt-en-decoder.d.ts → src/txt-en-decoder.d.ts} +0 -0
  517. /package/ts/{txt-en-decoder.js → src/txt-en-decoder.js} +0 -0
  518. /package/ts/{uri.test.d.ts → src/uri.test.d.ts} +0 -0
  519. /package/ts/{utils → src/utils}/fanout-write-stream.js +0 -0
  520. /package/ts/{utils → src/utils}/rebuffer.d.ts +0 -0
  521. /package/ts/{utils → src/utils}/rebuffer.test.d.ts +0 -0
  522. /package/ts/{utils → src/utils}/rebuffer.test.js +0 -0
  523. /package/ts/{utils → src/utils}/relative-path.d.ts +0 -0
  524. /package/ts/{utils → src/utils}/relative-path.js +0 -0
  525. /package/ts/{utils → src/utils}/relative-path.test.d.ts +0 -0
  526. /package/ts/{utils → src/utils}/relative-path.test.js +0 -0
  527. /package/ts/{utils → src/utils}/stream-map.d.ts +0 -0
  528. /package/ts/{utils → src/utils}/stream-map.js +0 -0
  529. /package/ts/{utils → src/utils}/stream-map.test.d.ts +0 -0
  530. /package/ts/{utils → src/utils}/stream-map.test.js +0 -0
  531. /package/ts/{utils → src/utils}/stream-test-helper.d.ts +0 -0
  532. /package/ts/{utils → src/utils}/stream2string.d.ts +0 -0
  533. /package/ts/{utils → src/utils}/stream2string.js +0 -0
  534. /package/ts/{utils → src/utils}/stream2string.test.d.ts +0 -0
  535. /package/ts/{utils → src/utils}/stream2string.test.js +0 -0
  536. /package/ts/{utils → src/utils}/string2stream.d.ts +0 -0
  537. /package/ts/{utils → src/utils}/string2stream.js +0 -0
  538. /package/ts/{utils → src/utils}/string2stream.test.d.ts +0 -0
  539. /package/ts/{utils → src/utils}/string2stream.test.js +0 -0
  540. /package/ts/{utils → src/utils}/stripper.js +0 -0
  541. /package/ts/{utils → src/utils}/stripper.test.d.ts +0 -0
  542. /package/ts/{utils → src/utils}/stripper.test.js +0 -0
  543. /package/ts/{version.d.ts → src/version.d.ts} +0 -0
  544. /package/ts/{version.js → src/version.js} +0 -0
  545. /package/ts/{web → src/web}/index.d.ts +0 -0
  546. /package/ts/{web → src/web}/index.js +0 -0
package/test/index.cjs CHANGED
@@ -14,9 +14,9 @@ var __export = (target, all) => {
14
14
  };
15
15
  var __copyProps = (to, from2, except, desc) => {
16
16
  if (from2 && typeof from2 === "object" || typeof from2 === "function") {
17
- for (let key2 of __getOwnPropNames(from2))
18
- if (!__hasOwnProp.call(to, key2) && key2 !== except)
19
- __defProp(to, key2, { get: () => from2[key2], enumerable: !(desc = __getOwnPropDesc(from2, key2)) || desc.enumerable });
17
+ for (let key of __getOwnPropNames(from2))
18
+ if (!__hasOwnProp.call(to, key) && key !== except)
19
+ __defProp(to, key, { get: () => from2[key], enumerable: !(desc = __getOwnPropDesc(from2, key)) || desc.enumerable });
20
20
  }
21
21
  return to;
22
22
  };
@@ -80,8 +80,8 @@ var Future = class {
80
80
  __privateAdd(this, _rejectFn, () => {
81
81
  throw new Error("This Promise is not working as expected.");
82
82
  });
83
- __privateSet(this, _promise, new Promise((resolve2, reject) => {
84
- __privateSet(this, _resolveFn, resolve2);
83
+ __privateSet(this, _promise, new Promise((resolve, reject) => {
84
+ __privateSet(this, _resolveFn, resolve);
85
85
  __privateSet(this, _rejectFn, reject);
86
86
  }));
87
87
  }
@@ -256,9 +256,6 @@ var LogValue = class {
256
256
  return this.value();
257
257
  }
258
258
  };
259
- function asyncLogValue(val) {
260
- throw new Error("Not implemented");
261
- }
262
259
  function logValue(val, ctx) {
263
260
  return logValueInternal(val, {
264
261
  ...ctx,
@@ -334,16 +331,16 @@ function logValueInternal(val, ctx) {
334
331
  }
335
332
  const res = {};
336
333
  const typedVal = val;
337
- for (const key2 in typedVal) {
338
- if (ctx.ignoreAttr.IsSome() && ctx.ignoreAttr.unwrap().test(key2)) {
334
+ for (const key in typedVal) {
335
+ if (ctx.ignoreAttr.IsSome() && ctx.ignoreAttr.unwrap().test(key)) {
339
336
  continue;
340
337
  }
341
- const element = typedVal[key2];
338
+ const element = typedVal[key];
342
339
  if (element instanceof LogValue) {
343
- res[key2] = element;
340
+ res[key] = element;
344
341
  } else {
345
342
  if (typeof element !== "function") {
346
- res[key2] = logValueInternal(element, ctx);
343
+ res[key] = logValueInternal(element, ctx);
347
344
  }
348
345
  }
349
346
  }
@@ -513,9 +510,9 @@ var SysTime = class extends Time {
513
510
  return /* @__PURE__ */ new Date();
514
511
  }
515
512
  Sleep(duration) {
516
- return new Promise((resolve2) => {
513
+ return new Promise((resolve) => {
517
514
  setTimeout(() => {
518
- resolve2();
515
+ resolve();
519
516
  }, duration);
520
517
  });
521
518
  }
@@ -628,13 +625,15 @@ var BaseSysAbstraction = class {
628
625
  this._systemService = params.SystemService;
629
626
  this._txtEnDe = params.TxtEnDecoder;
630
627
  const decoder2 = this._txtEnDe;
631
- this._stdout = CFWriteableStream(async (chunk) => {
628
+ this._stdout = CFWriteableStream((chunk) => {
632
629
  const decoded = decoder2.decode(chunk);
633
630
  console.log(decoded.trimEnd());
631
+ return Promise.resolve();
634
632
  });
635
- this._stderr = CFWriteableStream(async (chunk) => {
633
+ this._stderr = CFWriteableStream((chunk) => {
636
634
  const decoded = decoder2.decode(chunk);
637
635
  console.error(decoded.trimEnd());
636
+ return Promise.resolve();
638
637
  });
639
638
  }
640
639
  };
@@ -778,24 +777,24 @@ var Keyed = class {
778
777
  this._map = /* @__PURE__ */ new Map();
779
778
  this.factory = factory;
780
779
  }
781
- async asyncGet(key2) {
782
- return this.get(await key2());
780
+ async asyncGet(key) {
781
+ return this.get(await key());
783
782
  }
784
- get(key2) {
785
- if (typeof key2 === "function") {
786
- key2 = key2();
783
+ get(key) {
784
+ if (typeof key === "function") {
785
+ key = key();
787
786
  }
788
- let keyed = this._map.get(key2);
787
+ let keyed = this._map.get(key);
789
788
  if (!keyed) {
790
- keyed = this.factory(key2);
791
- this._map.set(key2, keyed);
789
+ keyed = this.factory(key);
790
+ this._map.set(key, keyed);
792
791
  }
793
792
  return keyed;
794
793
  }
795
- unget(key2) {
796
- const keyed = this._map.get(key2);
794
+ unget(key) {
795
+ const keyed = this._map.get(key);
797
796
  keyed == null ? void 0 : keyed.reset();
798
- this._map.delete(key2);
797
+ this._map.delete(key);
799
798
  }
800
799
  reset() {
801
800
  this._map.forEach((keyed) => keyed.reset());
@@ -804,7 +803,7 @@ var Keyed = class {
804
803
  };
805
804
  var KeyedResolvOnce = class extends Keyed {
806
805
  constructor() {
807
- super((key2) => new ResolveOnce(key2));
806
+ super((key) => new ResolveOnce(key));
808
807
  }
809
808
  };
810
809
 
@@ -821,7 +820,10 @@ function isSet(value, ref = globalThis) {
821
820
  }
822
821
  function runtimeFn() {
823
822
  const gt = globalThis;
824
- let isReactNative = isSet("navigator.product") && typeof gt["navigator"] === "object" && gt["navigator"]["product"] === "ReactNative";
823
+ let isReactNative = (
824
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
825
+ isSet("navigator.product") && typeof gt["navigator"] === "object" && gt["navigator"]["product"] === "ReactNative"
826
+ );
825
827
  let isNodeIsh = false;
826
828
  if (!isSet("Deno")) {
827
829
  isNodeIsh = isSet("process.versions.node") && !isReactNative;
@@ -842,12 +844,7 @@ function runtimeFn() {
842
844
  };
843
845
  }
844
846
 
845
- // src/deno/deno-file-service.ts
846
- var path = __toESM(require("path"), 1);
847
- var Deno = globalThis.Deno;
848
-
849
- // src/deno/deno-sys-abstraction.ts
850
- var Deno2 = globalThis.Deno;
847
+ // src/deno/deno-env-actions.ts
851
848
  var once = new ResolveOnce();
852
849
  var _deno;
853
850
  var _DenoEnvActions = class _DenoEnvActions {
@@ -862,8 +859,8 @@ var _DenoEnvActions = class _DenoEnvActions {
862
859
  return __privateGet(this, _deno).Deno.env;
863
860
  }
864
861
  register(env) {
865
- for (const key2 of env.keys()) {
866
- this._env.set(key2, env.get(key2) || "");
862
+ for (const key of env.keys()) {
863
+ this._env.set(key, env.get(key) || "");
867
864
  }
868
865
  return env;
869
866
  }
@@ -873,109 +870,22 @@ var _DenoEnvActions = class _DenoEnvActions {
873
870
  keys() {
874
871
  return Object.keys(this._env.toObject());
875
872
  }
876
- get(key2) {
877
- return this._env.get(key2);
873
+ get(key) {
874
+ return this._env.get(key);
878
875
  }
879
- set(key2, value) {
876
+ set(key, value) {
880
877
  if (value) {
881
- this._env.set(key2, value);
878
+ this._env.set(key, value);
882
879
  }
883
880
  }
884
- delete(key2) {
885
- this._env.delete(key2);
881
+ delete(key) {
882
+ this._env.delete(key);
886
883
  }
887
884
  };
888
885
  _deno = new WeakMap();
889
886
  var DenoEnvActions = _DenoEnvActions;
890
- var DenoExitServiceImpl = class {
891
- constructor() {
892
- this._exitHandlers = [];
893
- this.invoked = false;
894
- this._handleExit = async () => {
895
- if (this.invoked) {
896
- return;
897
- }
898
- this.invoked = true;
899
- for (const h of this._exitHandlers) {
900
- try {
901
- const ret = h.hdl();
902
- if (typeof ret.then === "function") {
903
- await ret;
904
- }
905
- } finally {
906
- }
907
- }
908
- };
909
- globalThis.addEventListener("unhandledrejection", (e) => {
910
- e.preventDefault();
911
- this.exit(19);
912
- });
913
- globalThis.addEventListener("error", () => {
914
- this.exit(19);
915
- });
916
- globalThis.addEventListener("uncaughtException", () => {
917
- this.exit(19);
918
- });
919
- globalThis.addEventListener("unload", () => {
920
- this.exit(0);
921
- });
922
- Deno2.addSignalListener("SIGQUIT", () => {
923
- this.exit(3);
924
- });
925
- Deno2.addSignalListener("SIGINT", () => {
926
- this.exit(2);
927
- });
928
- Deno2.addSignalListener("SIGTERM", () => {
929
- this.exit(9);
930
- });
931
- }
932
- injectExitHandlers(hdls) {
933
- this._exitHandlers = hdls;
934
- }
935
- exit(code) {
936
- this._handleExit().then(() => {
937
- Deno2.exit(code);
938
- }).catch((err) => {
939
- console.error("ExitService: failed to handle exit", err);
940
- Deno2.exit(code);
941
- });
942
- }
943
- };
944
- var _DenoSystemService = class _DenoSystemService {
945
- constructor() {
946
- this._exitService = new DenoExitServiceImpl();
947
- this._exitService.injectExitHandlers(_DenoSystemService._exitHandlers);
948
- }
949
- Env() {
950
- return envFactory();
951
- }
952
- Args() {
953
- return Deno2.args;
954
- }
955
- OnExit(hdl) {
956
- const id = crypto.randomUUID();
957
- _DenoSystemService._exitHandlers.push({ hdl, id });
958
- return () => {
959
- const idx = _DenoSystemService._exitHandlers.findIndex((h) => h.id === id);
960
- if (idx >= 0) {
961
- _DenoSystemService._exitHandlers.splice(idx, 1);
962
- }
963
- };
964
- }
965
- Exit(code) {
966
- this._exitService.exit(code);
967
- }
968
- };
969
- _DenoSystemService._exitHandlers = [];
970
- var DenoSystemService = _DenoSystemService;
971
-
972
- // src/node/node-file-service.ts
973
- var import_node_path = __toESM(require("path"), 1);
974
- var import_node_fs = __toESM(require("fs"), 1);
975
- var import_node_process = __toESM(require("process"), 1);
976
887
 
977
- // src/node/node-sys-abstraction.ts
978
- var import_node_process2 = __toESM(require("process"), 1);
888
+ // src/node/node-env-actions.ts
979
889
  var once2 = new ResolveOnce();
980
890
  var _node;
981
891
  var _NodeEnvActions = class _NodeEnvActions {
@@ -988,8 +898,8 @@ var _NodeEnvActions = class _NodeEnvActions {
988
898
  return once2.once(() => new _NodeEnvActions(opts));
989
899
  }
990
900
  register(env) {
991
- for (const key2 of env.keys()) {
992
- this._env[key2] = env.get(key2) || "";
901
+ for (const key of env.keys()) {
902
+ this._env[key] = env.get(key) || "";
993
903
  }
994
904
  return env;
995
905
  }
@@ -999,120 +909,75 @@ var _NodeEnvActions = class _NodeEnvActions {
999
909
  keys() {
1000
910
  return Object.keys(this._env);
1001
911
  }
1002
- get(key2) {
1003
- return this._env[key2];
912
+ get(key) {
913
+ return this._env[key];
1004
914
  }
1005
- set(key2, value) {
915
+ set(key, value) {
1006
916
  if (value) {
1007
- this._env[key2] = value;
917
+ this._env[key] = value;
1008
918
  }
1009
919
  }
1010
- delete(key2) {
1011
- delete this._env[key2];
920
+ delete(key) {
921
+ delete this._env[key];
1012
922
  }
1013
923
  };
1014
924
  _node = new WeakMap();
1015
925
  var NodeEnvActions = _NodeEnvActions;
1016
- var NodeExitServiceImpl = class {
1017
- constructor() {
1018
- this._exitHandlers = [];
1019
- this.invoked = false;
1020
- this._handleExit = async () => {
1021
- if (this.invoked) {
1022
- return;
1023
- }
1024
- this.invoked = true;
1025
- for (const h of this._exitHandlers) {
1026
- try {
1027
- const ret = h.hdl();
1028
- if (typeof ret.then === "function") {
1029
- await ret;
1030
- }
1031
- } finally {
1032
- }
1033
- }
1034
- };
1035
- import_node_process2.default.on("unhandledRejection", (reason, p) => {
1036
- this.exit(19);
1037
- });
1038
- import_node_process2.default.on("uncaughtException", (error) => {
1039
- this.exit(18);
1040
- });
1041
- import_node_process2.default.on("close", () => {
1042
- this.exit(0);
1043
- });
1044
- import_node_process2.default.on("exit", () => {
1045
- this.exit(0);
1046
- });
1047
- import_node_process2.default.on("SIGQUIT", () => {
1048
- this.exit(3);
1049
- });
1050
- import_node_process2.default.on("SIGINT", () => {
1051
- this.exit(2);
1052
- });
1053
- import_node_process2.default.on("SIGTERM", () => {
1054
- this.exit(9);
1055
- });
926
+
927
+ // src/web/web-env-actions.ts
928
+ var once3 = new ResolveOnce();
929
+ var BrowserEnvActions = class _BrowserEnvActions {
930
+ constructor(opts) {
931
+ this.env = /* @__PURE__ */ new Map();
932
+ this.opts = opts;
1056
933
  }
1057
- injectExitHandlers(hdls) {
1058
- this._exitHandlers = hdls;
934
+ static new(opts) {
935
+ return once3.once(() => new _BrowserEnvActions(opts));
1059
936
  }
1060
- exit(code) {
1061
- this._handleExit().then(() => {
1062
- import_node_process2.default.exit(code);
1063
- }).catch((err) => {
1064
- console.error("ExitService: failed to handle exit", err);
1065
- import_node_process2.default.exit(code);
1066
- });
937
+ get(key) {
938
+ return this.env.get(key);
1067
939
  }
1068
- };
1069
- var _NodeSystemService = class _NodeSystemService {
1070
- constructor() {
1071
- this._exitService = new NodeExitServiceImpl();
1072
- this._exitService.injectExitHandlers(_NodeSystemService._exitHandlers);
940
+ set(key, value) {
941
+ if (value) {
942
+ this.env.set(key, value);
943
+ }
1073
944
  }
1074
- Env() {
1075
- return envFactory();
945
+ delete(key) {
946
+ this.env.delete(key);
1076
947
  }
1077
- Args() {
1078
- return import_node_process2.default.argv;
948
+ keys() {
949
+ return Array.from(this.env.keys());
1079
950
  }
1080
- OnExit(hdl) {
1081
- const id = crypto.randomUUID();
1082
- _NodeSystemService._exitHandlers.push({ hdl, id });
1083
- return () => {
1084
- const idx = _NodeSystemService._exitHandlers.findIndex((h) => h.id === id);
1085
- if (idx >= 0) {
1086
- _NodeSystemService._exitHandlers.splice(idx, 1);
1087
- }
1088
- };
951
+ active() {
952
+ return true;
1089
953
  }
1090
- Exit(code) {
1091
- this._exitService.exit(code);
954
+ register(env) {
955
+ const sym = Symbol.for(this.opts.symbol || "CP_ENV");
956
+ const browser = globalThis;
957
+ browser[sym] = env;
958
+ return env;
1092
959
  }
1093
960
  };
1094
- _NodeSystemService._exitHandlers = [];
1095
- var NodeSystemService = _NodeSystemService;
1096
961
 
1097
- // src/cf/cf-sys-abstraction.ts
1098
- var once3 = new ResolveOnce();
962
+ // src/cf/cf-env-actions.ts
963
+ var once4 = new ResolveOnce();
1099
964
  var CFEnvActions = class _CFEnvActions {
1100
965
  constructor(env) {
1101
966
  this.injectOnRegister = {};
1102
967
  this.cfEnv = new Map(Object.entries(env.presetEnv || {}));
1103
968
  }
1104
969
  static new(opts) {
1105
- return once3.once(() => new _CFEnvActions(opts));
970
+ return once4.once(() => new _CFEnvActions(opts));
1106
971
  }
1107
972
  static inject(o) {
1108
973
  const env = _CFEnvActions.new({});
1109
- for (const key2 in o) {
1110
- const value = o[key2];
974
+ for (const key in o) {
975
+ const value = o[key];
1111
976
  if (typeof value === "string") {
1112
977
  if (env.env) {
1113
- env.env.set(key2, value);
978
+ env.env.set(key, value);
1114
979
  } else {
1115
- env.injectOnRegister[key2] = value;
980
+ env.injectOnRegister[key] = value;
1116
981
  }
1117
982
  }
1118
983
  }
@@ -1122,27 +987,177 @@ var CFEnvActions = class _CFEnvActions {
1122
987
  }
1123
988
  register(env) {
1124
989
  this.env = env;
1125
- for (const key2 in this.injectOnRegister) {
1126
- env.set(key2, this.injectOnRegister[key2]);
990
+ for (const key in this.injectOnRegister) {
991
+ env.set(key, this.injectOnRegister[key]);
1127
992
  }
1128
993
  return env;
1129
994
  }
1130
- get(key2) {
1131
- return this.cfEnv.get(key2);
995
+ get(key) {
996
+ return this.cfEnv.get(key);
1132
997
  }
1133
- set(key2, value) {
998
+ set(key, value) {
1134
999
  if (value) {
1135
- this.cfEnv.set(key2, value);
1000
+ this.cfEnv.set(key, value);
1136
1001
  }
1137
1002
  }
1138
- delete(key2) {
1139
- this.cfEnv.delete(key2);
1003
+ delete(key) {
1004
+ this.cfEnv.delete(key);
1140
1005
  }
1141
1006
  keys() {
1142
1007
  return Array.from(this.cfEnv.keys());
1143
1008
  }
1144
1009
  };
1145
1010
 
1011
+ // src/result.ts
1012
+ var Result = class _Result {
1013
+ static Ok(t) {
1014
+ return new ResultOK(t);
1015
+ }
1016
+ static Err(t) {
1017
+ if (typeof t === "string") {
1018
+ return new ResultError(new Error(t));
1019
+ }
1020
+ if (_Result.Is(t)) {
1021
+ if (t.is_ok()) {
1022
+ return new ResultError(new Error("Result Error is Ok"));
1023
+ }
1024
+ return t;
1025
+ }
1026
+ return new ResultError(t);
1027
+ }
1028
+ static Is(t) {
1029
+ if (!t) {
1030
+ return false;
1031
+ }
1032
+ if (t instanceof _Result) {
1033
+ return true;
1034
+ }
1035
+ const rt = t;
1036
+ if ([typeof rt.is_ok, typeof rt.is_err, typeof rt.unwrap, typeof rt.unwrap_err].every((x) => x === "function")) {
1037
+ return true;
1038
+ }
1039
+ return false;
1040
+ }
1041
+ isOk() {
1042
+ return this.is_ok();
1043
+ }
1044
+ isErr() {
1045
+ return this.is_err();
1046
+ }
1047
+ Ok() {
1048
+ return this.unwrap();
1049
+ }
1050
+ Err() {
1051
+ return this.unwrap_err();
1052
+ }
1053
+ };
1054
+ var ResultOK = class extends Result {
1055
+ constructor(t) {
1056
+ super();
1057
+ this._t = t;
1058
+ }
1059
+ is_ok() {
1060
+ return true;
1061
+ }
1062
+ is_err() {
1063
+ return false;
1064
+ }
1065
+ unwrap_err() {
1066
+ throw new Error("Result is Ok");
1067
+ }
1068
+ unwrap() {
1069
+ return this._t;
1070
+ }
1071
+ };
1072
+ var ResultError = class extends Result {
1073
+ constructor(t) {
1074
+ super();
1075
+ this._error = t;
1076
+ }
1077
+ is_ok() {
1078
+ return false;
1079
+ }
1080
+ is_err() {
1081
+ return true;
1082
+ }
1083
+ unwrap() {
1084
+ throw new Error(`Result is Err: ${this._error}`);
1085
+ }
1086
+ unwrap_err() {
1087
+ return this._error;
1088
+ }
1089
+ };
1090
+ function exception2Result(fn) {
1091
+ try {
1092
+ const res = fn();
1093
+ if (res instanceof Promise) {
1094
+ return res.then((value) => Result.Ok(value)).catch((e) => Result.Err(e));
1095
+ }
1096
+ return Result.Ok(res);
1097
+ } catch (e) {
1098
+ return Result.Err(e);
1099
+ }
1100
+ }
1101
+
1102
+ // src/utils/get-params-result.ts
1103
+ var _REQUIRED = class {
1104
+ constructor() {
1105
+ this.val = "REQUIRED";
1106
+ }
1107
+ };
1108
+ var _OPTIONAL = class {
1109
+ constructor() {
1110
+ this.val = "OPTIONAL";
1111
+ }
1112
+ };
1113
+ var param = {
1114
+ REQUIRED: new _REQUIRED(),
1115
+ OPTIONAL: new _OPTIONAL()
1116
+ };
1117
+ function getParamsResult(keys, getParam) {
1118
+ const keyDef = keys.flat().reduce(
1119
+ (acc, i) => {
1120
+ if (typeof i === "string") {
1121
+ acc.push({ key: i, def: void 0, isOptional: false });
1122
+ } else if (typeof i === "object") {
1123
+ acc.push(
1124
+ ...Object.keys(i).map((k) => ({
1125
+ key: k,
1126
+ def: typeof i[k] === "string" ? i[k] : void 0,
1127
+ isOptional: i[k] === param.OPTIONAL
1128
+ }))
1129
+ );
1130
+ }
1131
+ return acc;
1132
+ },
1133
+ []
1134
+ );
1135
+ const msgFn = keys.find((k) => typeof k === "function") || ((...keys2) => {
1136
+ const msg = keys2.join(",");
1137
+ return `missing parameters: ${msg}`;
1138
+ });
1139
+ const errors = [];
1140
+ const result = {};
1141
+ for (const kd of keyDef) {
1142
+ const val = getParam.getParam(kd.key);
1143
+ if (val === void 0) {
1144
+ if (typeof kd.def === "string") {
1145
+ result[kd.key] = kd.def;
1146
+ } else {
1147
+ if (!kd.isOptional) {
1148
+ errors.push(kd.key);
1149
+ }
1150
+ }
1151
+ } else {
1152
+ result[kd.key] = val;
1153
+ }
1154
+ }
1155
+ if (errors.length) {
1156
+ return Result.Err(msgFn(...errors));
1157
+ }
1158
+ return Result.Ok(result);
1159
+ }
1160
+
1146
1161
  // src/sys-env.ts
1147
1162
  var envActions = [
1148
1163
  { id: "cf", fn: (opts) => CFEnvActions.new(opts) },
@@ -1158,30 +1173,80 @@ function envFactory(opts = {}) {
1158
1173
  }
1159
1174
  return _envFactories.get(found.id).once(() => {
1160
1175
  const action = found.fn(opts);
1161
- const ret = new EnvImpl2(action, opts);
1176
+ const ret = new EnvImpl(action, opts);
1162
1177
  action.register(ret);
1163
1178
  return ret;
1164
1179
  });
1165
1180
  }
1166
- var EnvImpl2 = class {
1181
+ function isIterable(obj) {
1182
+ if (obj == null) {
1183
+ return false;
1184
+ }
1185
+ return typeof obj[Symbol.iterator] === "function";
1186
+ }
1187
+ var EnvImpl = class {
1167
1188
  constructor(map, opts = {}) {
1168
1189
  this._onSet = [];
1169
1190
  this._map = map;
1170
1191
  this._updatePresets(opts.presetEnv);
1171
1192
  }
1193
+ gets(...kparams) {
1194
+ return getParamsResult(kparams, {
1195
+ getParam: (k) => this.get(k)
1196
+ });
1197
+ }
1198
+ sets(...keys) {
1199
+ keys.forEach((key) => {
1200
+ if (Array.isArray(key)) {
1201
+ if (key.length === 2) {
1202
+ const [k, v] = key;
1203
+ if (typeof k === "string" && typeof v === "string") {
1204
+ this.set(k, v);
1205
+ return;
1206
+ }
1207
+ }
1208
+ for (const item of key) {
1209
+ if (Array.isArray(item)) {
1210
+ if (item.length === 2) {
1211
+ const [k, v] = item;
1212
+ if (typeof k === "string" && typeof v === "string") {
1213
+ this.set(k, v);
1214
+ }
1215
+ }
1216
+ }
1217
+ }
1218
+ } else {
1219
+ if (isIterable(key)) {
1220
+ for (const [k, v] of key) {
1221
+ if (typeof k === "string" && typeof v === "string") {
1222
+ this.set(k, v);
1223
+ }
1224
+ }
1225
+ } else {
1226
+ const rKey = key;
1227
+ for (const k in rKey) {
1228
+ const v = rKey[k];
1229
+ if (typeof k === "string" && typeof v === "string") {
1230
+ this.set(k, v);
1231
+ }
1232
+ }
1233
+ }
1234
+ }
1235
+ });
1236
+ }
1172
1237
  _updatePresets(presetEnv) {
1173
1238
  if (!presetEnv) {
1174
1239
  return;
1175
1240
  }
1176
- for (const [key2, value] of presetEnv) {
1177
- this._map.set(key2, value);
1241
+ for (const [key, value] of presetEnv) {
1242
+ this._map.set(key, value);
1178
1243
  }
1179
1244
  }
1180
- _applyOnSet(onSet, key2, value) {
1245
+ _applyOnSet(onSet, key, value) {
1181
1246
  onSet.forEach((item) => {
1182
1247
  let keys = [];
1183
- if (key2) {
1184
- keys = [key2];
1248
+ if (key) {
1249
+ keys = [key];
1185
1250
  } else {
1186
1251
  keys = this._map.keys();
1187
1252
  }
@@ -1195,9 +1260,9 @@ var EnvImpl2 = class {
1195
1260
  return false;
1196
1261
  }).forEach((k) => {
1197
1262
  let v;
1198
- if (!key2 && !value) {
1263
+ if (!key && !value) {
1199
1264
  v = this._map.get(k);
1200
- } else if (key2 && !value) {
1265
+ } else if (key && !value) {
1201
1266
  v = void 0;
1202
1267
  } else {
1203
1268
  v = value;
@@ -1215,56 +1280,23 @@ var EnvImpl2 = class {
1215
1280
  this._onSet.push(item);
1216
1281
  this._applyOnSet([item]);
1217
1282
  }
1218
- get(key2) {
1219
- return this._map.get(key2);
1283
+ get(key) {
1284
+ return this._map.get(key);
1220
1285
  }
1221
- set(key2, value) {
1286
+ set(key, value) {
1222
1287
  if (!value) {
1223
1288
  return;
1224
1289
  }
1225
- this._map.set(key2, value);
1226
- this._applyOnSet(this._onSet, key2, value);
1290
+ this._map.set(key, value);
1291
+ this._applyOnSet(this._onSet, key, value);
1227
1292
  }
1228
- delete(key2) {
1229
- this._map.delete(key2);
1230
- this._applyOnSet(this._onSet, key2);
1293
+ delete(key) {
1294
+ this._map.delete(key);
1295
+ this._applyOnSet(this._onSet, key);
1231
1296
  }
1232
1297
  };
1233
1298
 
1234
1299
  // src/web/web-sys-abstraction.ts
1235
- var once4 = new ResolveOnce();
1236
- var BrowserEnvActions = class _BrowserEnvActions {
1237
- constructor(opts) {
1238
- this.env = /* @__PURE__ */ new Map();
1239
- this.opts = opts;
1240
- }
1241
- static new(opts) {
1242
- return once4.once(() => new _BrowserEnvActions(opts));
1243
- }
1244
- get(key2) {
1245
- return this.env.get(key2);
1246
- }
1247
- set(key2, value) {
1248
- if (value) {
1249
- this.env.set(key2, value);
1250
- }
1251
- }
1252
- delete(key2) {
1253
- this.env.delete(key2);
1254
- }
1255
- keys() {
1256
- return Array.from(this.env.keys());
1257
- }
1258
- active() {
1259
- return true;
1260
- }
1261
- register(env) {
1262
- const sym = Symbol.for(this.opts.symbol || "CP_ENV");
1263
- const browser = globalThis;
1264
- browser[sym] = env;
1265
- return env;
1266
- }
1267
- };
1268
1300
  var WebFileService = class {
1269
1301
  get baseDir() {
1270
1302
  throw new Error("basedir-Method not implemented.");
@@ -1327,106 +1359,15 @@ var WebSystemService = class {
1327
1359
  }
1328
1360
  };
1329
1361
  var my = void 0;
1330
- function WebSysAbstraction(param) {
1362
+ function WebSysAbstraction(param2) {
1331
1363
  if (!my) {
1332
1364
  my = new BaseSysAbstraction({
1333
- TxtEnDecoder: (param == null ? void 0 : param.TxtEnDecoder) || Utf8EnDecoderSingleton(),
1365
+ TxtEnDecoder: (param2 == null ? void 0 : param2.TxtEnDecoder) || Utf8EnDecoderSingleton(),
1334
1366
  FileSystem: new WebFileService(),
1335
1367
  SystemService: new WebSystemService()
1336
1368
  });
1337
1369
  }
1338
- return new WrapperSysAbstraction(my, param);
1339
- }
1340
-
1341
- // src/result.ts
1342
- var Result = class _Result {
1343
- static Ok(t) {
1344
- return new ResultOK(t);
1345
- }
1346
- static Err(t) {
1347
- if (typeof t === "string") {
1348
- return new ResultError(new Error(t));
1349
- }
1350
- if (_Result.Is(t)) {
1351
- if (t.is_ok()) {
1352
- return new ResultError(new Error("Result Error is Ok"));
1353
- }
1354
- return t;
1355
- }
1356
- return new ResultError(t);
1357
- }
1358
- static Is(t) {
1359
- if (!t) {
1360
- return false;
1361
- }
1362
- if (t instanceof _Result) {
1363
- return true;
1364
- }
1365
- const rt = t;
1366
- if ([typeof rt.is_ok, typeof rt.is_err, typeof rt.unwrap, typeof rt.unwrap_err].every((x) => x === "function")) {
1367
- return true;
1368
- }
1369
- return false;
1370
- }
1371
- isOk() {
1372
- return this.is_ok();
1373
- }
1374
- isErr() {
1375
- return this.is_err();
1376
- }
1377
- Ok() {
1378
- return this.unwrap();
1379
- }
1380
- Err() {
1381
- return this.unwrap_err();
1382
- }
1383
- };
1384
- var ResultOK = class extends Result {
1385
- constructor(t) {
1386
- super();
1387
- this._t = t;
1388
- }
1389
- is_ok() {
1390
- return true;
1391
- }
1392
- is_err() {
1393
- return false;
1394
- }
1395
- unwrap_err() {
1396
- throw new Error("Result is Ok");
1397
- }
1398
- unwrap() {
1399
- return this._t;
1400
- }
1401
- };
1402
- var ResultError = class extends Result {
1403
- constructor(t) {
1404
- super();
1405
- this._error = t;
1406
- }
1407
- is_ok() {
1408
- return false;
1409
- }
1410
- is_err() {
1411
- return true;
1412
- }
1413
- unwrap() {
1414
- throw new Error(`Result is Err: ${this._error}`);
1415
- }
1416
- unwrap_err() {
1417
- return this._error;
1418
- }
1419
- };
1420
- function exception2Result(fn) {
1421
- try {
1422
- const res = fn();
1423
- if (res instanceof Promise) {
1424
- return res.then((value) => Result.Ok(value)).catch((e) => Result.Err(e));
1425
- }
1426
- return Result.Ok(res);
1427
- } catch (e) {
1428
- return Result.Err(e);
1429
- }
1370
+ return new WrapperSysAbstraction(my, param2);
1430
1371
  }
1431
1372
 
1432
1373
  // src/utils/relative-path.ts
@@ -1475,23 +1416,23 @@ var Path = class {
1475
1416
  this.parts.push(part);
1476
1417
  }
1477
1418
  };
1478
- function splitPath(path3) {
1419
+ function splitPath(path) {
1479
1420
  const p = new Path();
1480
- if (path3 === "") {
1421
+ if (path === "") {
1481
1422
  return p;
1482
1423
  }
1483
- for (let count = 0; path3.length; count++) {
1484
- if (path3.match(/^\/+/)) {
1424
+ for (let count = 0; path.length; count++) {
1425
+ if (path.match(/^\/+/)) {
1485
1426
  if (count === 0) {
1486
1427
  p.add(3 /* Root */);
1487
1428
  } else {
1488
1429
  p.add(1 /* Slash */);
1489
1430
  }
1490
- path3 = path3.replace(/^\/+/, "");
1431
+ path = path.replace(/^\/+/, "");
1491
1432
  } else {
1492
- const part = path3.replace(/\/.*$/, "");
1433
+ const part = path.replace(/\/.*$/, "");
1493
1434
  p.add(part);
1494
- path3 = path3.replace(/^[^/]+/, "");
1435
+ path = path.replace(/^[^/]+/, "");
1495
1436
  }
1496
1437
  }
1497
1438
  return p;
@@ -1500,29 +1441,29 @@ function pathJoin(...paths) {
1500
1441
  let prev = "";
1501
1442
  const res = [];
1502
1443
  for (let i = 0; i < paths.length; i++) {
1503
- const path3 = paths[i];
1504
- if (path3 === "") {
1444
+ const path = paths[i];
1445
+ if (path === "") {
1505
1446
  continue;
1506
1447
  }
1507
- if (!(prev.endsWith("/") || path3.startsWith("/"))) {
1448
+ if (!(prev.endsWith("/") || path.startsWith("/"))) {
1508
1449
  if (prev !== "") {
1509
1450
  res.push("/");
1510
1451
  }
1511
- res.push(path3);
1452
+ res.push(path);
1512
1453
  } else {
1513
- res.push(path3);
1454
+ res.push(path);
1514
1455
  }
1515
- prev = path3;
1456
+ prev = path;
1516
1457
  }
1517
1458
  return res.join("");
1518
1459
  }
1519
- function relativePath(path3, relative2) {
1520
- const relativeParts = splitPath(relative2);
1460
+ function relativePath(path, relative) {
1461
+ const relativeParts = splitPath(relative);
1521
1462
  let result;
1522
1463
  if (relativeParts.parts[0] === 3 /* Root */) {
1523
- result = relative2;
1464
+ result = relative;
1524
1465
  } else {
1525
- result = pathJoin(path3, relative2);
1466
+ result = pathJoin(path, relative);
1526
1467
  }
1527
1468
  const unoptPath = splitPath(result);
1528
1469
  const out = [];
@@ -1574,45 +1515,45 @@ function stripper(strip, obj) {
1574
1515
  });
1575
1516
  return localStripper(void 0, restrips, obj);
1576
1517
  }
1577
- function localStripper(path3, restrips, obj) {
1518
+ function localStripper(path, restrips, obj) {
1578
1519
  if (typeof obj !== "object" || obj === null) {
1579
1520
  return obj;
1580
1521
  }
1581
1522
  if (Array.isArray(obj)) {
1582
- return obj.map((i) => localStripper(path3, restrips, i));
1523
+ return obj.map((i) => localStripper(path, restrips, i));
1583
1524
  }
1584
1525
  const ret = { ...obj };
1585
- const matcher = (key2, nextPath) => {
1526
+ const matcher = (key, nextPath) => {
1586
1527
  for (const re of restrips) {
1587
- if (re.test(key2) || re.test(nextPath)) {
1528
+ if (re.test(key) || re.test(nextPath)) {
1588
1529
  return true;
1589
1530
  }
1590
1531
  }
1591
1532
  return false;
1592
1533
  };
1593
- for (const key2 in ret) {
1594
- if (Object.prototype.hasOwnProperty.call(ret, key2)) {
1534
+ for (const key in ret) {
1535
+ if (Object.prototype.hasOwnProperty.call(ret, key)) {
1595
1536
  let nextPath;
1596
- if (path3) {
1597
- nextPath = [path3, key2].join(".");
1537
+ if (path) {
1538
+ nextPath = [path, key].join(".");
1598
1539
  } else {
1599
- nextPath = key2;
1540
+ nextPath = key;
1600
1541
  }
1601
- if (matcher(key2, nextPath)) {
1602
- delete ret[key2];
1542
+ if (matcher(key, nextPath)) {
1543
+ delete ret[key];
1603
1544
  continue;
1604
1545
  }
1605
- if (typeof ret[key2] === "object") {
1606
- if (Array.isArray(ret[key2])) {
1607
- ret[key2] = ret[key2].reduce((acc, v, i) => {
1608
- const toDelete = matcher(key2, `${nextPath}[${i}]`);
1546
+ if (typeof ret[key] === "object") {
1547
+ if (Array.isArray(ret[key])) {
1548
+ ret[key] = ret[key].reduce((acc, v, i) => {
1549
+ const toDelete = matcher(key, `${nextPath}[${i}]`);
1609
1550
  if (!toDelete) {
1610
1551
  acc.push(localStripper(`${nextPath}[${i}]`, restrips, v));
1611
1552
  }
1612
1553
  return acc;
1613
1554
  }, []);
1614
1555
  } else {
1615
- ret[key2] = localStripper(nextPath, restrips, ret[key2]);
1556
+ ret[key] = localStripper(nextPath, restrips, ret[key]);
1616
1557
  }
1617
1558
  }
1618
1559
  }
@@ -1621,29 +1562,15 @@ function localStripper(path3, restrips, obj) {
1621
1562
  }
1622
1563
 
1623
1564
  // src/uri.ts
1624
- var _REQUIRED = class {
1625
- constructor() {
1626
- this.val = "REQUIRED";
1627
- }
1628
- };
1629
- var _OPTIONAL = class {
1630
- constructor() {
1631
- this.val = "OPTIONAL";
1632
- }
1633
- };
1634
- var key = {
1635
- REQUIRED: new _REQUIRED(),
1636
- OPTIONAL: new _OPTIONAL()
1637
- };
1638
- function coerceKey(key2, def) {
1639
- if (typeof key2 === "object") {
1640
- const keys = Object.keys(key2);
1565
+ function coerceKey(key, def) {
1566
+ if (typeof key === "object") {
1567
+ const keys = Object.keys(key);
1641
1568
  if (keys.length !== 1) {
1642
- throw new Error(`Invalid key: ${JSON.stringify(key2)}`);
1569
+ throw new Error(`Invalid key: ${JSON.stringify(key)}`);
1643
1570
  }
1644
- return { key: keys[0], def: key2[keys[0]] };
1571
+ return { key: keys[0], def: key[keys[0]] };
1645
1572
  }
1646
- return { key: key2, def };
1573
+ return { key, def };
1647
1574
  }
1648
1575
  function falsy2undef(value) {
1649
1576
  return value === void 0 || value === null ? void 0 : value;
@@ -1746,8 +1673,8 @@ var MutableURL = class _MutableURL extends URL {
1746
1673
  toString() {
1747
1674
  let search = "";
1748
1675
  if (this._sysURL.searchParams.size) {
1749
- for (const [key2, value] of Array.from(this._sysURL.searchParams.entries()).sort((a, b) => a[0].localeCompare(b[0]))) {
1750
- search += `${!search.length ? "?" : "&"}${key2}=${encodeURIComponent(value)}`;
1676
+ for (const [key, value] of Array.from(this._sysURL.searchParams.entries()).sort((a, b) => a[0].localeCompare(b[0]))) {
1677
+ search += `${!search.length ? "?" : "&"}${key}=${encodeURIComponent(value)}`;
1751
1678
  }
1752
1679
  }
1753
1680
  let hostpart = "";
@@ -1782,57 +1709,14 @@ function from(fac, strURLUri, defaultProtocol) {
1782
1709
  throw new Error(`Invalid argument: ${typeof strURLUri}`);
1783
1710
  }
1784
1711
  }
1785
- function getParamResult(key2, val, msgFn = (key3) => {
1786
- return `missing parameter: ${key3}`;
1712
+ function getParamResult(key, val, msgFn = (key2) => {
1713
+ return `missing parameter: ${key2}`;
1787
1714
  }) {
1788
1715
  if (val === void 0) {
1789
- return Result.Err(msgFn(key2));
1716
+ return Result.Err(msgFn(key));
1790
1717
  }
1791
1718
  return Result.Ok(val);
1792
1719
  }
1793
- function getParamsResult(keys, getParam) {
1794
- const keyDef = keys.flat().reduce(
1795
- (acc, i) => {
1796
- if (typeof i === "string") {
1797
- acc.push({ key: i, def: void 0, isOptional: false });
1798
- } else if (typeof i === "object") {
1799
- acc.push(
1800
- ...Object.keys(i).map((k) => ({
1801
- key: k,
1802
- def: typeof i[k] === "string" ? i[k] : void 0,
1803
- isOptional: i[k] instanceof _OPTIONAL
1804
- }))
1805
- );
1806
- }
1807
- return acc;
1808
- },
1809
- []
1810
- );
1811
- const msgFn = keys.find((k) => typeof k === "function") || ((...keys2) => {
1812
- const msg = keys2.join(",");
1813
- return `missing parameters: ${msg}`;
1814
- });
1815
- const errors = [];
1816
- const result = {};
1817
- for (const kd of keyDef) {
1818
- const val = getParam.getParam(kd.key);
1819
- if (val === void 0) {
1820
- if (typeof kd.def === "string") {
1821
- result[kd.key] = kd.def;
1822
- } else {
1823
- if (!kd.isOptional) {
1824
- errors.push(kd.key);
1825
- }
1826
- }
1827
- } else {
1828
- result[kd.key] = val;
1829
- }
1830
- }
1831
- if (errors.length) {
1832
- return Result.Err(msgFn(...errors));
1833
- }
1834
- return Result.Ok(result);
1835
- }
1836
1720
  var BuildURI = class _BuildURI {
1837
1721
  // pathname needs this
1838
1722
  constructor(url) {
@@ -1886,47 +1770,47 @@ var BuildURI = class _BuildURI {
1886
1770
  const pathname = "./" + appendUrl.pathname;
1887
1771
  const basePath = this._url.pathname;
1888
1772
  this.pathname(relativePath(basePath, pathname));
1889
- for (const [key2, value] of appendUrl.getParams) {
1890
- this.setParam(key2, value);
1773
+ for (const [key, value] of appendUrl.getParams) {
1774
+ this.setParam(key, value);
1891
1775
  }
1892
1776
  return this;
1893
1777
  }
1894
1778
  cleanParams() {
1895
- for (const key2 of Array.from(this._url.searchParams.keys())) {
1896
- this._url.searchParams.delete(key2);
1779
+ for (const key of Array.from(this._url.searchParams.keys())) {
1780
+ this._url.searchParams.delete(key);
1897
1781
  }
1898
1782
  return this;
1899
1783
  }
1900
- delParam(key2) {
1901
- this._url.searchParams.delete(key2);
1784
+ delParam(key) {
1785
+ this._url.searchParams.delete(key);
1902
1786
  return this;
1903
1787
  }
1904
- defParam(key2, str) {
1905
- if (!this._url.searchParams.has(key2)) {
1906
- this._url.searchParams.set(key2, str);
1788
+ defParam(key, str) {
1789
+ if (!this._url.searchParams.has(key)) {
1790
+ this._url.searchParams.set(key, str);
1907
1791
  }
1908
1792
  return this;
1909
1793
  }
1910
- setParam(key2, str) {
1911
- this._url.searchParams.set(key2, str);
1794
+ setParam(key, str) {
1795
+ this._url.searchParams.set(key, str);
1912
1796
  return this;
1913
1797
  }
1914
- hasParam(key2) {
1915
- return this._url.searchParams.has(key2);
1798
+ hasParam(key) {
1799
+ return this._url.searchParams.has(key);
1916
1800
  }
1917
1801
  get getParams() {
1918
1802
  return this._url.searchParams.entries();
1919
1803
  }
1920
- getParam(key2, def) {
1921
- const { key: k, def: d } = coerceKey(key2, def);
1804
+ getParam(key, def) {
1805
+ const { key: k, def: d } = coerceKey(key, def);
1922
1806
  let val = this._url.searchParams.get(k);
1923
1807
  if (!falsy2undef(val) && d) {
1924
1808
  val = d;
1925
1809
  }
1926
1810
  return falsy2undef(val);
1927
1811
  }
1928
- getParamResult(key2, msgFn) {
1929
- return getParamResult(key2, this.getParam(key2), msgFn);
1812
+ getParamResult(key, msgFn) {
1813
+ return getParamResult(key, this.getParam(key), msgFn);
1930
1814
  }
1931
1815
  getParamsResult(...keys) {
1932
1816
  return getParamsResult(keys, this);
@@ -1969,8 +1853,8 @@ var URI = class _URI {
1969
1853
  if (!(fPath.length === 0 || fPath === "/" || fPath === "./")) {
1970
1854
  intoUrl.pathname(fromUrl.pathname);
1971
1855
  }
1972
- for (const [key2, value] of fromUrl.getParams) {
1973
- intoUrl.setParam(key2, value);
1856
+ for (const [key, value] of fromUrl.getParams) {
1857
+ intoUrl.setParam(key, value);
1974
1858
  }
1975
1859
  return intoUrl.URI();
1976
1860
  }
@@ -2023,19 +1907,19 @@ var URI = class _URI {
2023
1907
  get getParams() {
2024
1908
  return this._url.searchParams.entries();
2025
1909
  }
2026
- hasParam(key2) {
2027
- return this._url.searchParams.has(key2);
1910
+ hasParam(key) {
1911
+ return this._url.searchParams.has(key);
2028
1912
  }
2029
- getParam(key2, def) {
2030
- const { key: k, def: d } = coerceKey(key2, def);
1913
+ getParam(key, def) {
1914
+ const { key: k, def: d } = coerceKey(key, def);
2031
1915
  let val = this._url.searchParams.get(k);
2032
1916
  if (!falsy2undef(val) && d) {
2033
1917
  val = d;
2034
1918
  }
2035
1919
  return falsy2undef(val);
2036
1920
  }
2037
- getParamResult(key2, msgFn) {
2038
- return getParamResult(key2, this.getParam(key2), msgFn);
1921
+ getParamResult(key, msgFn) {
1922
+ return getParamResult(key, this.getParam(key), msgFn);
2039
1923
  }
2040
1924
  getParamsResult(...keys) {
2041
1925
  return getParamsResult(keys, this);
@@ -2092,7 +1976,7 @@ var ConsoleWriterStreamDefaultWriter = class {
2092
1976
  this.ready = Promise.resolve(void 0);
2093
1977
  this.closed = Promise.resolve(void 0);
2094
1978
  }
2095
- async write(chunk) {
1979
+ write(chunk) {
2096
1980
  let strObj = this.decoder.decode(chunk).trimEnd();
2097
1981
  let output = "log";
2098
1982
  try {
@@ -2110,6 +1994,7 @@ var ConsoleWriterStreamDefaultWriter = class {
2110
1994
  default:
2111
1995
  console.log(strObj);
2112
1996
  }
1997
+ return Promise.resolve();
2113
1998
  }
2114
1999
  };
2115
2000
  var ConsoleWriterStream = class {
@@ -2120,8 +2005,8 @@ var ConsoleWriterStream = class {
2120
2005
  abort(reason) {
2121
2006
  throw new Error("Method not implemented.");
2122
2007
  }
2123
- async close() {
2124
- return;
2008
+ close() {
2009
+ return Promise.resolve();
2125
2010
  }
2126
2011
  getWriter() {
2127
2012
  if (this.locked) {
@@ -2149,7 +2034,7 @@ var LogWriterStream = class {
2149
2034
  const writer = this._out.getWriter();
2150
2035
  await writer.ready;
2151
2036
  await writer.write(encoded);
2152
- await writer.releaseLock();
2037
+ writer.releaseLock();
2153
2038
  } catch (err) {
2154
2039
  console.error("Chunk error:", err);
2155
2040
  }
@@ -2173,7 +2058,9 @@ var LogWriterStream = class {
2173
2058
  return;
2174
2059
  }
2175
2060
  const my2 = this._toFlush.shift();
2176
- my2 == null ? void 0 : my2().finally(() => {
2061
+ my2 == null ? void 0 : my2().catch((e) => {
2062
+ console.error("Flush error:", e);
2063
+ }).finally(() => {
2177
2064
  this._flush(this._toFlush);
2178
2065
  });
2179
2066
  }
@@ -2195,9 +2082,6 @@ function getLen(value, lvs) {
2195
2082
  }
2196
2083
  return logValue(() => -1, lvs);
2197
2084
  }
2198
- function hash(value) {
2199
- return "not implemented";
2200
- }
2201
2085
  function toLogValue(lop) {
2202
2086
  if (lop && typeof lop.then === "function") {
2203
2087
  throw new Error("async logValue Not implemented");
@@ -2296,9 +2180,9 @@ var LoggerImpl = class _LoggerImpl {
2296
2180
  this.levelHandler.disableLevel(level, ...modules);
2297
2181
  return this;
2298
2182
  }
2299
- Module(key2) {
2300
- this._attributes["module"] = logValue(key2, toLogValueCtx(this.levelHandler));
2301
- this._withAttributes["module"] = logValue(key2, toLogValueCtx(this.levelHandler));
2183
+ Module(key) {
2184
+ this._attributes["module"] = logValue(key, toLogValueCtx(this.levelHandler));
2185
+ this._withAttributes["module"] = logValue(key, toLogValueCtx(this.levelHandler));
2302
2186
  return this;
2303
2187
  }
2304
2188
  // if the string is "*" it will enable for all modules
@@ -2339,10 +2223,10 @@ var LoggerImpl = class _LoggerImpl {
2339
2223
  }
2340
2224
  Err(err) {
2341
2225
  var _a;
2342
- let key2 = "error";
2226
+ let key = "error";
2343
2227
  if (Result.Is(err)) {
2344
2228
  if (err.isOk()) {
2345
- key2 = "noerror";
2229
+ key = "noerror";
2346
2230
  err = err.Ok();
2347
2231
  } else {
2348
2232
  err = err.Err();
@@ -2350,12 +2234,12 @@ var LoggerImpl = class _LoggerImpl {
2350
2234
  }
2351
2235
  if (err instanceof Error) {
2352
2236
  if (err.cause) {
2353
- this.coerceKey(key2, {
2237
+ this.coerceKey(key, {
2354
2238
  message: err.message,
2355
2239
  cause: err.cause
2356
2240
  });
2357
2241
  } else {
2358
- this._attributes[key2] = logValue(err.message, toLogValueCtx(this.levelHandler));
2242
+ this._attributes[key] = logValue(err.message, toLogValueCtx(this.levelHandler));
2359
2243
  }
2360
2244
  if (this.levelHandler.isStackExposed) {
2361
2245
  this._attributes["stack"] = logValue(
@@ -2364,7 +2248,7 @@ var LoggerImpl = class _LoggerImpl {
2364
2248
  );
2365
2249
  }
2366
2250
  } else {
2367
- this.Any(key2, err);
2251
+ this.Any(key, err);
2368
2252
  }
2369
2253
  return this;
2370
2254
  }
@@ -2372,22 +2256,22 @@ var LoggerImpl = class _LoggerImpl {
2372
2256
  this._attributes["level"] = logValue(l, toLogValueCtx(this.levelHandler));
2373
2257
  return this;
2374
2258
  }
2375
- Ref(key2, action) {
2259
+ Ref(key, action) {
2376
2260
  if (typeof action === "function") {
2377
- this._attributes[key2] = logValue(action, toLogValueCtx(this.levelHandler));
2261
+ this._attributes[key] = logValue(action, toLogValueCtx(this.levelHandler));
2378
2262
  } else if (typeof action.toString === "function") {
2379
- this._attributes[key2] = logValue(() => action.toString(), toLogValueCtx(this.levelHandler));
2263
+ this._attributes[key] = logValue(() => action.toString(), toLogValueCtx(this.levelHandler));
2380
2264
  } else {
2381
- this._attributes[key2] = logValue("INVALID REF", toLogValueCtx(this.levelHandler));
2265
+ this._attributes[key] = logValue("INVALID REF", toLogValueCtx(this.levelHandler));
2382
2266
  }
2383
2267
  return this;
2384
2268
  }
2385
- Bool(key2, value) {
2386
- this.coerceKey(key2, !!value);
2269
+ Bool(key, value) {
2270
+ this.coerceKey(key, !!value);
2387
2271
  return this;
2388
2272
  }
2389
2273
  Http(...mix) {
2390
- const key2 = mix.find((x) => typeof x === "string");
2274
+ const key = mix.find((x) => typeof x === "string");
2391
2275
  mix = mix.filter((x) => typeof x !== "string");
2392
2276
  const resErrors = mix.filter((x) => Result.Is(x) && x.isErr());
2393
2277
  if (resErrors.length) {
@@ -2407,76 +2291,74 @@ var LoggerImpl = class _LoggerImpl {
2407
2291
  reqAndOrres = req;
2408
2292
  }
2409
2293
  if (reqAndOrres) {
2410
- this.Any(key2 || "Http", reqAndOrres);
2294
+ this.Any(key || "Http", reqAndOrres);
2411
2295
  }
2412
2296
  return this;
2413
2297
  }
2414
2298
  Pair(x) {
2415
- for (const key2 of Object.keys(x)) {
2416
- const value = x[key2];
2299
+ for (const key of Object.keys(x)) {
2300
+ const value = x[key];
2417
2301
  if (value instanceof LogValue) {
2418
- this._attributes[key2] = value;
2302
+ this._attributes[key] = value;
2419
2303
  continue;
2420
2304
  }
2421
2305
  if (Result.Is(value)) {
2422
- this.Result(key2, value);
2306
+ this.Result(key, value);
2423
2307
  continue;
2424
2308
  }
2425
- this.Any(key2, value);
2309
+ this.Any(key, value);
2426
2310
  }
2427
2311
  return this;
2428
2312
  }
2429
- Result(key2, res) {
2313
+ Result(key, res) {
2430
2314
  if (res.isOk()) {
2431
- this._attributes[key2] = logValue(res.Ok(), toLogValueCtx(this.levelHandler));
2315
+ this._attributes[key] = logValue(res.Ok(), toLogValueCtx(this.levelHandler));
2432
2316
  } else {
2433
2317
  this.Err(res.Err());
2434
2318
  }
2435
2319
  return this;
2436
2320
  }
2437
- Len(value, key2 = "len") {
2438
- this._attributes[key2] = getLen(value, toLogValueCtx(this.levelHandler));
2321
+ Len(value, key = "len") {
2322
+ this._attributes[key] = getLen(value, toLogValueCtx(this.levelHandler));
2439
2323
  return this;
2440
2324
  }
2441
- Hash(value, key2 = "hash") {
2442
- this._attributes[key2] = asyncLogValue(
2443
- async () => `${getLen(value, toLogValueCtx(this.levelHandler)).value()}:${await hash(value)}`
2444
- );
2445
- return this;
2325
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
2326
+ Hash(value, key = "hash") {
2327
+ throw new Error("Not implemented");
2446
2328
  }
2447
- Url(url, key2 = "url") {
2448
- this.Ref(key2, () => URI.from(url).toString());
2329
+ Url(url, key = "url") {
2330
+ this.Ref(key, () => URI.from(url).toString());
2449
2331
  return this;
2450
2332
  }
2451
- coerceKey(key2, value) {
2452
- if (typeof key2 === "string") {
2453
- this._attributes[key2] = logValue(value, toLogValueCtx(this.levelHandler));
2333
+ coerceKey(key, value) {
2334
+ if (typeof key === "string") {
2335
+ this._attributes[key] = logValue(value, toLogValueCtx(this.levelHandler));
2454
2336
  } else {
2455
- this.Pair(key2);
2337
+ this.Pair(key);
2456
2338
  }
2457
2339
  }
2458
- Str(key2, value) {
2459
- this.coerceKey(key2, value);
2340
+ Str(key, value) {
2341
+ this.coerceKey(key, value);
2460
2342
  return this;
2461
2343
  }
2462
- Any(key2, value) {
2463
- this.coerceKey(key2, value);
2344
+ Any(key, value) {
2345
+ this.coerceKey(key, value);
2464
2346
  return this;
2465
2347
  }
2466
- Dur(key2, nsec) {
2467
- this._attributes[key2] = logValue(`${nsec}ms`, toLogValueCtx(this.levelHandler));
2348
+ Dur(key, nsec) {
2349
+ this._attributes[key] = logValue(`${nsec}ms`, toLogValueCtx(this.levelHandler));
2468
2350
  return this;
2469
2351
  }
2470
- Uint64(key2, value) {
2471
- this.coerceKey(key2, value);
2352
+ Uint64(key, value) {
2353
+ this.coerceKey(key, value);
2472
2354
  return this;
2473
2355
  }
2474
- Int(key2, value) {
2475
- return this.Uint64(key2, value);
2356
+ Int(key, value) {
2357
+ return this.Uint64(key, value);
2476
2358
  }
2477
2359
  async Flush() {
2478
- return new Promise((resolve2) => {
2479
- this._logWriter._flush(void 0, resolve2);
2360
+ return new Promise((resolve) => {
2361
+ this._logWriter._flush(void 0, resolve);
2480
2362
  });
2481
2363
  }
2482
2364
  With() {
@@ -2495,8 +2377,8 @@ var LoggerImpl = class _LoggerImpl {
2495
2377
  }
2496
2378
  _resetAttributes(fn) {
2497
2379
  const ret = fn();
2498
- Object.keys(this._attributes).forEach((key2) => {
2499
- delete this._attributes[key2];
2380
+ Object.keys(this._attributes).forEach((key) => {
2381
+ delete this._attributes[key];
2500
2382
  });
2501
2383
  Object.assign(this._attributes, this._withAttributes);
2502
2384
  return ret;
@@ -2563,8 +2445,8 @@ var WithLoggerBuilder = class {
2563
2445
  this._li.levelHandler.enableLevel(level, ...modules);
2564
2446
  return this;
2565
2447
  }
2566
- Module(key2) {
2567
- this._li.Module(key2);
2448
+ Module(key) {
2449
+ this._li.Module(key);
2568
2450
  return this;
2569
2451
  }
2570
2452
  SetDebug(...modules) {
@@ -2579,36 +2461,36 @@ var WithLoggerBuilder = class {
2579
2461
  this._li.Pair(x);
2580
2462
  return this;
2581
2463
  }
2582
- Str(key2, value) {
2583
- this._li.Str(key2, value);
2464
+ Str(key, value) {
2465
+ this._li.Str(key, value);
2584
2466
  return this;
2585
2467
  }
2586
- Len(value, key2) {
2587
- this._li.Len(value, key2);
2468
+ Len(value, key) {
2469
+ this._li.Len(value, key);
2588
2470
  return this;
2589
2471
  }
2590
- Hash(value, key2) {
2591
- this._li.Hash(value, key2);
2472
+ Hash(value, key) {
2473
+ this._li.Hash(value, key);
2592
2474
  return this;
2593
2475
  }
2594
- Ref(key2, action) {
2595
- this._li.Ref(key2, action);
2476
+ Ref(key, action) {
2477
+ this._li.Ref(key, action);
2596
2478
  return this;
2597
2479
  }
2598
- Bool(key2, value) {
2599
- this._li.Bool(key2, value);
2480
+ Bool(key, value) {
2481
+ this._li.Bool(key, value);
2600
2482
  return this;
2601
2483
  }
2602
- Result(key2, res) {
2603
- this._li.Result(key2, res);
2484
+ Result(key, res) {
2485
+ this._li.Result(key, res);
2604
2486
  return this;
2605
2487
  }
2606
- Url(url, key2) {
2607
- this._li.Url(url, key2);
2488
+ Url(url, key) {
2489
+ this._li.Url(url, key);
2608
2490
  return this;
2609
2491
  }
2610
- Int(key2, value) {
2611
- this._li.Int(key2, value);
2492
+ Int(key, value) {
2493
+ this._li.Int(key, value);
2612
2494
  return this;
2613
2495
  }
2614
2496
  Log() {
@@ -2643,16 +2525,16 @@ var WithLoggerBuilder = class {
2643
2525
  this._li.Timestamp();
2644
2526
  return this;
2645
2527
  }
2646
- Any(key2, value) {
2647
- this._li.Any(key2, value);
2528
+ Any(key, value) {
2529
+ this._li.Any(key, value);
2648
2530
  return this;
2649
2531
  }
2650
- Dur(key2, nsec) {
2651
- this._li.Dur(key2, nsec);
2532
+ Dur(key, nsec) {
2533
+ this._li.Dur(key, nsec);
2652
2534
  return this;
2653
2535
  }
2654
- Uint64(key2, value) {
2655
- this._li.Uint64(key2, value);
2536
+ Uint64(key, value) {
2537
+ this._li.Uint64(key, value);
2656
2538
  return this;
2657
2539
  }
2658
2540
  };