@nestia/sdk 14.0.1 → 14.0.3

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 (377) hide show
  1. package/assets/bundle/distribute/build-sdk.cjs +28 -0
  2. package/assets/bundle/distribute/package.json +6 -2
  3. package/lib/INestiaConfig.d.ts +55 -24
  4. package/lib/NestiaSdkApplication.d.ts +60 -0
  5. package/lib/NestiaSdkApplication.js +63 -5
  6. package/lib/NestiaSdkApplication.js.map +1 -1
  7. package/lib/NestiaSwaggerComposer.d.ts +21 -0
  8. package/lib/NestiaSwaggerComposer.js +21 -3
  9. package/lib/NestiaSwaggerComposer.js.map +1 -1
  10. package/lib/analyses/AccessorAnalyzer.d.ts +26 -0
  11. package/lib/analyses/AccessorAnalyzer.js +26 -0
  12. package/lib/analyses/AccessorAnalyzer.js.map +1 -1
  13. package/lib/analyses/ConfigAnalyzer.d.ts +41 -0
  14. package/lib/analyses/ConfigAnalyzer.js +57 -80
  15. package/lib/analyses/ConfigAnalyzer.js.map +1 -1
  16. package/lib/analyses/ImportAnalyzer.d.ts +25 -0
  17. package/lib/analyses/ImportAnalyzer.js +25 -0
  18. package/lib/analyses/ImportAnalyzer.js.map +1 -1
  19. package/lib/analyses/ParameterNameAnalyzer.d.ts +24 -0
  20. package/lib/analyses/ParameterNameAnalyzer.js +15 -0
  21. package/lib/analyses/ParameterNameAnalyzer.js.map +1 -1
  22. package/lib/analyses/PathAnalyzer.d.ts +63 -1
  23. package/lib/analyses/PathAnalyzer.js +54 -9
  24. package/lib/analyses/PathAnalyzer.js.map +1 -1
  25. package/lib/analyses/ReflectControllerAnalyzer.d.ts +32 -0
  26. package/lib/analyses/ReflectControllerAnalyzer.js +22 -0
  27. package/lib/analyses/ReflectControllerAnalyzer.js.map +1 -1
  28. package/lib/analyses/ReflectHttpOperationAnalyzer.d.ts +29 -0
  29. package/lib/analyses/ReflectHttpOperationAnalyzer.js +28 -17
  30. package/lib/analyses/ReflectHttpOperationAnalyzer.js.map +1 -1
  31. package/lib/analyses/ReflectHttpOperationExceptionAnalyzer.d.ts +31 -0
  32. package/lib/analyses/ReflectHttpOperationExceptionAnalyzer.js +21 -0
  33. package/lib/analyses/ReflectHttpOperationExceptionAnalyzer.js.map +1 -1
  34. package/lib/analyses/ReflectHttpOperationParameterAnalyzer.d.ts +31 -0
  35. package/lib/analyses/ReflectHttpOperationParameterAnalyzer.js +21 -0
  36. package/lib/analyses/ReflectHttpOperationParameterAnalyzer.js.map +1 -1
  37. package/lib/analyses/ReflectHttpOperationResponseAnalyzer.d.ts +32 -0
  38. package/lib/analyses/ReflectHttpOperationResponseAnalyzer.js +22 -0
  39. package/lib/analyses/ReflectHttpOperationResponseAnalyzer.js.map +1 -1
  40. package/lib/analyses/ReflectMcpOperationAnalyzer.d.ts +29 -0
  41. package/lib/analyses/ReflectMcpOperationAnalyzer.js +30 -9
  42. package/lib/analyses/ReflectMcpOperationAnalyzer.js.map +1 -1
  43. package/lib/analyses/ReflectMetadataAnalyzer.d.ts +47 -0
  44. package/lib/analyses/ReflectMetadataAnalyzer.js +47 -0
  45. package/lib/analyses/ReflectMetadataAnalyzer.js.map +1 -1
  46. package/lib/analyses/ReflectWebSocketOperationAnalyzer.d.ts +29 -0
  47. package/lib/analyses/ReflectWebSocketOperationAnalyzer.js +22 -5
  48. package/lib/analyses/ReflectWebSocketOperationAnalyzer.js.map +1 -1
  49. package/lib/analyses/SecurityAnalyzer.d.ts +15 -0
  50. package/lib/analyses/SecurityAnalyzer.js +15 -0
  51. package/lib/analyses/SecurityAnalyzer.js.map +1 -1
  52. package/lib/analyses/SwaggerExampleAnalyzer.d.ts +16 -0
  53. package/lib/analyses/SwaggerExampleAnalyzer.js +16 -0
  54. package/lib/analyses/SwaggerExampleAnalyzer.js.map +1 -1
  55. package/lib/analyses/TypedHttpRouteAnalyzer.d.ts +41 -3
  56. package/lib/analyses/TypedHttpRouteAnalyzer.js +172 -157
  57. package/lib/analyses/TypedHttpRouteAnalyzer.js.map +1 -1
  58. package/lib/analyses/TypedMcpRouteAnalyzer.d.ts +29 -0
  59. package/lib/analyses/TypedMcpRouteAnalyzer.js +152 -20
  60. package/lib/analyses/TypedMcpRouteAnalyzer.js.map +1 -1
  61. package/lib/analyses/TypedWebSocketRouteAnalyzer.d.ts +19 -0
  62. package/lib/analyses/TypedWebSocketRouteAnalyzer.js +19 -0
  63. package/lib/analyses/TypedWebSocketRouteAnalyzer.js.map +1 -1
  64. package/lib/decorators/OperationMetadata.d.ts +6 -0
  65. package/lib/decorators/OperationMetadata.js +6 -0
  66. package/lib/decorators/OperationMetadata.js.map +1 -1
  67. package/lib/executable/internal/CommandParser.d.ts +19 -0
  68. package/lib/executable/internal/CommandParser.js +19 -0
  69. package/lib/executable/internal/CommandParser.js.map +1 -1
  70. package/lib/executable/internal/NestiaConfigLoader.d.ts +56 -0
  71. package/lib/executable/internal/NestiaConfigLoader.js +48 -42
  72. package/lib/executable/internal/NestiaConfigLoader.js.map +1 -1
  73. package/lib/executable/internal/NestiaSdkCommand.d.ts +60 -0
  74. package/lib/executable/internal/NestiaSdkCommand.js +95 -3
  75. package/lib/executable/internal/NestiaSdkCommand.js.map +1 -1
  76. package/lib/executable/internal/NestiaSdkWatcher.d.ts +81 -0
  77. package/lib/executable/internal/NestiaSdkWatcher.js +122 -38
  78. package/lib/executable/internal/NestiaSdkWatcher.js.map +1 -1
  79. package/lib/executable/internal/NestiaSwaggerWatch.d.ts +80 -0
  80. package/lib/executable/internal/NestiaSwaggerWatch.js +308 -0
  81. package/lib/executable/internal/NestiaSwaggerWatch.js.map +1 -0
  82. package/lib/factories/ExpressionFactory.d.ts +17 -2
  83. package/lib/factories/ExpressionFactory.js +17 -2
  84. package/lib/factories/ExpressionFactory.js.map +1 -1
  85. package/lib/factories/IdentifierFactory.d.ts +24 -0
  86. package/lib/factories/IdentifierFactory.js +24 -0
  87. package/lib/factories/IdentifierFactory.js.map +1 -1
  88. package/lib/factories/LiteralFactory.d.ts +22 -4
  89. package/lib/factories/LiteralFactory.js +30 -10
  90. package/lib/factories/LiteralFactory.js.map +1 -1
  91. package/lib/factories/StatementFactory.d.ts +28 -1
  92. package/lib/factories/StatementFactory.js +28 -1
  93. package/lib/factories/StatementFactory.js.map +1 -1
  94. package/lib/factories/TypeFactory.d.ts +24 -0
  95. package/lib/factories/TypeFactory.js +15 -0
  96. package/lib/factories/TypeFactory.js.map +1 -1
  97. package/lib/generates/CloneGenerator.d.ts +22 -0
  98. package/lib/generates/CloneGenerator.js +26 -5
  99. package/lib/generates/CloneGenerator.js.map +1 -1
  100. package/lib/generates/E2eGenerator.d.ts +19 -0
  101. package/lib/generates/E2eGenerator.js +19 -0
  102. package/lib/generates/E2eGenerator.js.map +1 -1
  103. package/lib/generates/SdkGenerator.d.ts +38 -0
  104. package/lib/generates/SdkGenerator.js +40 -2
  105. package/lib/generates/SdkGenerator.js.map +1 -1
  106. package/lib/generates/SwaggerGenerator.d.ts +36 -6
  107. package/lib/generates/SwaggerGenerator.js +55 -13
  108. package/lib/generates/SwaggerGenerator.js.map +1 -1
  109. package/lib/generates/internal/E2eFileProgrammer.d.ts +19 -0
  110. package/lib/generates/internal/E2eFileProgrammer.js +20 -1
  111. package/lib/generates/internal/E2eFileProgrammer.js.map +1 -1
  112. package/lib/generates/internal/FilePrinter.d.ts +43 -0
  113. package/lib/generates/internal/FilePrinter.js +43 -0
  114. package/lib/generates/internal/FilePrinter.js.map +1 -1
  115. package/lib/generates/internal/ImportDictionary.d.ts +92 -2
  116. package/lib/generates/internal/ImportDictionary.js +91 -3
  117. package/lib/generates/internal/ImportDictionary.js.map +1 -1
  118. package/lib/generates/internal/SdkAliasCollection.d.ts +119 -0
  119. package/lib/generates/internal/SdkAliasCollection.js +124 -7
  120. package/lib/generates/internal/SdkAliasCollection.js.map +1 -1
  121. package/lib/generates/internal/SdkDistributionComposer.d.ts +19 -0
  122. package/lib/generates/internal/SdkDistributionComposer.js +98 -59
  123. package/lib/generates/internal/SdkDistributionComposer.js.map +1 -1
  124. package/lib/generates/internal/SdkFileProgrammer.d.ts +18 -0
  125. package/lib/generates/internal/SdkFileProgrammer.js +18 -0
  126. package/lib/generates/internal/SdkFileProgrammer.js.map +1 -1
  127. package/lib/generates/internal/SdkHttpCloneProgrammer.d.ts +29 -0
  128. package/lib/generates/internal/SdkHttpCloneProgrammer.js +33 -0
  129. package/lib/generates/internal/SdkHttpCloneProgrammer.js.map +1 -1
  130. package/lib/generates/internal/SdkHttpCloneReferencer.d.ts +19 -0
  131. package/lib/generates/internal/SdkHttpCloneReferencer.js +78 -25
  132. package/lib/generates/internal/SdkHttpCloneReferencer.js.map +1 -1
  133. package/lib/generates/internal/SdkHttpFunctionProgrammer.d.ts +19 -0
  134. package/lib/generates/internal/SdkHttpFunctionProgrammer.js +19 -0
  135. package/lib/generates/internal/SdkHttpFunctionProgrammer.js.map +1 -1
  136. package/lib/generates/internal/SdkHttpNamespaceProgrammer.d.ts +19 -0
  137. package/lib/generates/internal/SdkHttpNamespaceProgrammer.js +19 -0
  138. package/lib/generates/internal/SdkHttpNamespaceProgrammer.js.map +1 -1
  139. package/lib/generates/internal/SdkHttpParameterProgrammer.d.ts +104 -2
  140. package/lib/generates/internal/SdkHttpParameterProgrammer.js +70 -0
  141. package/lib/generates/internal/SdkHttpParameterProgrammer.js.map +1 -1
  142. package/lib/generates/internal/SdkHttpRouteProgrammer.d.ts +20 -0
  143. package/lib/generates/internal/SdkHttpRouteProgrammer.js +20 -0
  144. package/lib/generates/internal/SdkHttpRouteProgrammer.js.map +1 -1
  145. package/lib/generates/internal/SdkHttpSimulationProgrammer.d.ts +38 -0
  146. package/lib/generates/internal/SdkHttpSimulationProgrammer.js +49 -5
  147. package/lib/generates/internal/SdkHttpSimulationProgrammer.js.map +1 -1
  148. package/lib/generates/internal/SdkImportWizard.d.ts +63 -0
  149. package/lib/generates/internal/SdkImportWizard.js +63 -0
  150. package/lib/generates/internal/SdkImportWizard.js.map +1 -1
  151. package/lib/generates/internal/SdkMcpRouteProgrammer.d.ts +17 -2
  152. package/lib/generates/internal/SdkMcpRouteProgrammer.js +33 -13
  153. package/lib/generates/internal/SdkMcpRouteProgrammer.js.map +1 -1
  154. package/lib/generates/internal/SdkPathTemplate.d.ts +15 -0
  155. package/lib/generates/internal/SdkPathTemplate.js +15 -0
  156. package/lib/generates/internal/SdkPathTemplate.js.map +1 -1
  157. package/lib/generates/internal/SdkRouteDirectory.d.ts +10 -0
  158. package/lib/generates/internal/SdkRouteDirectory.js +10 -0
  159. package/lib/generates/internal/SdkRouteDirectory.js.map +1 -1
  160. package/lib/generates/internal/SdkTypeProgrammer.d.ts +54 -1
  161. package/lib/generates/internal/SdkTypeProgrammer.js +96 -12
  162. package/lib/generates/internal/SdkTypeProgrammer.js.map +1 -1
  163. package/lib/generates/internal/SdkTypeTagProgrammer.d.ts +36 -3
  164. package/lib/generates/internal/SdkTypeTagProgrammer.js +28 -7
  165. package/lib/generates/internal/SdkTypeTagProgrammer.js.map +1 -1
  166. package/lib/generates/internal/SdkWebSocketCloneProgrammer.d.ts +40 -0
  167. package/lib/generates/internal/SdkWebSocketCloneProgrammer.js +149 -142
  168. package/lib/generates/internal/SdkWebSocketCloneProgrammer.js.map +1 -1
  169. package/lib/generates/internal/SdkWebSocketNamespaceProgrammer.d.ts +19 -0
  170. package/lib/generates/internal/SdkWebSocketNamespaceProgrammer.js +19 -0
  171. package/lib/generates/internal/SdkWebSocketNamespaceProgrammer.js.map +1 -1
  172. package/lib/generates/internal/SdkWebSocketParameterProgrammer.d.ts +81 -2
  173. package/lib/generates/internal/SdkWebSocketParameterProgrammer.js +48 -0
  174. package/lib/generates/internal/SdkWebSocketParameterProgrammer.js.map +1 -1
  175. package/lib/generates/internal/SdkWebSocketRouteProgrammer.d.ts +18 -0
  176. package/lib/generates/internal/SdkWebSocketRouteProgrammer.js +18 -0
  177. package/lib/generates/internal/SdkWebSocketRouteProgrammer.js.map +1 -1
  178. package/lib/generates/internal/SwaggerDescriptionComposer.d.ts +42 -0
  179. package/lib/generates/internal/SwaggerDescriptionComposer.js +44 -1
  180. package/lib/generates/internal/SwaggerDescriptionComposer.js.map +1 -1
  181. package/lib/generates/internal/SwaggerOperationComposer.d.ts +18 -0
  182. package/lib/generates/internal/SwaggerOperationComposer.js +18 -0
  183. package/lib/generates/internal/SwaggerOperationComposer.js.map +1 -1
  184. package/lib/generates/internal/SwaggerOperationParameterComposer.d.ts +39 -0
  185. package/lib/generates/internal/SwaggerOperationParameterComposer.js +31 -8
  186. package/lib/generates/internal/SwaggerOperationParameterComposer.js.map +1 -1
  187. package/lib/generates/internal/SwaggerOperationResponseComposer.d.ts +19 -0
  188. package/lib/generates/internal/SwaggerOperationResponseComposer.js +19 -0
  189. package/lib/generates/internal/SwaggerOperationResponseComposer.js.map +1 -1
  190. package/lib/internal/legacy.d.ts +296 -16
  191. package/lib/internal/legacy.js +127 -10
  192. package/lib/internal/legacy.js.map +1 -1
  193. package/lib/structures/INestiaProject.d.ts +10 -0
  194. package/lib/structures/INestiaSdkInput.d.ts +31 -1
  195. package/lib/structures/IOperationMetadata.d.ts +55 -0
  196. package/lib/structures/IReflectController.d.ts +11 -1
  197. package/lib/structures/IReflectHttpOperation.d.ts +11 -1
  198. package/lib/structures/IReflectHttpOperationException.d.ts +10 -0
  199. package/lib/structures/IReflectHttpOperationParameter.d.ts +47 -0
  200. package/lib/structures/IReflectHttpOperationSuccess.d.ts +11 -0
  201. package/lib/structures/IReflectImport.d.ts +10 -0
  202. package/lib/structures/IReflectMcpOperation.d.ts +19 -0
  203. package/lib/structures/IReflectMcpOperationParameter.d.ts +9 -0
  204. package/lib/structures/IReflectOperationError.d.ts +28 -0
  205. package/lib/structures/IReflectOperationError.js +22 -2
  206. package/lib/structures/IReflectOperationError.js.map +1 -1
  207. package/lib/structures/IReflectType.d.ts +9 -0
  208. package/lib/structures/IReflectWebSocketOperation.d.ts +10 -0
  209. package/lib/structures/IReflectWebSocketOperationParameter.d.ts +55 -0
  210. package/lib/structures/ITypedApplication.d.ts +10 -0
  211. package/lib/structures/ITypedHttpRoute.d.ts +10 -0
  212. package/lib/structures/ITypedHttpRouteException.d.ts +10 -0
  213. package/lib/structures/ITypedHttpRouteParameter.d.ts +45 -0
  214. package/lib/structures/ITypedHttpRouteSuccess.d.ts +10 -0
  215. package/lib/structures/ITypedMcpRoute.d.ts +11 -0
  216. package/lib/structures/ITypedWebSocketRoute.d.ts +10 -0
  217. package/lib/transform.d.ts +6 -0
  218. package/lib/transform.js +6 -0
  219. package/lib/transform.js.map +1 -1
  220. package/lib/utils/ArrayUtil.d.ts +31 -1
  221. package/lib/utils/ArrayUtil.js +32 -11
  222. package/lib/utils/ArrayUtil.js.map +1 -1
  223. package/lib/utils/EmittedJavaScriptPatcher.d.ts +20 -0
  224. package/lib/utils/EmittedJavaScriptPatcher.js +65 -46
  225. package/lib/utils/EmittedJavaScriptPatcher.js.map +1 -1
  226. package/lib/utils/FileRetriever.d.ts +29 -0
  227. package/lib/utils/FileRetriever.js +29 -0
  228. package/lib/utils/FileRetriever.js.map +1 -1
  229. package/lib/utils/HttpResponseContentTypeUtil.d.ts +41 -0
  230. package/lib/utils/HttpResponseContentTypeUtil.js +31 -0
  231. package/lib/utils/HttpResponseContentTypeUtil.js.map +1 -1
  232. package/lib/utils/MapUtil.d.ts +64 -1
  233. package/lib/utils/MapUtil.js +24 -3
  234. package/lib/utils/MapUtil.js.map +1 -1
  235. package/lib/utils/PathUtil.d.ts +31 -0
  236. package/lib/utils/PathUtil.js +38 -0
  237. package/lib/utils/PathUtil.js.map +1 -1
  238. package/lib/utils/SdkBundlePath.d.ts +2 -0
  239. package/lib/utils/SdkBundlePath.js +10 -0
  240. package/lib/utils/SdkBundlePath.js.map +1 -0
  241. package/lib/utils/SdkInputFilter.d.ts +31 -0
  242. package/lib/utils/SdkInputFilter.js +115 -0
  243. package/lib/utils/SdkInputFilter.js.map +1 -0
  244. package/lib/utils/SourceFinder.d.ts +35 -0
  245. package/lib/utils/SourceFinder.js +47 -12
  246. package/lib/utils/SourceFinder.js.map +1 -1
  247. package/lib/utils/StringUtil.d.ts +77 -2
  248. package/lib/utils/StringUtil.js +166 -4
  249. package/lib/utils/StringUtil.js.map +1 -1
  250. package/lib/utils/TemporaryDirectory.d.ts +60 -0
  251. package/lib/utils/TemporaryDirectory.js +112 -0
  252. package/lib/utils/TemporaryDirectory.js.map +1 -0
  253. package/lib/utils/TsConfigReader.d.ts +42 -0
  254. package/lib/utils/TsConfigReader.js +98 -14
  255. package/lib/utils/TsConfigReader.js.map +1 -1
  256. package/lib/utils/TtscExecutor.d.ts +23 -1
  257. package/lib/utils/TtscExecutor.js +22 -0
  258. package/lib/utils/TtscExecutor.js.map +1 -1
  259. package/lib/utils/VersioningStrategy.d.ts +27 -2
  260. package/lib/utils/VersioningStrategy.js +30 -9
  261. package/lib/utils/VersioningStrategy.js.map +1 -1
  262. package/lib/validators/TextPlainValidator.d.ts +19 -0
  263. package/lib/validators/TextPlainValidator.js +19 -0
  264. package/lib/validators/TextPlainValidator.js.map +1 -1
  265. package/native/go.mod +1 -1
  266. package/native/go.sum +2 -2
  267. package/native/sdk/register.go +12 -2
  268. package/native/sdk/sdk_metadata_json.go +6 -1
  269. package/native/sdk/sdk_transform.go +393 -403
  270. package/package.json +9 -7
  271. package/src/INestiaConfig.ts +55 -24
  272. package/src/NestiaSdkApplication.ts +66 -7
  273. package/src/NestiaSwaggerComposer.ts +21 -6
  274. package/src/analyses/AccessorAnalyzer.ts +26 -0
  275. package/src/analyses/ConfigAnalyzer.ts +59 -96
  276. package/src/analyses/ImportAnalyzer.ts +25 -0
  277. package/src/analyses/ParameterNameAnalyzer.ts +24 -0
  278. package/src/analyses/PathAnalyzer.ts +63 -11
  279. package/src/analyses/ReflectControllerAnalyzer.ts +32 -0
  280. package/src/analyses/ReflectHttpOperationAnalyzer.ts +32 -10
  281. package/src/analyses/ReflectHttpOperationExceptionAnalyzer.ts +31 -0
  282. package/src/analyses/ReflectHttpOperationParameterAnalyzer.ts +31 -0
  283. package/src/analyses/ReflectHttpOperationResponseAnalyzer.ts +32 -0
  284. package/src/analyses/ReflectMcpOperationAnalyzer.ts +32 -1
  285. package/src/analyses/ReflectMetadataAnalyzer.ts +48 -1
  286. package/src/analyses/ReflectWebSocketOperationAnalyzer.ts +34 -14
  287. package/src/analyses/SecurityAnalyzer.ts +15 -0
  288. package/src/analyses/SwaggerExampleAnalyzer.ts +16 -0
  289. package/src/analyses/TypedHttpRouteAnalyzer.ts +240 -184
  290. package/src/analyses/TypedMcpRouteAnalyzer.ts +180 -20
  291. package/src/analyses/TypedWebSocketRouteAnalyzer.ts +19 -0
  292. package/src/decorators/OperationMetadata.ts +6 -0
  293. package/src/executable/internal/CommandParser.ts +19 -0
  294. package/src/executable/internal/NestiaConfigLoader.ts +66 -50
  295. package/src/executable/internal/NestiaSdkCommand.ts +96 -3
  296. package/src/executable/internal/NestiaSdkWatcher.ts +169 -41
  297. package/src/executable/internal/NestiaSwaggerWatch.ts +359 -0
  298. package/src/factories/ExpressionFactory.ts +17 -2
  299. package/src/factories/IdentifierFactory.ts +24 -0
  300. package/src/factories/LiteralFactory.ts +44 -11
  301. package/src/factories/StatementFactory.ts +28 -1
  302. package/src/factories/TypeFactory.ts +24 -0
  303. package/src/generates/CloneGenerator.ts +26 -5
  304. package/src/generates/E2eGenerator.ts +19 -0
  305. package/src/generates/SdkGenerator.ts +40 -9
  306. package/src/generates/SwaggerGenerator.ts +56 -14
  307. package/src/generates/internal/E2eFileProgrammer.ts +20 -0
  308. package/src/generates/internal/FilePrinter.ts +43 -0
  309. package/src/generates/internal/ImportDictionary.ts +110 -3
  310. package/src/generates/internal/SdkAliasCollection.ts +133 -11
  311. package/src/generates/internal/SdkDistributionComposer.ts +117 -66
  312. package/src/generates/internal/SdkFileProgrammer.ts +18 -0
  313. package/src/generates/internal/SdkHttpCloneProgrammer.ts +55 -0
  314. package/src/generates/internal/SdkHttpCloneReferencer.ts +97 -23
  315. package/src/generates/internal/SdkHttpFunctionProgrammer.ts +19 -0
  316. package/src/generates/internal/SdkHttpNamespaceProgrammer.ts +19 -0
  317. package/src/generates/internal/SdkHttpParameterProgrammer.ts +104 -2
  318. package/src/generates/internal/SdkHttpRouteProgrammer.ts +20 -0
  319. package/src/generates/internal/SdkHttpSimulationProgrammer.ts +72 -5
  320. package/src/generates/internal/SdkImportWizard.ts +63 -0
  321. package/src/generates/internal/SdkMcpRouteProgrammer.ts +38 -18
  322. package/src/generates/internal/SdkPathTemplate.ts +15 -0
  323. package/src/generates/internal/SdkRouteDirectory.ts +10 -0
  324. package/src/generates/internal/SdkTypeProgrammer.ts +118 -14
  325. package/src/generates/internal/SdkTypeTagProgrammer.ts +37 -7
  326. package/src/generates/internal/SdkWebSocketCloneProgrammer.ts +185 -142
  327. package/src/generates/internal/SdkWebSocketNamespaceProgrammer.ts +19 -0
  328. package/src/generates/internal/SdkWebSocketParameterProgrammer.ts +81 -2
  329. package/src/generates/internal/SdkWebSocketRouteProgrammer.ts +18 -0
  330. package/src/generates/internal/SwaggerDescriptionComposer.ts +47 -1
  331. package/src/generates/internal/SwaggerOperationComposer.ts +18 -0
  332. package/src/generates/internal/SwaggerOperationParameterComposer.ts +41 -8
  333. package/src/generates/internal/SwaggerOperationResponseComposer.ts +19 -0
  334. package/src/internal/legacy-augmentation.d.ts +16 -0
  335. package/src/internal/legacy.ts +296 -26
  336. package/src/structures/INestiaProject.ts +10 -0
  337. package/src/structures/INestiaSdkInput.ts +31 -1
  338. package/src/structures/IOperationMetadata.ts +55 -0
  339. package/src/structures/IReflectController.ts +11 -1
  340. package/src/structures/IReflectHttpOperation.ts +11 -1
  341. package/src/structures/IReflectHttpOperationException.ts +10 -0
  342. package/src/structures/IReflectHttpOperationParameter.ts +47 -0
  343. package/src/structures/IReflectHttpOperationSuccess.ts +11 -0
  344. package/src/structures/IReflectImport.ts +10 -0
  345. package/src/structures/IReflectMcpOperation.ts +19 -0
  346. package/src/structures/IReflectMcpOperationParameter.ts +9 -0
  347. package/src/structures/IReflectOperationError.ts +31 -2
  348. package/src/structures/IReflectType.ts +9 -0
  349. package/src/structures/IReflectWebSocketOperation.ts +10 -0
  350. package/src/structures/IReflectWebSocketOperationParameter.ts +55 -0
  351. package/src/structures/ITypedApplication.ts +10 -0
  352. package/src/structures/ITypedHttpRoute.ts +10 -0
  353. package/src/structures/ITypedHttpRouteException.ts +10 -0
  354. package/src/structures/ITypedHttpRouteParameter.ts +45 -0
  355. package/src/structures/ITypedHttpRouteSuccess.ts +10 -0
  356. package/src/structures/ITypedMcpRoute.ts +12 -0
  357. package/src/structures/ITypedWebSocketRoute.ts +10 -0
  358. package/src/transform.ts +6 -0
  359. package/src/utils/ArrayUtil.ts +32 -13
  360. package/src/utils/EmittedJavaScriptPatcher.ts +70 -47
  361. package/src/utils/FileRetriever.ts +29 -0
  362. package/src/utils/HttpResponseContentTypeUtil.ts +41 -0
  363. package/src/utils/MapUtil.ts +68 -3
  364. package/src/utils/PathUtil.ts +38 -0
  365. package/src/utils/SdkBundlePath.ts +11 -0
  366. package/src/utils/SdkInputFilter.ts +108 -0
  367. package/src/utils/SourceFinder.ts +51 -14
  368. package/src/utils/StringUtil.ts +182 -5
  369. package/src/utils/TemporaryDirectory.ts +108 -0
  370. package/src/utils/TsConfigReader.ts +124 -26
  371. package/src/utils/TtscExecutor.ts +23 -1
  372. package/src/utils/VersioningStrategy.ts +37 -14
  373. package/src/validators/TextPlainValidator.ts +19 -0
  374. package/lib/generates/internal/SwaggerReadonlyArrayEmender.d.ts +0 -9
  375. package/lib/generates/internal/SwaggerReadonlyArrayEmender.js +0 -178
  376. package/lib/generates/internal/SwaggerReadonlyArrayEmender.js.map +0 -1
  377. package/src/generates/internal/SwaggerReadonlyArrayEmender.ts +0 -264
@@ -2,8 +2,34 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AccessorAnalyzer = void 0;
4
4
  const utils_1 = require("@typia/utils");
5
+ /**
6
+ * Assigns each route the accessor path under which the generated SDK exposes
7
+ * it.
8
+ *
9
+ * @evidence contracts/common.md#principled-implementation The accessors are shrunk where a name repeats, escaped into valid unique identifiers, shrunk again, and each route is renamed to its last accessor segment.
10
+ * @evidence contracts/common.md#clear-and-simple-design One public function over three private passes.
11
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The passes follow the accessor structure and no route or controller name is special-cased.
12
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
13
+ * efficient algorithms: For R routes of at most D accessor segments, the prefix maps avoid repeated route-to-route searches. Prefix slicing and joining costs O(R D²) character work before collision escapes; collisions add probes and longer names. Two shrink passes are required around escaping because escaping changes the names being shrunk.
14
+ * reuse equivalent work: This invocation computes its own result and coordinates no completed or in-flight computation across requests.
15
+ * bound retention and release resources: This operation owns only invocation-local values, with no retained cache, handle or background task.
16
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation AccessorAnalyzer analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
17
+ */
5
18
  var AccessorAnalyzer;
6
19
  (function (AccessorAnalyzer) {
20
+ /**
21
+ * Rewrites the accessor of every route in place so that accessors are valid,
22
+ * unique, and as short as they can be.
23
+ *
24
+ * @evidence contracts/common.md#principled-implementation Segments that repeat their parent are removed when no sibling shares the parent, non-identifier characters become underscores, a segment that collides with an existing accessor gets an underscore prefix, and the route name becomes the last segment.
25
+ * @evidence contracts/common.md#clear-and-simple-design One function that runs the passes in a fixed order.
26
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The rules apply to every route, and reserved names are computed from the routes themselves.
27
+ * @evidence contracts/common.md#meaningful-documentation The comment states the passes and the in-place rewrite.
28
+ * efficient algorithms: For R routes of at most D accessor segments, the prefix maps avoid repeated route-to-route searches. Prefix slicing and joining costs O(R D²) character work before collision escapes; collisions add probes and longer names. Two shrink passes are required around escaping because escaping changes the names being shrunk.
29
+ * reuse equivalent work: This invocation computes its own result and coordinates no completed or in-flight computation across requests.
30
+ * bound retention and release resources: This operation owns only invocation-local values, with no retained cache, handle or background task.
31
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation AccessorAnalyzer.analyze analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
32
+ */
7
33
  AccessorAnalyzer.analyze = (routes) => {
8
34
  var _b;
9
35
  shrink(routes);
@@ -1 +1 @@
1
- {"version":3,"file":"AccessorAnalyzer.js","sourceRoot":"","sources":["../../src/analyses/AccessorAnalyzer.ts"],"names":[],"mappings":";;;AAAA,wCAAgD;AAQhD,IAAiB,gBAAgB,CAoFhC;AApFD,WAAiB,gBAAgB;IAClB,wBAAO,GAAG,CAAC,MAAuB,EAAE,EAAE;;QACjD,MAAM,CAAC,MAAM,CAAC,CAAC;QACf,QAAQ,CAAC,MAAM,CAAC,CAAC;QACjB,MAAM,CAAC,MAAM,CAAC,CAAC;QACf,KAAK,MAAM,CAAC,IAAI,MAAM;YAAE,CAAC,CAAC,IAAI,SAAG,CAAC,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,mCAAI,CAAC,CAAC,IAAI,CAAC;IAC/D,CAAC,CAAC;IAEF,MAAM,OAAO,GAAG,CAAC,SAA0B,EAAuB,EAAE;QAClE,MAAM,IAAI,GAAwB,IAAI,GAAG,EAAE,CAAC;QAC5C,KAAK,MAAM,KAAK,IAAI,SAAS;YAC3B,KAAK,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,EAAE;;gBAC/B,MAAM,GAAG,GAAW,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;gBAC7D,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,OAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,mCAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;YAC1C,CAAC,CAAC,CAAC;QACL,OAAO,IAAI,CAAC;IACd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from "@nestjs/common";
2
2
  import { INestiaConfig } from "../INestiaConfig";
3
3
  import { INestiaSdkInput } from "../structures/INestiaSdkInput";
4
+ /**
5
+ * Finds the controllers a configuration names, either by compiling and
6
+ * importing sources or by reading a running application.
7
+ *
8
+ * @evidence contracts/common.md#principled-implementation Sources are compiled once through ttsc into a temporary directory, imported, and the exports that carry the Nest `path` metadata are the controllers; an application is read from its module container; results are memoized per configuration object in a weakly keyed map, so a configuration the watcher reloads releases its entry with the object.
9
+ * @evidence contracts/common.md#clear-and-simple-design Two public functions and a private runtime compiler; the output-specific bundle filter comes from SdkInputFilter and configuration/runtime materializations share the owned-child cleanup registry.
10
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The generated SDK's own files are excluded from the input by the bundle list of the SDK, not by name, and the container is read through internals, as noted at `application`.
11
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
12
+ * efficient algorithms: Discovery traverses candidate files once, compiles one runtime project and inspects every exported value; work scales with source/compiler input and export population. Application input instead traverses container controllers and resolves each unique class location.
13
+ * reuse equivalent work: The promise cache shares concurrent and completed analyses for the same config object. It assumes that object, its input sources and application state remain unchanged during its lifetime; callers must supply a fresh config object after changes. Bundle exclusion shares only installed asset descriptions and derives native/realpath roots separately for each output; distinct outputs never reuse one captured prefix.
14
+ * bound retention and release resources: The weakly keyed input map does not retain released config objects, but emitted directories are registered until owned generation cleanup or process exit. Imported CommonJS/ESM modules remain in the hosting Node loader; direct programmatic callers have no per-generation unload guarantee. CLI watch generations isolate this state in a short-lived child.
15
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
16
+ */
4
17
  export declare namespace ConfigAnalyzer {
18
+ /**
19
+ * Returns the analyzed input of a configuration: the controllers with their
20
+ * files and the global prefix and versioning options.
21
+ *
22
+ * The result is cached per configuration object.
23
+ *
24
+ * @evidence contracts/common.md#principled-implementation A function input is asked for the application and read as a running app; otherwise the matched TypeScript sources are compiled and imported, and the memo stores the promise so concurrent callers share one compilation.
25
+ * @evidence contracts/common.md#clear-and-simple-design One function delegating to `application` or to the runtime compiler.
26
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The cache is keyed by the identity of the configuration object, so a different or reloaded configuration object is never served another's result; one object keeps its first result, which is the contract of a configuration that is not mutated between generations.
27
+ * @evidence contracts/common.md#meaningful-documentation The comment states the two input forms and the caching.
28
+ * efficient algorithms: Discovery traverses candidate files once, compiles one runtime project and inspects every exported value; work scales with source/compiler input and export population. Application input instead traverses container controllers and resolves each unique class location.
29
+ * reuse equivalent work: The promise cache shares concurrent and completed analyses for the same config object. It assumes that object, its input sources and application state remain unchanged during its lifetime; callers must supply a fresh config object after changes. Bundle exclusion shares only installed asset descriptions and derives native/realpath roots separately for each output; distinct outputs never reuse one captured prefix.
30
+ * bound retention and release resources: The weakly keyed input map does not retain released config objects, but emitted directories are registered until owned generation cleanup or process exit. Imported CommonJS/ESM modules remain in the hosting Node loader; direct programmatic callers have no per-generation unload guarantee. CLI watch generations isolate this state in a short-lived child.
31
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
32
+ */
5
33
  const input: (config: INestiaConfig) => Promise<INestiaSdkInput>;
34
+ /**
35
+ * Reads the controllers, the global prefix, and the versioning options of a
36
+ * running NestJS application.
37
+ *
38
+ * @evidence contracts/common.md#principled-implementation The controllers come from the module container with their module paths, their files from the location of each class, decoded from the `file:` URL, and the prefix and versioning options from the application's configuration.
39
+ * @evidence contracts/common.md#clear-and-simple-design One function.
40
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts NestJS exposes no public accessor for the container or the configuration, so the function reads `app.container` and `app.config`; this is the one foreign-internal read of the package and stays a stated limit.
41
+ * @evidence contracts/common.md#meaningful-documentation The comment states what is read.
42
+ * efficient algorithms: The container is traversed once and a hash map groups each class with its module prefixes, so location lookup occurs once per unique controller class.
43
+ * reuse equivalent work: This invocation computes its own result and coordinates no completed or in-flight computation across requests.
44
+ * bound retention and release resources: The invocation retains local module/controller collections until it returns. The running application and its controllers remain caller-owned; this reader neither starts nor closes the app.
45
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
46
+ */
6
47
  const application: (app: INestApplication) => Promise<INestiaSdkInput>;
7
48
  }
@@ -21,15 +21,44 @@ const get_function_location_1 = __importDefault(require("get-function-location")
21
21
  const path_1 = __importDefault(require("path"));
22
22
  const tstl_1 = require("tstl");
23
23
  const url_1 = require("url");
24
- const SdkGenerator_1 = require("../generates/SdkGenerator");
25
- const ArrayUtil_1 = require("../utils/ArrayUtil");
26
24
  const EmittedJavaScriptPatcher_1 = require("../utils/EmittedJavaScriptPatcher");
27
25
  const MapUtil_1 = require("../utils/MapUtil");
26
+ const PathUtil_1 = require("../utils/PathUtil");
27
+ const SdkInputFilter_1 = require("../utils/SdkInputFilter");
28
28
  const SourceFinder_1 = require("../utils/SourceFinder");
29
+ const TemporaryDirectory_1 = require("../utils/TemporaryDirectory");
29
30
  const TsConfigReader_1 = require("../utils/TsConfigReader");
30
31
  const TtscExecutor_1 = require("../utils/TtscExecutor");
32
+ /**
33
+ * Finds the controllers a configuration names, either by compiling and
34
+ * importing sources or by reading a running application.
35
+ *
36
+ * @evidence contracts/common.md#principled-implementation Sources are compiled once through ttsc into a temporary directory, imported, and the exports that carry the Nest `path` metadata are the controllers; an application is read from its module container; results are memoized per configuration object in a weakly keyed map, so a configuration the watcher reloads releases its entry with the object.
37
+ * @evidence contracts/common.md#clear-and-simple-design Two public functions and a private runtime compiler; the output-specific bundle filter comes from SdkInputFilter and configuration/runtime materializations share the owned-child cleanup registry.
38
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The generated SDK's own files are excluded from the input by the bundle list of the SDK, not by name, and the container is read through internals, as noted at `application`.
39
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
40
+ * efficient algorithms: Discovery traverses candidate files once, compiles one runtime project and inspects every exported value; work scales with source/compiler input and export population. Application input instead traverses container controllers and resolves each unique class location.
41
+ * reuse equivalent work: The promise cache shares concurrent and completed analyses for the same config object. It assumes that object, its input sources and application state remain unchanged during its lifetime; callers must supply a fresh config object after changes. Bundle exclusion shares only installed asset descriptions and derives native/realpath roots separately for each output; distinct outputs never reuse one captured prefix.
42
+ * bound retention and release resources: The weakly keyed input map does not retain released config objects, but emitted directories are registered until owned generation cleanup or process exit. Imported CommonJS/ESM modules remain in the hosting Node loader; direct programmatic callers have no per-generation unload guarantee. CLI watch generations isolate this state in a short-lived child.
43
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
44
+ */
31
45
  var ConfigAnalyzer;
32
46
  (function (ConfigAnalyzer) {
47
+ /**
48
+ * Returns the analyzed input of a configuration: the controllers with their
49
+ * files and the global prefix and versioning options.
50
+ *
51
+ * The result is cached per configuration object.
52
+ *
53
+ * @evidence contracts/common.md#principled-implementation A function input is asked for the application and read as a running app; otherwise the matched TypeScript sources are compiled and imported, and the memo stores the promise so concurrent callers share one compilation.
54
+ * @evidence contracts/common.md#clear-and-simple-design One function delegating to `application` or to the runtime compiler.
55
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The cache is keyed by the identity of the configuration object, so a different or reloaded configuration object is never served another's result; one object keeps its first result, which is the contract of a configuration that is not mutated between generations.
56
+ * @evidence contracts/common.md#meaningful-documentation The comment states the two input forms and the caching.
57
+ * efficient algorithms: Discovery traverses candidate files once, compiles one runtime project and inspects every exported value; work scales with source/compiler input and export population. Application input instead traverses container controllers and resolves each unique class location.
58
+ * reuse equivalent work: The promise cache shares concurrent and completed analyses for the same config object. It assumes that object, its input sources and application state remain unchanged during its lifetime; callers must supply a fresh config object after changes. Bundle exclusion shares only installed asset descriptions and derives native/realpath roots separately for each output; distinct outputs never reuse one captured prefix.
59
+ * bound retention and release resources: The weakly keyed input map does not retain released config objects, but emitted directories are registered until owned generation cleanup or process exit. Imported CommonJS/ESM modules remain in the hosting Node loader; direct programmatic callers have no per-generation unload guarantee. CLI watch generations isolate this state in a short-lived child.
60
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
61
+ */
33
62
  ConfigAnalyzer.input = (config) => __awaiter(this, void 0, void 0, function* () {
34
63
  return MapUtil_1.MapUtil.take(memory, config, () => __awaiter(this, void 0, void 0, function* () {
35
64
  var _a;
@@ -44,7 +73,7 @@ var ConfigAnalyzer;
44
73
  exclude: typeof config.input === "object" && !Array.isArray(config.input)
45
74
  ? ((_a = config.input.exclude) !== null && _a !== void 0 ? _a : [])
46
75
  : [],
47
- filter: filter(config),
76
+ filter: yield SdkInputFilter_1.SdkInputFilter.create(config.output),
48
77
  });
49
78
  const runtime = yield RuntimeCompiler.compile(sources);
50
79
  const controllers = [];
@@ -67,6 +96,19 @@ var ConfigAnalyzer;
67
96
  };
68
97
  }));
69
98
  });
99
+ /**
100
+ * Reads the controllers, the global prefix, and the versioning options of a
101
+ * running NestJS application.
102
+ *
103
+ * @evidence contracts/common.md#principled-implementation The controllers come from the module container with their module paths, their files from the location of each class, decoded from the `file:` URL, and the prefix and versioning options from the application's configuration.
104
+ * @evidence contracts/common.md#clear-and-simple-design One function.
105
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts NestJS exposes no public accessor for the container or the configuration, so the function reads `app.container` and `app.config`; this is the one foreign-internal read of the package and stays a stated limit.
106
+ * @evidence contracts/common.md#meaningful-documentation The comment states what is read.
107
+ * efficient algorithms: The container is traversed once and a hash map groups each class with its module prefixes, so location lookup occurs once per unique controller class.
108
+ * reuse equivalent work: This invocation computes its own result and coordinates no completed or in-flight computation across requests.
109
+ * bound retention and release resources: The invocation retains local module/controller collections until it returns. The running application and its controllers remain caller-owned; this reader neither starts nor closes the app.
110
+ * @evidence contracts/portability.md#os-neutral-implementation Source/controller identity is obtained from Node path/file-URL conversion, module resolution and native fs. Compiler projects use explicit cwd and native paths; emitted module imports use file URLs. Route prefix/version spelling is kept as protocol text, not treated as filesystem identity.
111
+ */
70
112
  ConfigAnalyzer.application = (app) => __awaiter(this, void 0, void 0, function* () {
71
113
  var _a, _b, _c, _d;
72
114
  var _e, _f, _g, _h, _j;
@@ -84,7 +126,7 @@ var ConfigAnalyzer;
84
126
  const file = (_g = (_a = (yield (0, get_function_location_1.default)(it.first))) === null || _a === void 0 ? void 0 : _a.source) !== null && _g !== void 0 ? _g : null;
85
127
  if (file === null)
86
128
  continue;
87
- const location = normalize_file(file);
129
+ const location = PathUtil_1.PathUtil.location(file);
88
130
  if (location.length === 0)
89
131
  continue;
90
132
  controllers.push({
@@ -113,7 +155,7 @@ var ConfigAnalyzer;
113
155
  };
114
156
  });
115
157
  })(ConfigAnalyzer || (exports.ConfigAnalyzer = ConfigAnalyzer = {}));
116
- const memory = new Map();
158
+ const memory = new WeakMap();
117
159
  class RuntimeCompiler {
118
160
  constructor(cwd, outDir) {
119
161
  this.cwd = cwd;
@@ -121,25 +163,25 @@ class RuntimeCompiler {
121
163
  }
122
164
  static compile(sources) {
123
165
  return __awaiter(this, void 0, void 0, function* () {
124
- var _a;
166
+ var _a, _b;
125
167
  const cwd = process.cwd();
126
168
  const runtimeRoot = path_1.default.join(cwd, "node_modules", ".nestia", "runtime");
127
- yield fs_1.default.promises.mkdir(runtimeRoot, { recursive: true });
128
- ensureRuntimeCleanup(runtimeRoot);
129
- const outDir = yield fs_1.default.promises.mkdtemp(path_1.default.join(runtimeRoot, "run-"));
130
- const project = path_1.default.join(cwd, `.nestia.runtime.${process.pid}.${Date.now()}.json`);
131
- const relative = (file) => path_1.default.relative(cwd, file).split("\\").join("/");
169
+ const outDir = TemporaryDirectory_1.TemporaryDirectory.create(runtimeRoot, "run-");
170
+ // Compiler materializations belong below node_modules with their emitted
171
+ // output. A project file in cwd is itself a watched JSON input and would
172
+ // schedule another generation when this compilation creates/removes it.
173
+ const project = path_1.default.join(outDir, "tsconfig.json");
132
174
  yield fs_1.default.promises.writeFile(project, JSON.stringify({
133
- extends: normalizeProjectPath(process.env.NESTIA_PROJECT),
175
+ extends: path_1.default.resolve(cwd, (_a = process.env.NESTIA_PROJECT) !== null && _a !== void 0 ? _a : "tsconfig.json"),
134
176
  compilerOptions: {
135
177
  noEmit: false,
136
178
  noUnusedLocals: false,
137
179
  noUnusedParameters: false,
138
180
  outDir,
139
181
  plugins: yield runtimePlugins(cwd),
140
- rootDir: ".",
182
+ rootDir: cwd,
141
183
  },
142
- include: sources.map(relative),
184
+ include: sources.map((file) => path_1.default.resolve(cwd, file)),
143
185
  }, null, 2), "utf8");
144
186
  try {
145
187
  TtscExecutor_1.TtscExecutor.run({
@@ -150,7 +192,7 @@ class RuntimeCompiler {
150
192
  }
151
193
  catch (error) {
152
194
  const output = error instanceof Error && "stderr" in error
153
- ? String((_a = error.stderr) !== null && _a !== void 0 ? _a : "")
195
+ ? String((_b = error.stderr) !== null && _b !== void 0 ? _b : "")
154
196
  : "";
155
197
  throw new Error(output || `Failed to compile Nestia runtime inputs.`);
156
198
  }
@@ -167,41 +209,6 @@ class RuntimeCompiler {
167
209
  return emitted;
168
210
  }
169
211
  }
170
- const RUNTIME_ROOTS = new Set();
171
- let RUNTIME_CLEANUP_REGISTERED = false;
172
- const ensureRuntimeCleanup = (runtimeRoot) => {
173
- RUNTIME_ROOTS.add(runtimeRoot);
174
- if (RUNTIME_CLEANUP_REGISTERED === true)
175
- return;
176
- RUNTIME_CLEANUP_REGISTERED = true;
177
- const sweep = () => {
178
- for (const location of RUNTIME_ROOTS)
179
- fs_1.default.rmSync(location, { force: true, recursive: true });
180
- };
181
- process.once("exit", sweep);
182
- // process.once("exit", …) does not fire on SIGINT/SIGTERM. Without these
183
- // handlers a Ctrl-C during codegen leaves `run-*` mkdtemp directories
184
- // behind under node_modules/.nestia/runtime/ until a subsequent clean exit.
185
- // The module-level RUNTIME_CLEANUP_REGISTERED flag above guards against
186
- // re-entrancy within this module; we deliberately do NOT gate on
187
- // `process.listenerCount(signal) > 0` because NestiaConfigLoader's parallel
188
- // sweep registers first, and that gate would skip our registration —
189
- // leaving RUNTIME_ROOTS unswept on Ctrl-C while config-loader cleans up.
190
- // Windows note: `process.kill(pid, "SIGINT")` calls TerminateProcess
191
- // rather than re-raising through the listener queue, so the handler
192
- // cascade documented above only holds on POSIX. On Windows, whichever
193
- // module registers FIRST runs its sweep and the second is skipped —
194
- // RUNTIME_ROOTS cleanup is best-effort there. SIGHUP is a no-op for
195
- // most common code paths on Windows (Node fires it on console-close
196
- // and exits within seconds).
197
- const onSignal = (signal) => {
198
- sweep();
199
- process.kill(process.pid, signal);
200
- };
201
- for (const signal of ["SIGINT", "SIGTERM", "SIGHUP"]) {
202
- process.once(signal, onSignal);
203
- }
204
- };
205
212
  const sdkTransformEnv = () => process.env.NESTIA_SDK_TRANSFORM === undefined
206
213
  ? { NESTIA_SDK_TRANSFORM: "1" }
207
214
  : {};
@@ -243,35 +250,5 @@ const normalizeProjectPath = (project) => {
243
250
  const next = project !== null && project !== void 0 ? project : "tsconfig.json";
244
251
  return path_1.default.isAbsolute(next) || next.startsWith(".") ? next : `./${next}`;
245
252
  };
246
- const normalize_file = (str) => str.substring(str.startsWith("file:///")
247
- ? process.cwd()[0] === "/"
248
- ? 7
249
- : 8
250
- : str.startsWith("file://")
251
- ? 7
252
- : 0);
253
- const filter = (config) => (location) => __awaiter(void 0, void 0, void 0, function* () {
254
- return SourceFinder_1.SourceFinder.isTypeScriptSource(location) &&
255
- (config.output === undefined ||
256
- (location.indexOf(path_1.default.join(config.output, "functional")) === -1 &&
257
- (yield (yield bundler.get(config.output))(location))) === false);
258
- });
259
253
  const dynamicImport = Function("specifier", "return import(specifier);");
260
- const bundler = new tstl_1.Singleton((output) => __awaiter(void 0, void 0, void 0, function* () {
261
- const assets = yield fs_1.default.promises.readdir(SdkGenerator_1.SdkGenerator.BUNDLE_PATH);
262
- const tuples = yield ArrayUtil_1.ArrayUtil.asyncMap(assets, (file) => __awaiter(void 0, void 0, void 0, function* () {
263
- const relative = path_1.default.join(output, file);
264
- const location = path_1.default.join(SdkGenerator_1.SdkGenerator.BUNDLE_PATH, file);
265
- const stats = yield fs_1.default.promises.stat(location);
266
- return new tstl_1.Pair(relative, stats.isDirectory());
267
- }));
268
- return (file) => __awaiter(void 0, void 0, void 0, function* () {
269
- for (const it of tuples)
270
- if (it.second === false && file === it.first)
271
- return true;
272
- else if (it.second === true && file.indexOf(it.first) === 0)
273
- return true;
274
- return false;
275
- });
276
- }));
277
254
  //# sourceMappingURL=ConfigAnalyzer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ConfigAnalyzer.js","sourceRoot":"","sources":["../../src/analyses/ConfigAnalyzer.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,8DAA8D;AAC9D,2CAAkE;AAClE,wDAAuD;AAGvD,4CAAoB;AACpB,kFAAwD;AACxD,gDAAwB;AACxB,+BAAgD;AAChD,6BAAoC;AAGpC,4DAAyD;AAEzD,kDAA+C;AAC/C,gFAA6E;AAC7E,8CAA2C;AAC3C,wDAAqD;AACrD,4DAAyD;AACzD,wDAAqD;AAErD,IAAiB,cAAc,CAoG9B;AApGD,WAAiB,cAAc;IAChB,oBAAK,GAAG,CACnB,MAAqB,EACK,EAAE;QAC5B,OAAO,iBAAO,CAAC,IAAI,CAAC,MAAM,EAAE,MAAM,EAAE,GAAS,EAAE;;YAC7C,IAAI,OAAO,MAAM,CAAC,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AAM,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;AAE1E,MAAM,gBAAgB,GAAG,CAAC,IAAY,EAAE,SAAiB,EAAU,EAAE,CACnE,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,CAAC,OAAO,EAAE,EAAE,CACxC,OAAO,CAAC,WAAW,EAAE,KAAK,MAAM;IAC9B,CAAC,CAAC,MAAM;IACR,CAAC,CAAC,OAAO,CAAC,WAAW,EAAE,KAAK,MAAM;QAChC,CAAC,CAAC,MAAM;QACR,CAAC,CAAC,SAAS,CAChB,CAAC;AAEJ,MAAM,oBAAoB,GAAG,CAAC,OAA2B,EAAU,EAAE;IACnE,MAAM,IAAI,GAAW,OAAO,aAAP,OAAO,cAAP,OAAO,GAAI,eAAe,CAAC;IAChD,OAAO,cAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,IAAI,EAAE,CAAC;AAC5E,CAAC,CAAC;AAEF,MAAM,aAAa,GAAwC,QAAQ,CACjE,WAAW,EACX,2BAA2B,CACW,CAAC"}
@@ -1,4 +1,13 @@
1
1
  import { IReflectImport } from "../structures/IReflectImport";
2
+ /**
3
+ * Helpers for the import lists of routes.
4
+ *
5
+ * @evidence contracts/common.md#principled-implementation The namespace merges the imports collected for one route and keeps a removal notice for the old analysis entry.
6
+ * @evidence contracts/common.md#clear-and-simple-design Two functions.
7
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The merge is generic.
8
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
9
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
10
+ */
2
11
  export declare namespace ImportAnalyzer {
3
12
  /**
4
13
  * @deprecated Removed in the Go-migration cycle. Import metadata is now
@@ -8,7 +17,23 @@ export declare namespace ImportAnalyzer {
8
17
  * `ts.SourceFile` to derive imports should read the metadata delivered
9
18
  * through `Reflect.getMetadata("nestia/OperationMetadata", …)` instead. See
10
19
  * `packages/core/MIGRATION.md`.
20
+ * @evidence contracts/common.md#principled-implementation The function exists only to give an actionable error to a caller of the removed API, and always throws.
21
+ * @evidence contracts/common.md#clear-and-simple-design One statement.
22
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts It reports the removal instead of failing later with a missing function.
23
+ * @evidence contracts/common.md#meaningful-documentation The comment names the replacement.
24
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer.analyze analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
11
25
  */
12
26
  const analyze: () => never;
27
+ /**
28
+ * Merges import records by file: namespace imports and default imports are
29
+ * deduplicated and sorted, and the named elements of every import of a file
30
+ * are combined with their aliases.
31
+ *
32
+ * @evidence contracts/common.md#principled-implementation Imports are grouped by file, each group emits its namespace imports, default imports, and one element list with an alias map for renamed elements, so the same file is imported once per kind.
33
+ * @evidence contracts/common.md#clear-and-simple-design One function over one group merger.
34
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The merge follows the import records, with no file special-cased.
35
+ * @evidence contracts/common.md#meaningful-documentation The comment states the grouping and the merging.
36
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer.merge analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
37
+ */
13
38
  const merge: (imports: IReflectImport[]) => IReflectImport[];
14
39
  }
@@ -2,6 +2,15 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ImportAnalyzer = void 0;
4
4
  const MapUtil_1 = require("../utils/MapUtil");
5
+ /**
6
+ * Helpers for the import lists of routes.
7
+ *
8
+ * @evidence contracts/common.md#principled-implementation The namespace merges the imports collected for one route and keeps a removal notice for the old analysis entry.
9
+ * @evidence contracts/common.md#clear-and-simple-design Two functions.
10
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The merge is generic.
11
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
12
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
13
+ */
5
14
  var ImportAnalyzer;
6
15
  (function (ImportAnalyzer) {
7
16
  /**
@@ -12,12 +21,28 @@ var ImportAnalyzer;
12
21
  * `ts.SourceFile` to derive imports should read the metadata delivered
13
22
  * through `Reflect.getMetadata("nestia/OperationMetadata", …)` instead. See
14
23
  * `packages/core/MIGRATION.md`.
24
+ * @evidence contracts/common.md#principled-implementation The function exists only to give an actionable error to a caller of the removed API, and always throws.
25
+ * @evidence contracts/common.md#clear-and-simple-design One statement.
26
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts It reports the removal instead of failing later with a missing function.
27
+ * @evidence contracts/common.md#meaningful-documentation The comment names the replacement.
28
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer.analyze analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
15
29
  */
16
30
  ImportAnalyzer.analyze = () => {
17
31
  throw new Error("ImportAnalyzer.analyze was removed in @nestia/sdk@next. " +
18
32
  "Imports are now attached by the native transformer; read them from " +
19
33
  "IOperationMetadata.imports (see packages/core/MIGRATION.md).");
20
34
  };
35
+ /**
36
+ * Merges import records by file: namespace imports and default imports are
37
+ * deduplicated and sorted, and the named elements of every import of a file
38
+ * are combined with their aliases.
39
+ *
40
+ * @evidence contracts/common.md#principled-implementation Imports are grouped by file, each group emits its namespace imports, default imports, and one element list with an alias map for renamed elements, so the same file is imported once per kind.
41
+ * @evidence contracts/common.md#clear-and-simple-design One function over one group merger.
42
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The merge follows the import records, with no file special-cased.
43
+ * @evidence contracts/common.md#meaningful-documentation The comment states the grouping and the merging.
44
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ImportAnalyzer.merge analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
45
+ */
21
46
  ImportAnalyzer.merge = (imports) => {
22
47
  // group by files
23
48
  const fileGroups = new Map();
@@ -1 +1 @@
1
- {"version":3,"file":"ImportAnalyzer.js","sourceRoot":"","sources":["../../src/analyses/ImportAnalyzer.ts"],"names":[],"mappings":";;;AACA,8CAA2C;AAE3C,IAAiB,cAAc,CAgG9B;AAhGD,WAAiB,cAAc;IAC7B;;;;;;;;OAQG;IACU,sBAAO,GAAG,GAAU,EAAE;QACjC,MAAM,IAAI,KAAK,CACb,0DAA0D;YACxD,qEAAqE;YACrE,8DAA8D,CACjE,CAAC;IACJ,CAAC,CAAC;IAEW,oBAAK,GAAG,CAAC,OAAyB,EAAoB,EAAE;QACnE,iBAAiB;QACjB,MAAM,UAAU,GAAkC,IAAI,GAAG,EAAE,CAAC;QAC5D,KAAK,MAAM,GAAG,IAAI,OAAO,EAAE,CAAC;YAC1B,MAAM,KAAK,GAAqB,iBAAO,CAAC,IAAI,CAC1C,UAAU,EACV,GAAG,CAAC,IAAI,EACR,GAAG,EAAE,CAAC,EAAE,CACT,CAAC;YACF,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAClB,CAAC;QACD,OAAO,KAAK,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,EAAE,CAAC;aACpC,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,UAAU,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC;aAC7C,IAAI,EAAE,CAAC;IACZ,CAAC,CAAC;IAEF,SAAS,UAAU,CACjB,IAAY,EACZ,OAAyB;;;QAEzB,MAAM,cAAc,GAAqB,KAAK,CAAC,IAAI,CACjD,IAAI,GAAG,CACL,OAAO;aACJ,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,QAAQ,KA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1,4 +1,22 @@
1
+ /**
2
+ * Gives names to parameters that declare none, such as destructured ones.
3
+ *
4
+ * @evidence contracts/common.md#principled-implementation A missing name is derived from the field, camel-cased when it is not an identifier, or from the category, and then made unique against the names already taken.
5
+ * @evidence contracts/common.md#clear-and-simple-design One function, one record type, and one private candidate rule.
6
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The rule is generic.
7
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
8
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ParameterNameAnalyzer analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
9
+ */
1
10
  export declare namespace ParameterNameAnalyzer {
11
+ /**
12
+ * A parameter to name: its current name, its category, and an optional field.
13
+ *
14
+ * @evidence contracts/common.md#principled-implementation The three members are the inputs of the naming rule.
15
+ * @evidence contracts/common.md#clear-and-simple-design A flat record with no behavior.
16
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts It is a type and adds no runtime behavior.
17
+ * @evidence contracts/common.md#meaningful-documentation The comment states what the type describes and the meaning of its members.
18
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ParameterNameAnalyzer.IParameter analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
19
+ */
2
20
  interface IParameter {
3
21
  name: string;
4
22
  category: string;
@@ -15,6 +33,12 @@ export declare namespace ParameterNameAnalyzer {
15
33
  * dropped in camel case, otherwise its category, such as `body` or `query`.
16
34
  * The name yields to every other parameter's, which are the user's and are
17
35
  * kept.
36
+ *
37
+ * @evidence contracts/common.md#principled-implementation The names in use are collected first, and each new name is escaped against them with underscores and added, so the result has no duplicates.
38
+ * @evidence contracts/common.md#clear-and-simple-design One function.
39
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Existing names are never changed.
40
+ * @evidence contracts/common.md#meaningful-documentation The comment states the rule.
41
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ParameterNameAnalyzer.name analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
18
42
  */
19
43
  const name: <T extends IParameter>(parameters: T[]) => T[];
20
44
  }
@@ -3,6 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.ParameterNameAnalyzer = void 0;
4
4
  const utils_1 = require("@typia/utils");
5
5
  const StringUtil_1 = require("../utils/StringUtil");
6
+ /**
7
+ * Gives names to parameters that declare none, such as destructured ones.
8
+ *
9
+ * @evidence contracts/common.md#principled-implementation A missing name is derived from the field, camel-cased when it is not an identifier, or from the category, and then made unique against the names already taken.
10
+ * @evidence contracts/common.md#clear-and-simple-design One function, one record type, and one private candidate rule.
11
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts The rule is generic.
12
+ * @evidence contracts/common.md#meaningful-documentation The comment states its purpose.
13
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ParameterNameAnalyzer analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
14
+ */
6
15
  var ParameterNameAnalyzer;
7
16
  (function (ParameterNameAnalyzer) {
8
17
  /**
@@ -16,6 +25,12 @@ var ParameterNameAnalyzer;
16
25
  * dropped in camel case, otherwise its category, such as `body` or `query`.
17
26
  * The name yields to every other parameter's, which are the user's and are
18
27
  * kept.
28
+ *
29
+ * @evidence contracts/common.md#principled-implementation The names in use are collected first, and each new name is escaped against them with underscores and added, so the result has no duplicates.
30
+ * @evidence contracts/common.md#clear-and-simple-design One function.
31
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Existing names are never changed.
32
+ * @evidence contracts/common.md#meaningful-documentation The comment states the rule.
33
+ * @evidenceExclude contracts/portability.md#os-neutral-implementation ParameterNameAnalyzer.name analyzes reflected route metadata; it does not resolve native file identity or launch a process. Source resolution and file emission belong to their filesystem owners.
19
34
  */
20
35
  ParameterNameAnalyzer.name = (parameters) => {
21
36
  const taken = parameters
@@ -1 +1 @@
1
- {"version":3,"file":"ParameterNameAnal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