@zudojs/core 0.0.1

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 (547) hide show
  1. package/README.md +33 -0
  2. package/dist/.tsbuildinfo +1 -0
  3. package/dist/application/application.d.ts +25 -0
  4. package/dist/application/application.d.ts.map +1 -0
  5. package/dist/application/application.js +86 -0
  6. package/dist/application/application.js.map +1 -0
  7. package/dist/application/applicationContext.context.d.ts +40 -0
  8. package/dist/application/applicationContext.context.d.ts.map +1 -0
  9. package/dist/application/applicationContext.context.js +43 -0
  10. package/dist/application/applicationContext.context.js.map +1 -0
  11. package/dist/application/applicationState.state.d.ts +5 -0
  12. package/dist/application/applicationState.state.d.ts.map +1 -0
  13. package/dist/application/applicationState.state.js +2 -0
  14. package/dist/application/applicationState.state.js.map +1 -0
  15. package/dist/application/index.d.ts +10 -0
  16. package/dist/application/index.d.ts.map +1 -0
  17. package/dist/application/index.js +10 -0
  18. package/dist/application/index.js.map +1 -0
  19. package/dist/configuration/configurationManager.manager.d.ts +68 -0
  20. package/dist/configuration/configurationManager.manager.d.ts.map +1 -0
  21. package/dist/configuration/configurationManager.manager.js +157 -0
  22. package/dist/configuration/configurationManager.manager.js.map +1 -0
  23. package/dist/configuration/core/configuration.d.ts +53 -0
  24. package/dist/configuration/core/configuration.d.ts.map +1 -0
  25. package/dist/configuration/core/configuration.js +206 -0
  26. package/dist/configuration/core/configuration.js.map +1 -0
  27. package/dist/configuration/core/configurationKey.key.d.ts +43 -0
  28. package/dist/configuration/core/configurationKey.key.d.ts.map +1 -0
  29. package/dist/configuration/core/configurationKey.key.js +27 -0
  30. package/dist/configuration/core/configurationKey.key.js.map +1 -0
  31. package/dist/configuration/core/configurationSource.source.d.ts +114 -0
  32. package/dist/configuration/core/configurationSource.source.d.ts.map +1 -0
  33. package/dist/configuration/core/configurationSource.source.js +55 -0
  34. package/dist/configuration/core/configurationSource.source.js.map +1 -0
  35. package/dist/configuration/core/index.d.ts +12 -0
  36. package/dist/configuration/core/index.d.ts.map +1 -0
  37. package/dist/configuration/core/index.js +9 -0
  38. package/dist/configuration/core/index.js.map +1 -0
  39. package/dist/configuration/error/configurationError.error.d.ts +108 -0
  40. package/dist/configuration/error/configurationError.error.d.ts.map +1 -0
  41. package/dist/configuration/error/configurationError.error.js +168 -0
  42. package/dist/configuration/error/configurationError.error.js.map +1 -0
  43. package/dist/configuration/error/configurationRedactor.redactor.d.ts +111 -0
  44. package/dist/configuration/error/configurationRedactor.redactor.d.ts.map +1 -0
  45. package/dist/configuration/error/configurationRedactor.redactor.js +176 -0
  46. package/dist/configuration/error/configurationRedactor.redactor.js.map +1 -0
  47. package/dist/configuration/error/index.d.ts +10 -0
  48. package/dist/configuration/error/index.d.ts.map +1 -0
  49. package/dist/configuration/error/index.js +8 -0
  50. package/dist/configuration/error/index.js.map +1 -0
  51. package/dist/configuration/events/configurationEvents.events.d.ts +174 -0
  52. package/dist/configuration/events/configurationEvents.events.d.ts.map +1 -0
  53. package/dist/configuration/events/configurationEvents.events.js +99 -0
  54. package/dist/configuration/events/configurationEvents.events.js.map +1 -0
  55. package/dist/configuration/events/index.d.ts +8 -0
  56. package/dist/configuration/events/index.d.ts.map +1 -0
  57. package/dist/configuration/events/index.js +7 -0
  58. package/dist/configuration/events/index.js.map +1 -0
  59. package/dist/configuration/index.d.ts +30 -0
  60. package/dist/configuration/index.d.ts.map +1 -0
  61. package/dist/configuration/index.js +29 -0
  62. package/dist/configuration/index.js.map +1 -0
  63. package/dist/configuration/loader/configurationLoader.loader.d.ts +113 -0
  64. package/dist/configuration/loader/configurationLoader.loader.d.ts.map +1 -0
  65. package/dist/configuration/loader/configurationLoader.loader.js +155 -0
  66. package/dist/configuration/loader/configurationLoader.loader.js.map +1 -0
  67. package/dist/configuration/loader/index.d.ts +8 -0
  68. package/dist/configuration/loader/index.d.ts.map +1 -0
  69. package/dist/configuration/loader/index.js +7 -0
  70. package/dist/configuration/loader/index.js.map +1 -0
  71. package/dist/configuration/registry/configurationProvider.provider.d.ts +130 -0
  72. package/dist/configuration/registry/configurationProvider.provider.d.ts.map +1 -0
  73. package/dist/configuration/registry/configurationProvider.provider.js +113 -0
  74. package/dist/configuration/registry/configurationProvider.provider.js.map +1 -0
  75. package/dist/configuration/registry/configurationRegistry.registry.d.ts +143 -0
  76. package/dist/configuration/registry/configurationRegistry.registry.d.ts.map +1 -0
  77. package/dist/configuration/registry/configurationRegistry.registry.js +157 -0
  78. package/dist/configuration/registry/configurationRegistry.registry.js.map +1 -0
  79. package/dist/configuration/registry/index.d.ts +10 -0
  80. package/dist/configuration/registry/index.d.ts.map +1 -0
  81. package/dist/configuration/registry/index.js +8 -0
  82. package/dist/configuration/registry/index.js.map +1 -0
  83. package/dist/configuration/schema/configurationSchema.schema.d.ts +159 -0
  84. package/dist/configuration/schema/configurationSchema.schema.d.ts.map +1 -0
  85. package/dist/configuration/schema/configurationSchema.schema.js +155 -0
  86. package/dist/configuration/schema/configurationSchema.schema.js.map +1 -0
  87. package/dist/configuration/schema/configurationValidation.validator.d.ts +82 -0
  88. package/dist/configuration/schema/configurationValidation.validator.d.ts.map +1 -0
  89. package/dist/configuration/schema/configurationValidation.validator.js +110 -0
  90. package/dist/configuration/schema/configurationValidation.validator.js.map +1 -0
  91. package/dist/configuration/schema/index.d.ts +10 -0
  92. package/dist/configuration/schema/index.d.ts.map +1 -0
  93. package/dist/configuration/schema/index.js +8 -0
  94. package/dist/configuration/schema/index.js.map +1 -0
  95. package/dist/container/container.d.ts +43 -0
  96. package/dist/container/container.d.ts.map +1 -0
  97. package/dist/container/container.js +91 -0
  98. package/dist/container/container.js.map +1 -0
  99. package/dist/container/index.d.ts +8 -0
  100. package/dist/container/index.d.ts.map +1 -0
  101. package/dist/container/index.js +8 -0
  102. package/dist/container/index.js.map +1 -0
  103. package/dist/container/provider.d.ts +28 -0
  104. package/dist/container/provider.d.ts.map +1 -0
  105. package/dist/container/provider.js +2 -0
  106. package/dist/container/provider.js.map +1 -0
  107. package/dist/container/scope.d.ts +24 -0
  108. package/dist/container/scope.d.ts.map +1 -0
  109. package/dist/container/scope.js +2 -0
  110. package/dist/container/scope.js.map +1 -0
  111. package/dist/container/token.d.ts +18 -0
  112. package/dist/container/token.d.ts.map +1 -0
  113. package/dist/container/token.js +10 -0
  114. package/dist/container/token.js.map +1 -0
  115. package/dist/context/core/context.d.ts +95 -0
  116. package/dist/context/core/context.d.ts.map +1 -0
  117. package/dist/context/core/context.js +103 -0
  118. package/dist/context/core/context.js.map +1 -0
  119. package/dist/context/core/contextKey.key.d.ts +60 -0
  120. package/dist/context/core/contextKey.key.d.ts.map +1 -0
  121. package/dist/context/core/contextKey.key.js +58 -0
  122. package/dist/context/core/contextKey.key.js.map +1 -0
  123. package/dist/context/core/executionContext.context.d.ts +131 -0
  124. package/dist/context/core/executionContext.context.d.ts.map +1 -0
  125. package/dist/context/core/executionContext.context.js +81 -0
  126. package/dist/context/core/executionContext.context.js.map +1 -0
  127. package/dist/context/core/index.d.ts +9 -0
  128. package/dist/context/core/index.d.ts.map +1 -0
  129. package/dist/context/core/index.js +9 -0
  130. package/dist/context/core/index.js.map +1 -0
  131. package/dist/context/index.d.ts +8 -0
  132. package/dist/context/index.d.ts.map +1 -0
  133. package/dist/context/index.js +8 -0
  134. package/dist/context/index.js.map +1 -0
  135. package/dist/context/provider/contextProvider.provider.d.ts +61 -0
  136. package/dist/context/provider/contextProvider.provider.d.ts.map +1 -0
  137. package/dist/context/provider/contextProvider.provider.js +44 -0
  138. package/dist/context/provider/contextProvider.provider.js.map +1 -0
  139. package/dist/context/provider/contextStorage.storage.d.ts +54 -0
  140. package/dist/context/provider/contextStorage.storage.d.ts.map +1 -0
  141. package/dist/context/provider/contextStorage.storage.js +74 -0
  142. package/dist/context/provider/contextStorage.storage.js.map +1 -0
  143. package/dist/context/provider/index.d.ts +8 -0
  144. package/dist/context/provider/index.d.ts.map +1 -0
  145. package/dist/context/provider/index.js +8 -0
  146. package/dist/context/provider/index.js.map +1 -0
  147. package/dist/context/snapshot/contextSnapshot.snapshot.d.ts +48 -0
  148. package/dist/context/snapshot/contextSnapshot.snapshot.d.ts.map +1 -0
  149. package/dist/context/snapshot/contextSnapshot.snapshot.js +33 -0
  150. package/dist/context/snapshot/contextSnapshot.snapshot.js.map +1 -0
  151. package/dist/context/snapshot/index.d.ts +8 -0
  152. package/dist/context/snapshot/index.d.ts.map +1 -0
  153. package/dist/context/snapshot/index.js +8 -0
  154. package/dist/context/snapshot/index.js.map +1 -0
  155. package/dist/context/values/contextValues.values.d.ts +84 -0
  156. package/dist/context/values/contextValues.values.d.ts.map +1 -0
  157. package/dist/context/values/contextValues.values.js +120 -0
  158. package/dist/context/values/contextValues.values.js.map +1 -0
  159. package/dist/context/values/index.d.ts +7 -0
  160. package/dist/context/values/index.d.ts.map +1 -0
  161. package/dist/context/values/index.js +7 -0
  162. package/dist/context/values/index.js.map +1 -0
  163. package/dist/contracts/adapter.d.ts +44 -0
  164. package/dist/contracts/adapter.d.ts.map +1 -0
  165. package/dist/contracts/adapter.js +2 -0
  166. package/dist/contracts/adapter.js.map +1 -0
  167. package/dist/contracts/disposable.d.ts +23 -0
  168. package/dist/contracts/disposable.d.ts.map +1 -0
  169. package/dist/contracts/disposable.js +2 -0
  170. package/dist/contracts/disposable.js.map +1 -0
  171. package/dist/contracts/handler.d.ts +32 -0
  172. package/dist/contracts/handler.d.ts.map +1 -0
  173. package/dist/contracts/handler.js +9 -0
  174. package/dist/contracts/handler.js.map +1 -0
  175. package/dist/contracts/index.d.ts +7 -0
  176. package/dist/contracts/index.d.ts.map +1 -0
  177. package/dist/contracts/index.js +7 -0
  178. package/dist/contracts/index.js.map +1 -0
  179. package/dist/errors/errorCode.code.d.ts +78 -0
  180. package/dist/errors/errorCode.code.d.ts.map +1 -0
  181. package/dist/errors/errorCode.code.js +84 -0
  182. package/dist/errors/errorCode.code.js.map +1 -0
  183. package/dist/errors/exceptions.d.ts +52 -0
  184. package/dist/errors/exceptions.d.ts.map +1 -0
  185. package/dist/errors/exceptions.js +125 -0
  186. package/dist/errors/exceptions.js.map +1 -0
  187. package/dist/errors/frameworkError.error.d.ts +51 -0
  188. package/dist/errors/frameworkError.error.d.ts.map +1 -0
  189. package/dist/errors/frameworkError.error.js +54 -0
  190. package/dist/errors/frameworkError.error.js.map +1 -0
  191. package/dist/errors/index.d.ts +10 -0
  192. package/dist/errors/index.d.ts.map +1 -0
  193. package/dist/errors/index.js +9 -0
  194. package/dist/errors/index.js.map +1 -0
  195. package/dist/index.d.ts +30 -0
  196. package/dist/index.d.ts.map +1 -0
  197. package/dist/index.js +75 -0
  198. package/dist/index.js.map +1 -0
  199. package/dist/lifecycle/core/index.d.ts +9 -0
  200. package/dist/lifecycle/core/index.d.ts.map +1 -0
  201. package/dist/lifecycle/core/index.js +9 -0
  202. package/dist/lifecycle/core/index.js.map +1 -0
  203. package/dist/lifecycle/core/lifecycle.d.ts +44 -0
  204. package/dist/lifecycle/core/lifecycle.d.ts.map +1 -0
  205. package/dist/lifecycle/core/lifecycle.js +179 -0
  206. package/dist/lifecycle/core/lifecycle.js.map +1 -0
  207. package/dist/lifecycle/core/lifecycleHook.hook.d.ts +59 -0
  208. package/dist/lifecycle/core/lifecycleHook.hook.d.ts.map +1 -0
  209. package/dist/lifecycle/core/lifecycleHook.hook.js +37 -0
  210. package/dist/lifecycle/core/lifecycleHook.hook.js.map +1 -0
  211. package/dist/lifecycle/core/lifecycleRegistry.registry.d.ts +101 -0
  212. package/dist/lifecycle/core/lifecycleRegistry.registry.d.ts.map +1 -0
  213. package/dist/lifecycle/core/lifecycleRegistry.registry.js +115 -0
  214. package/dist/lifecycle/core/lifecycleRegistry.registry.js.map +1 -0
  215. package/dist/lifecycle/core/lifecycleState.state.d.ts +2 -0
  216. package/dist/lifecycle/core/lifecycleState.state.d.ts.map +1 -0
  217. package/dist/lifecycle/core/lifecycleState.state.js +2 -0
  218. package/dist/lifecycle/core/lifecycleState.state.js.map +1 -0
  219. package/dist/lifecycle/index.d.ts +10 -0
  220. package/dist/lifecycle/index.d.ts.map +1 -0
  221. package/dist/lifecycle/index.js +10 -0
  222. package/dist/lifecycle/index.js.map +1 -0
  223. package/dist/lifecycle/manager/index.d.ts +7 -0
  224. package/dist/lifecycle/manager/index.d.ts.map +1 -0
  225. package/dist/lifecycle/manager/index.js +7 -0
  226. package/dist/lifecycle/manager/index.js.map +1 -0
  227. package/dist/lifecycle/manager/lifecycleManager.manager.d.ts +33 -0
  228. package/dist/lifecycle/manager/lifecycleManager.manager.d.ts.map +1 -0
  229. package/dist/lifecycle/manager/lifecycleManager.manager.js +157 -0
  230. package/dist/lifecycle/manager/lifecycleManager.manager.js.map +1 -0
  231. package/dist/lifecycle/scope/index.d.ts +8 -0
  232. package/dist/lifecycle/scope/index.d.ts.map +1 -0
  233. package/dist/lifecycle/scope/index.js +8 -0
  234. package/dist/lifecycle/scope/index.js.map +1 -0
  235. package/dist/lifecycle/scope/lifecycleScope.scope.d.ts +49 -0
  236. package/dist/lifecycle/scope/lifecycleScope.scope.d.ts.map +1 -0
  237. package/dist/lifecycle/scope/lifecycleScope.scope.js +234 -0
  238. package/dist/lifecycle/scope/lifecycleScope.scope.js.map +1 -0
  239. package/dist/logging/console/consoleLogger.logger.d.ts +59 -0
  240. package/dist/logging/console/consoleLogger.logger.d.ts.map +1 -0
  241. package/dist/logging/console/consoleLogger.logger.js +180 -0
  242. package/dist/logging/console/consoleLogger.logger.js.map +1 -0
  243. package/dist/logging/console/index.d.ts +8 -0
  244. package/dist/logging/console/index.d.ts.map +1 -0
  245. package/dist/logging/console/index.js +8 -0
  246. package/dist/logging/console/index.js.map +1 -0
  247. package/dist/logging/console/loggerFactory.factory.d.ts +45 -0
  248. package/dist/logging/console/loggerFactory.factory.d.ts.map +1 -0
  249. package/dist/logging/console/loggerFactory.factory.js +37 -0
  250. package/dist/logging/console/loggerFactory.factory.js.map +1 -0
  251. package/dist/logging/core/index.d.ts +11 -0
  252. package/dist/logging/core/index.d.ts.map +1 -0
  253. package/dist/logging/core/index.js +11 -0
  254. package/dist/logging/core/index.js.map +1 -0
  255. package/dist/logging/core/logEntry.entry.d.ts +73 -0
  256. package/dist/logging/core/logEntry.entry.d.ts.map +1 -0
  257. package/dist/logging/core/logEntry.entry.js +38 -0
  258. package/dist/logging/core/logEntry.entry.js.map +1 -0
  259. package/dist/logging/core/logLevel.level.d.ts +29 -0
  260. package/dist/logging/core/logLevel.level.d.ts.map +1 -0
  261. package/dist/logging/core/logLevel.level.js +34 -0
  262. package/dist/logging/core/logLevel.level.js.map +1 -0
  263. package/dist/logging/core/logger.d.ts +80 -0
  264. package/dist/logging/core/logger.d.ts.map +1 -0
  265. package/dist/logging/core/logger.js +39 -0
  266. package/dist/logging/core/logger.js.map +1 -0
  267. package/dist/logging/core/loggerContext.context.d.ts +62 -0
  268. package/dist/logging/core/loggerContext.context.d.ts.map +1 -0
  269. package/dist/logging/core/loggerContext.context.js +19 -0
  270. package/dist/logging/core/loggerContext.context.js.map +1 -0
  271. package/dist/logging/core/loggerOptions.options.d.ts +69 -0
  272. package/dist/logging/core/loggerOptions.options.d.ts.map +1 -0
  273. package/dist/logging/core/loggerOptions.options.js +10 -0
  274. package/dist/logging/core/loggerOptions.options.js.map +1 -0
  275. package/dist/logging/index.d.ts +8 -0
  276. package/dist/logging/index.d.ts.map +1 -0
  277. package/dist/logging/index.js +8 -0
  278. package/dist/logging/index.js.map +1 -0
  279. package/dist/modules/index.d.ts +20 -0
  280. package/dist/modules/index.d.ts.map +1 -0
  281. package/dist/modules/index.js +52 -0
  282. package/dist/modules/index.js.map +1 -0
  283. package/dist/modules/module.d.ts +171 -0
  284. package/dist/modules/module.d.ts.map +1 -0
  285. package/dist/modules/module.js +99 -0
  286. package/dist/modules/module.js.map +1 -0
  287. package/dist/modules/moduleContext.context.d.ts +170 -0
  288. package/dist/modules/moduleContext.context.d.ts.map +1 -0
  289. package/dist/modules/moduleContext.context.js +82 -0
  290. package/dist/modules/moduleContext.context.js.map +1 -0
  291. package/dist/modules/moduleDefinition.definition.d.ts +112 -0
  292. package/dist/modules/moduleDefinition.definition.d.ts.map +1 -0
  293. package/dist/modules/moduleDefinition.definition.js +101 -0
  294. package/dist/modules/moduleDefinition.definition.js.map +1 -0
  295. package/dist/modules/moduleDependency/index.d.ts +10 -0
  296. package/dist/modules/moduleDependency/index.d.ts.map +1 -0
  297. package/dist/modules/moduleDependency/index.js +10 -0
  298. package/dist/modules/moduleDependency/index.js.map +1 -0
  299. package/dist/modules/moduleDependency/moduleDependency.graph.d.ts +43 -0
  300. package/dist/modules/moduleDependency/moduleDependency.graph.d.ts.map +1 -0
  301. package/dist/modules/moduleDependency/moduleDependency.graph.js +175 -0
  302. package/dist/modules/moduleDependency/moduleDependency.graph.js.map +1 -0
  303. package/dist/modules/moduleDependency/moduleDependency.ordering.d.ts +38 -0
  304. package/dist/modules/moduleDependency/moduleDependency.ordering.d.ts.map +1 -0
  305. package/dist/modules/moduleDependency/moduleDependency.ordering.js +112 -0
  306. package/dist/modules/moduleDependency/moduleDependency.ordering.js.map +1 -0
  307. package/dist/modules/moduleDependency/moduleDependency.type.d.ts +66 -0
  308. package/dist/modules/moduleDependency/moduleDependency.type.d.ts.map +1 -0
  309. package/dist/modules/moduleDependency/moduleDependency.type.js +2 -0
  310. package/dist/modules/moduleDependency/moduleDependency.type.js.map +1 -0
  311. package/dist/modules/moduleError/index.d.ts +11 -0
  312. package/dist/modules/moduleError/index.d.ts.map +1 -0
  313. package/dist/modules/moduleError/index.js +11 -0
  314. package/dist/modules/moduleError/index.js.map +1 -0
  315. package/dist/modules/moduleError/moduleError.base.d.ts +119 -0
  316. package/dist/modules/moduleError/moduleError.base.d.ts.map +1 -0
  317. package/dist/modules/moduleError/moduleError.base.js +105 -0
  318. package/dist/modules/moduleError/moduleError.base.js.map +1 -0
  319. package/dist/modules/moduleError/moduleError.dependency.d.ts +45 -0
  320. package/dist/modules/moduleError/moduleError.dependency.d.ts.map +1 -0
  321. package/dist/modules/moduleError/moduleError.dependency.js +55 -0
  322. package/dist/modules/moduleError/moduleError.dependency.js.map +1 -0
  323. package/dist/modules/moduleError/moduleError.helpers.d.ts +22 -0
  324. package/dist/modules/moduleError/moduleError.helpers.d.ts.map +1 -0
  325. package/dist/modules/moduleError/moduleError.helpers.js +32 -0
  326. package/dist/modules/moduleError/moduleError.helpers.js.map +1 -0
  327. package/dist/modules/moduleError/moduleError.lifecycle.d.ts +61 -0
  328. package/dist/modules/moduleError/moduleError.lifecycle.d.ts.map +1 -0
  329. package/dist/modules/moduleError/moduleError.lifecycle.js +107 -0
  330. package/dist/modules/moduleError/moduleError.lifecycle.js.map +1 -0
  331. package/dist/modules/moduleError/moduleError.registration.d.ts +21 -0
  332. package/dist/modules/moduleError/moduleError.registration.d.ts.map +1 -0
  333. package/dist/modules/moduleError/moduleError.registration.js +39 -0
  334. package/dist/modules/moduleError/moduleError.registration.js.map +1 -0
  335. package/dist/modules/moduleLifecycle/index.d.ts +10 -0
  336. package/dist/modules/moduleLifecycle/index.d.ts.map +1 -0
  337. package/dist/modules/moduleLifecycle/index.js +10 -0
  338. package/dist/modules/moduleLifecycle/index.js.map +1 -0
  339. package/dist/modules/moduleLifecycle/moduleLifecycle.lifecycle.d.ts +41 -0
  340. package/dist/modules/moduleLifecycle/moduleLifecycle.lifecycle.d.ts.map +1 -0
  341. package/dist/modules/moduleLifecycle/moduleLifecycle.lifecycle.js +116 -0
  342. package/dist/modules/moduleLifecycle/moduleLifecycle.lifecycle.js.map +1 -0
  343. package/dist/modules/moduleLifecycle/moduleLifecycle.stateMachine.d.ts +21 -0
  344. package/dist/modules/moduleLifecycle/moduleLifecycle.stateMachine.d.ts.map +1 -0
  345. package/dist/modules/moduleLifecycle/moduleLifecycle.stateMachine.js +107 -0
  346. package/dist/modules/moduleLifecycle/moduleLifecycle.stateMachine.js.map +1 -0
  347. package/dist/modules/moduleLifecycle/moduleLifecycle.type.d.ts +94 -0
  348. package/dist/modules/moduleLifecycle/moduleLifecycle.type.d.ts.map +1 -0
  349. package/dist/modules/moduleLifecycle/moduleLifecycle.type.js +11 -0
  350. package/dist/modules/moduleLifecycle/moduleLifecycle.type.js.map +1 -0
  351. package/dist/modules/moduleLoader/index.d.ts +9 -0
  352. package/dist/modules/moduleLoader/index.d.ts.map +1 -0
  353. package/dist/modules/moduleLoader/index.js +9 -0
  354. package/dist/modules/moduleLoader/index.js.map +1 -0
  355. package/dist/modules/moduleLoader/moduleLoader.loader.d.ts +36 -0
  356. package/dist/modules/moduleLoader/moduleLoader.loader.d.ts.map +1 -0
  357. package/dist/modules/moduleLoader/moduleLoader.loader.js +164 -0
  358. package/dist/modules/moduleLoader/moduleLoader.loader.js.map +1 -0
  359. package/dist/modules/moduleLoader/moduleLoader.type.d.ts +57 -0
  360. package/dist/modules/moduleLoader/moduleLoader.type.d.ts.map +1 -0
  361. package/dist/modules/moduleLoader/moduleLoader.type.js +11 -0
  362. package/dist/modules/moduleLoader/moduleLoader.type.js.map +1 -0
  363. package/dist/modules/moduleMetadata.metadata.d.ts +36 -0
  364. package/dist/modules/moduleMetadata.metadata.d.ts.map +1 -0
  365. package/dist/modules/moduleMetadata.metadata.js +105 -0
  366. package/dist/modules/moduleMetadata.metadata.js.map +1 -0
  367. package/dist/modules/moduleRegistry/index.d.ts +8 -0
  368. package/dist/modules/moduleRegistry/index.d.ts.map +1 -0
  369. package/dist/modules/moduleRegistry/index.js +8 -0
  370. package/dist/modules/moduleRegistry/index.js.map +1 -0
  371. package/dist/modules/moduleRegistry/moduleRegistry.registry.d.ts +35 -0
  372. package/dist/modules/moduleRegistry/moduleRegistry.registry.d.ts.map +1 -0
  373. package/dist/modules/moduleRegistry/moduleRegistry.registry.js +155 -0
  374. package/dist/modules/moduleRegistry/moduleRegistry.registry.js.map +1 -0
  375. package/dist/modules/moduleRegistry/moduleRegistry.type.d.ts +134 -0
  376. package/dist/modules/moduleRegistry/moduleRegistry.type.d.ts.map +1 -0
  377. package/dist/modules/moduleRegistry/moduleRegistry.type.js +2 -0
  378. package/dist/modules/moduleRegistry/moduleRegistry.type.js.map +1 -0
  379. package/dist/runtime/index.d.ts +24 -0
  380. package/dist/runtime/index.d.ts.map +1 -0
  381. package/dist/runtime/index.js +42 -0
  382. package/dist/runtime/index.js.map +1 -0
  383. package/dist/runtime/runtime.d.ts +89 -0
  384. package/dist/runtime/runtime.d.ts.map +1 -0
  385. package/dist/runtime/runtime.js +179 -0
  386. package/dist/runtime/runtime.js.map +1 -0
  387. package/dist/runtime/runtimeBootstrap/index.d.ts +10 -0
  388. package/dist/runtime/runtimeBootstrap/index.d.ts.map +1 -0
  389. package/dist/runtime/runtimeBootstrap/index.js +9 -0
  390. package/dist/runtime/runtimeBootstrap/index.js.map +1 -0
  391. package/dist/runtime/runtimeBootstrap/pipeline/index.d.ts +8 -0
  392. package/dist/runtime/runtimeBootstrap/pipeline/index.d.ts.map +1 -0
  393. package/dist/runtime/runtimeBootstrap/pipeline/index.js +8 -0
  394. package/dist/runtime/runtimeBootstrap/pipeline/index.js.map +1 -0
  395. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.invoke.d.ts +6 -0
  396. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.invoke.d.ts.map +1 -0
  397. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.invoke.js +27 -0
  398. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.invoke.js.map +1 -0
  399. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.pipeline.d.ts +19 -0
  400. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.pipeline.d.ts.map +1 -0
  401. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.pipeline.js +107 -0
  402. package/dist/runtime/runtimeBootstrap/pipeline/runtimeBootstrap.pipeline.js.map +1 -0
  403. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.core.d.ts +25 -0
  404. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.core.d.ts.map +1 -0
  405. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.core.js +122 -0
  406. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.core.js.map +1 -0
  407. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.type.d.ts +78 -0
  408. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.type.d.ts.map +1 -0
  409. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.type.js +2 -0
  410. package/dist/runtime/runtimeBootstrap/runtimeBootstrap.type.js.map +1 -0
  411. package/dist/runtime/runtimeContext/index.d.ts +10 -0
  412. package/dist/runtime/runtimeContext/index.d.ts.map +1 -0
  413. package/dist/runtime/runtimeContext/index.js +9 -0
  414. package/dist/runtime/runtimeContext/index.js.map +1 -0
  415. package/dist/runtime/runtimeContext/runtimeContext.core.d.ts +38 -0
  416. package/dist/runtime/runtimeContext/runtimeContext.core.d.ts.map +1 -0
  417. package/dist/runtime/runtimeContext/runtimeContext.core.js +99 -0
  418. package/dist/runtime/runtimeContext/runtimeContext.core.js.map +1 -0
  419. package/dist/runtime/runtimeContext/runtimeContext.factory.d.ts +22 -0
  420. package/dist/runtime/runtimeContext/runtimeContext.factory.d.ts.map +1 -0
  421. package/dist/runtime/runtimeContext/runtimeContext.factory.js +43 -0
  422. package/dist/runtime/runtimeContext/runtimeContext.factory.js.map +1 -0
  423. package/dist/runtime/runtimeContext/runtimeContext.type.d.ts +68 -0
  424. package/dist/runtime/runtimeContext/runtimeContext.type.d.ts.map +1 -0
  425. package/dist/runtime/runtimeContext/runtimeContext.type.js +2 -0
  426. package/dist/runtime/runtimeContext/runtimeContext.type.js.map +1 -0
  427. package/dist/runtime/runtimeEnvironment/detection/index.d.ts +9 -0
  428. package/dist/runtime/runtimeEnvironment/detection/index.d.ts.map +1 -0
  429. package/dist/runtime/runtimeEnvironment/detection/index.js +9 -0
  430. package/dist/runtime/runtimeEnvironment/detection/index.js.map +1 -0
  431. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.detection.d.ts +8 -0
  432. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.detection.d.ts.map +1 -0
  433. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.detection.js +92 -0
  434. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.detection.js.map +1 -0
  435. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.env.d.ts +4 -0
  436. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.env.d.ts.map +1 -0
  437. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.env.js +51 -0
  438. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.env.js.map +1 -0
  439. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.os.d.ts +4 -0
  440. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.os.d.ts.map +1 -0
  441. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.os.js +26 -0
  442. package/dist/runtime/runtimeEnvironment/detection/runtimeEnvironment.os.js.map +1 -0
  443. package/dist/runtime/runtimeEnvironment/index.d.ts +10 -0
  444. package/dist/runtime/runtimeEnvironment/index.d.ts.map +1 -0
  445. package/dist/runtime/runtimeEnvironment/index.js +9 -0
  446. package/dist/runtime/runtimeEnvironment/index.js.map +1 -0
  447. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.core.d.ts +41 -0
  448. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.core.d.ts.map +1 -0
  449. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.core.js +105 -0
  450. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.core.js.map +1 -0
  451. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.type.d.ts +108 -0
  452. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.type.d.ts.map +1 -0
  453. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.type.js +2 -0
  454. package/dist/runtime/runtimeEnvironment/runtimeEnvironment.type.js.map +1 -0
  455. package/dist/runtime/runtimeError/index.d.ts +29 -0
  456. package/dist/runtime/runtimeError/index.d.ts.map +1 -0
  457. package/dist/runtime/runtimeError/index.js +47 -0
  458. package/dist/runtime/runtimeError/index.js.map +1 -0
  459. package/dist/runtime/runtimeError/runtimeError.base.d.ts +30 -0
  460. package/dist/runtime/runtimeError/runtimeError.base.d.ts.map +1 -0
  461. package/dist/runtime/runtimeError/runtimeError.base.js +81 -0
  462. package/dist/runtime/runtimeError/runtimeError.base.js.map +1 -0
  463. package/dist/runtime/runtimeError/runtimeError.lifecycle.d.ts +35 -0
  464. package/dist/runtime/runtimeError/runtimeError.lifecycle.d.ts.map +1 -0
  465. package/dist/runtime/runtimeError/runtimeError.lifecycle.js +77 -0
  466. package/dist/runtime/runtimeError/runtimeError.lifecycle.js.map +1 -0
  467. package/dist/runtime/runtimeError/runtimeError.specialized.d.ts +35 -0
  468. package/dist/runtime/runtimeError/runtimeError.specialized.d.ts.map +1 -0
  469. package/dist/runtime/runtimeError/runtimeError.specialized.js +79 -0
  470. package/dist/runtime/runtimeError/runtimeError.specialized.js.map +1 -0
  471. package/dist/runtime/runtimeError/runtimeError.type.d.ts +74 -0
  472. package/dist/runtime/runtimeError/runtimeError.type.d.ts.map +1 -0
  473. package/dist/runtime/runtimeError/runtimeError.type.js +28 -0
  474. package/dist/runtime/runtimeError/runtimeError.type.js.map +1 -0
  475. package/dist/runtime/runtimeLogger.d.ts +5 -0
  476. package/dist/runtime/runtimeLogger.d.ts.map +1 -0
  477. package/dist/runtime/runtimeLogger.js +18 -0
  478. package/dist/runtime/runtimeLogger.js.map +1 -0
  479. package/dist/runtime/runtimeManager/index.d.ts +12 -0
  480. package/dist/runtime/runtimeManager/index.d.ts.map +1 -0
  481. package/dist/runtime/runtimeManager/index.js +11 -0
  482. package/dist/runtime/runtimeManager/index.js.map +1 -0
  483. package/dist/runtime/runtimeManager/runtimeManager.core.d.ts +31 -0
  484. package/dist/runtime/runtimeManager/runtimeManager.core.d.ts.map +1 -0
  485. package/dist/runtime/runtimeManager/runtimeManager.core.js +136 -0
  486. package/dist/runtime/runtimeManager/runtimeManager.core.js.map +1 -0
  487. package/dist/runtime/runtimeManager/runtimeManager.error.d.ts +14 -0
  488. package/dist/runtime/runtimeManager/runtimeManager.error.d.ts.map +1 -0
  489. package/dist/runtime/runtimeManager/runtimeManager.error.js +21 -0
  490. package/dist/runtime/runtimeManager/runtimeManager.error.js.map +1 -0
  491. package/dist/runtime/runtimeManager/runtimeManager.factory.d.ts +7 -0
  492. package/dist/runtime/runtimeManager/runtimeManager.factory.d.ts.map +1 -0
  493. package/dist/runtime/runtimeManager/runtimeManager.factory.js +8 -0
  494. package/dist/runtime/runtimeManager/runtimeManager.factory.js.map +1 -0
  495. package/dist/runtime/runtimeManager/runtimeManager.lifecycle.d.ts +16 -0
  496. package/dist/runtime/runtimeManager/runtimeManager.lifecycle.d.ts.map +1 -0
  497. package/dist/runtime/runtimeManager/runtimeManager.lifecycle.js +49 -0
  498. package/dist/runtime/runtimeManager/runtimeManager.lifecycle.js.map +1 -0
  499. package/dist/runtime/runtimeManager/runtimeManager.type.d.ts +54 -0
  500. package/dist/runtime/runtimeManager/runtimeManager.type.d.ts.map +1 -0
  501. package/dist/runtime/runtimeManager/runtimeManager.type.js +2 -0
  502. package/dist/runtime/runtimeManager/runtimeManager.type.js.map +1 -0
  503. package/dist/runtime/runtimeOptions/index.d.ts +10 -0
  504. package/dist/runtime/runtimeOptions/index.d.ts.map +1 -0
  505. package/dist/runtime/runtimeOptions/index.js +9 -0
  506. package/dist/runtime/runtimeOptions/index.js.map +1 -0
  507. package/dist/runtime/runtimeOptions/runtimeOptions.defaults.d.ts +6 -0
  508. package/dist/runtime/runtimeOptions/runtimeOptions.defaults.d.ts.map +1 -0
  509. package/dist/runtime/runtimeOptions/runtimeOptions.defaults.js +37 -0
  510. package/dist/runtime/runtimeOptions/runtimeOptions.defaults.js.map +1 -0
  511. package/dist/runtime/runtimeOptions/runtimeOptions.resolver.d.ts +10 -0
  512. package/dist/runtime/runtimeOptions/runtimeOptions.resolver.d.ts.map +1 -0
  513. package/dist/runtime/runtimeOptions/runtimeOptions.resolver.js +80 -0
  514. package/dist/runtime/runtimeOptions/runtimeOptions.resolver.js.map +1 -0
  515. package/dist/runtime/runtimeOptions/runtimeOptions.type.d.ts +94 -0
  516. package/dist/runtime/runtimeOptions/runtimeOptions.type.d.ts.map +1 -0
  517. package/dist/runtime/runtimeOptions/runtimeOptions.type.js +2 -0
  518. package/dist/runtime/runtimeOptions/runtimeOptions.type.js.map +1 -0
  519. package/dist/runtime/runtimeOptions/runtimeOptions.validation.d.ts +26 -0
  520. package/dist/runtime/runtimeOptions/runtimeOptions.validation.d.ts.map +1 -0
  521. package/dist/runtime/runtimeOptions/runtimeOptions.validation.js +59 -0
  522. package/dist/runtime/runtimeOptions/runtimeOptions.validation.js.map +1 -0
  523. package/dist/runtime/runtimeShutdown/index.d.ts +10 -0
  524. package/dist/runtime/runtimeShutdown/index.d.ts.map +1 -0
  525. package/dist/runtime/runtimeShutdown/index.js +9 -0
  526. package/dist/runtime/runtimeShutdown/index.js.map +1 -0
  527. package/dist/runtime/runtimeShutdown/pipeline/index.d.ts +7 -0
  528. package/dist/runtime/runtimeShutdown/pipeline/index.d.ts.map +1 -0
  529. package/dist/runtime/runtimeShutdown/pipeline/index.js +7 -0
  530. package/dist/runtime/runtimeShutdown/pipeline/index.js.map +1 -0
  531. package/dist/runtime/runtimeShutdown/pipeline/runtimeShutdown.pipeline.d.ts +9 -0
  532. package/dist/runtime/runtimeShutdown/pipeline/runtimeShutdown.pipeline.d.ts.map +1 -0
  533. package/dist/runtime/runtimeShutdown/pipeline/runtimeShutdown.pipeline.js +67 -0
  534. package/dist/runtime/runtimeShutdown/pipeline/runtimeShutdown.pipeline.js.map +1 -0
  535. package/dist/runtime/runtimeShutdown/runtimeShutdown.core.d.ts +35 -0
  536. package/dist/runtime/runtimeShutdown/runtimeShutdown.core.d.ts.map +1 -0
  537. package/dist/runtime/runtimeShutdown/runtimeShutdown.core.js +147 -0
  538. package/dist/runtime/runtimeShutdown/runtimeShutdown.core.js.map +1 -0
  539. package/dist/runtime/runtimeShutdown/runtimeShutdown.type.d.ts +74 -0
  540. package/dist/runtime/runtimeShutdown/runtimeShutdown.type.d.ts.map +1 -0
  541. package/dist/runtime/runtimeShutdown/runtimeShutdown.type.js +2 -0
  542. package/dist/runtime/runtimeShutdown/runtimeShutdown.type.js.map +1 -0
  543. package/dist/runtime/runtimeState.state.d.ts +60 -0
  544. package/dist/runtime/runtimeState.state.d.ts.map +1 -0
  545. package/dist/runtime/runtimeState.state.js +157 -0
  546. package/dist/runtime/runtimeState.state.js.map +1 -0
  547. package/package.json +85 -0
@@ -0,0 +1,168 @@
1
+ import { FrameworkError } from "../../errors/frameworkError.error.js";
2
+ import { ErrorCode } from "../../errors/errorCode.code.js";
3
+ /**
4
+ * Base error for all configuration related failures.
5
+ *
6
+ * This gives the configuration subsystem a common error type
7
+ * while still allowing callers to handle more specific errors.
8
+ */
9
+ export class ConfigurationError extends FrameworkError {
10
+ /**
11
+ * Configuration path associated with the error.
12
+ */
13
+ path;
14
+ /**
15
+ * Original error that caused this failure.
16
+ */
17
+ name = "ConfigurationError";
18
+ constructor(code, message, options = {}) {
19
+ super(message, {
20
+ code,
21
+ details: {
22
+ ...(options.details ?? {}),
23
+ ...(options.path
24
+ ? {
25
+ path: options.path,
26
+ }
27
+ : {}),
28
+ },
29
+ cause: options.cause,
30
+ });
31
+ this.name = "ConfigurationError";
32
+ this.path = options.path;
33
+ }
34
+ }
35
+ /**
36
+ * Thrown when configuration loading fails.
37
+ */
38
+ export class ConfigurationSourceError extends ConfigurationError {
39
+ /**
40
+ * Name of the configuration source that failed.
41
+ */
42
+ sourceName;
43
+ /**
44
+ * Type of configuration source.
45
+ */
46
+ sourceType;
47
+ constructor(sourceName, sourceType, cause) {
48
+ const causeMessage = cause instanceof Error ? cause.message : String(cause);
49
+ super(ErrorCode.CONFIGURATION_LOAD_FAILED, `Failed to load configuration source "${sourceName}": ${causeMessage}`, {
50
+ cause,
51
+ details: {
52
+ sourceName,
53
+ sourceType,
54
+ },
55
+ });
56
+ this.name = "ConfigurationSourceError";
57
+ this.sourceName = sourceName;
58
+ this.sourceType = sourceType;
59
+ }
60
+ }
61
+ /**
62
+ * Thrown when a required configuration value is missing.
63
+ */
64
+ export class ConfigurationMissingError extends ConfigurationError {
65
+ constructor(path) {
66
+ super(ErrorCode.CONFIGURATION_REQUIRED, `Required configuration "${path}" is not defined.`, {
67
+ path,
68
+ });
69
+ this.name = "ConfigurationMissingError";
70
+ }
71
+ }
72
+ /**
73
+ * Thrown when a configuration value has an invalid type
74
+ * or otherwise cannot be interpreted correctly.
75
+ */
76
+ export class ConfigurationTypeError extends ConfigurationError {
77
+ /**
78
+ * Expected configuration type.
79
+ */
80
+ expectedType;
81
+ /**
82
+ * Actual configuration type.
83
+ */
84
+ actualType;
85
+ constructor(path, expectedType, value) {
86
+ const actualType = getValueType(value);
87
+ super(ErrorCode.CONFIGURATION_INVALID_TYPE, `Configuration "${path}" must be of type ${expectedType}, received ${actualType}.`, {
88
+ path,
89
+ details: {
90
+ expectedType,
91
+ actualType,
92
+ },
93
+ });
94
+ this.name = "ConfigurationTypeError";
95
+ this.expectedType = expectedType;
96
+ this.actualType = actualType;
97
+ }
98
+ }
99
+ /**
100
+ * Thrown when a configuration value fails schema validation.
101
+ */
102
+ export class ConfigurationSchemaError extends ConfigurationError {
103
+ /**
104
+ * Validation issues associated with the schema.
105
+ */
106
+ issues;
107
+ constructor(path, issues) {
108
+ super(ErrorCode.CONFIGURATION_VALIDATION_FAILED, createSchemaErrorMessage(path, issues), {
109
+ path,
110
+ details: {
111
+ issues,
112
+ },
113
+ });
114
+ this.name = "ConfigurationSchemaError";
115
+ this.issues = [...issues];
116
+ }
117
+ }
118
+ /**
119
+ * Thrown when a configuration source contains
120
+ * duplicate or conflicting definitions that cannot
121
+ * be resolved.
122
+ */
123
+ export class ConfigurationConflictError extends ConfigurationError {
124
+ /**
125
+ * Configuration path where the conflict occurred.
126
+ */
127
+ conflictingPath;
128
+ /**
129
+ * Names of the conflicting sources.
130
+ */
131
+ sources;
132
+ constructor(path, sources) {
133
+ super(ErrorCode.CONFIGURATION_CONFLICT, `Configuration conflict detected for "${path}" between sources: ${sources.join(", ")}.`, {
134
+ path,
135
+ details: {
136
+ sources,
137
+ },
138
+ });
139
+ this.name = "ConfigurationConflictError";
140
+ this.conflictingPath = path;
141
+ this.sources = [...sources];
142
+ }
143
+ }
144
+ /**
145
+ * Creates a safe representation of a configuration value's type.
146
+ */
147
+ function getValueType(value) {
148
+ if (value === null) {
149
+ return "null";
150
+ }
151
+ if (Array.isArray(value)) {
152
+ return "array";
153
+ }
154
+ return typeof value;
155
+ }
156
+ /**
157
+ * Formats schema validation issues.
158
+ */
159
+ function createSchemaErrorMessage(path, issues) {
160
+ if (issues.length === 0) {
161
+ return `Configuration "${path}" failed schema validation.`;
162
+ }
163
+ const details = issues
164
+ .map((issue) => `${issue.path}: ${issue.message}`)
165
+ .join("; ");
166
+ return `Configuration "${path}" failed schema validation: ${details}`;
167
+ }
168
+ //# sourceMappingURL=configurationError.error.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"configurationError.error.js","sourceRoot":"","sources":["../../../src/configuration/error/configurationError.error.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,sCAAsC,CAAC;AAEtE,OAAO,EAAE,SAAS,EAAE,MAAM,gCAAgC,CAAC;AAE3D;;;;;GAKG;AACH,MAAM,OAAO,kBAAmB,SAAQ,cAAc;IACpD;;OAEG;IACa,IAAI,CAAU;IAE9B;;OAEG;IAEa,IAAI,GAAW,oBAAoB,CAAC;IAEpD,YACE,IAAe,EACf,OAAe,EACf,OAAO,GAIH,EAAE;QAEN,KAAK,CAAC,OAAO,EAAE;YACb,IAAI;YACJ,OAAO,EAAE;gBACP,GAAG,CAAC,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;gBAC1B,GAAG,CAAC,OAAO,CAAC,IA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AAO,GAAG,CAAC,GAAG,OAAO,CAAC,CAAC;IAC9B,CAAC;CACF;AAED;;GAEG;AACH,SAAS,YAAY,CAAC,KAAc;IAClC,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACnB,OAAO,MAAM,CAAC;IAChB,CAAC;IAED,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC;QACzB,OAAO,OAAO,CAAC;IACjB,CAAC;IAED,OAAO,OAAO,KAAK,CAAC;AACtB,CAAC;AAED;;GAEG;AACH,SAAS,wBAAwB,CAC/B,IAAY,EACZ,MAA0C;IAE1C,IAAI,MAAM,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACxB,OAAO,kBAAkB,IAAI,6BAA6B,CAAC;IAC7D,CAAC;IAED,MAAM,OAAO,GAAG,MAAM;SACnB,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,GAAG,KAAK,CAAC,IAAI,KAAK,KAAK,CAAC,OAAO,EAAE,CAAC;SACjD,IAAI,CAAC,IAAI,CAAC,CAAC;IAEd,OAAO,kBAAkB,IAAI,+BAA+B,OAAO,EAAE,CAAC;AACxE,CAAC"}
@@ -0,0 +1,111 @@
1
+ import type { Configuration, ConfigurationValue } from "../core/configuration.js";
2
+ /**
3
+ * Default configuration paths and key fragments that should
4
+ * be treated as sensitive.
5
+ *
6
+ * Matching is case-insensitive.
7
+ */
8
+ export declare const DEFAULT_SENSITIVE_PATTERNS: readonly string[];
9
+ /**
10
+ * Default value used when a sensitive configuration value
11
+ * is redacted.
12
+ */
13
+ export declare const DEFAULT_REDACTION_VALUE = "[REDACTED]";
14
+ /**
15
+ * Options for ConfigurationRedactor.
16
+ */
17
+ export interface ConfigurationRedactorOptions {
18
+ /**
19
+ * Additional patterns that should be treated as sensitive.
20
+ */
21
+ readonly sensitivePatterns?: readonly string[];
22
+ /**
23
+ * Exact configuration paths that should be treated
24
+ * as sensitive.
25
+ */
26
+ readonly sensitivePaths?: readonly string[];
27
+ /**
28
+ * Value used when redacting sensitive data.
29
+ *
30
+ * Defaults to "[REDACTED]".
31
+ */
32
+ readonly redactionValue?: string;
33
+ /**
34
+ * Whether nested objects and arrays should be traversed.
35
+ *
36
+ * Defaults to true.
37
+ */
38
+ readonly deep?: boolean;
39
+ }
40
+ /**
41
+ * Result of checking whether a configuration path
42
+ * contains sensitive information.
43
+ */
44
+ export interface ConfigurationSensitivity {
45
+ /**
46
+ * Whether the path is sensitive.
47
+ */
48
+ readonly sensitive: boolean;
49
+ /**
50
+ * Reason the path was classified as sensitive.
51
+ */
52
+ readonly reason?: "pattern" | "exact-path";
53
+ }
54
+ /**
55
+ * Safe representation of configuration.
56
+ */
57
+ export type RedactedConfiguration = ConfigurationValue;
58
+ /**
59
+ * Redacts sensitive configuration values.
60
+ *
61
+ * This class deliberately operates on copies and never mutates
62
+ * the original configuration object.
63
+ */
64
+ export declare class ConfigurationRedactor {
65
+ private readonly sensitivePatterns;
66
+ private readonly sensitivePaths;
67
+ private readonly redactionValue;
68
+ private readonly deep;
69
+ constructor(options?: ConfigurationRedactorOptions);
70
+ /**
71
+ * Determines whether a configuration path is sensitive.
72
+ */
73
+ isSensitive(path: string): boolean;
74
+ /**
75
+ * Provides detailed sensitivity information.
76
+ */
77
+ checkSensitivity(path: string): ConfigurationSensitivity;
78
+ /**
79
+ * Redacts a complete Configuration instance.
80
+ *
81
+ * The returned object is safe to use for logging and
82
+ * diagnostics.
83
+ */
84
+ redact(configuration: Configuration): RedactedConfiguration;
85
+ /**
86
+ * Redacts a plain configuration object.
87
+ */
88
+ redactObject(value: ConfigurationValue): RedactedConfiguration;
89
+ /**
90
+ * Redacts a single configuration value at a known path.
91
+ */
92
+ redactValueAtPath(path: string, value: ConfigurationValue): ConfigurationValue;
93
+ /**
94
+ * Recursively redacts objects and arrays.
95
+ */
96
+ private redactValue;
97
+ /**
98
+ * Checks whether a path segment matches one of the
99
+ * configured sensitive patterns.
100
+ */
101
+ private matchesSensitivePattern;
102
+ }
103
+ /**
104
+ * Creates a ConfigurationRedactor.
105
+ */
106
+ export declare function createConfigurationRedactor(options?: ConfigurationRedactorOptions): ConfigurationRedactor;
107
+ /**
108
+ * Redacts configuration using the default redaction rules.
109
+ */
110
+ export declare function redactConfiguration(configuration: Configuration): RedactedConfiguration;
111
+ //# sourceMappingURL=configurationRedactor.redactor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"configurationRedactor.redactor.d.ts","sourceRoot":"","sources":["../../../src/configuration/error/configurationRedactor.redactor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,kBAAkB,EACnB,MAAM,0BAA0B,CAAC;AAElC;;;;;GAKG;AACH,eAAO,MAAM,0BAA0B,EAAE,SAAS,MAAM,EAevD,CAAC;AAEF;;;GAGG;AACH,eAAO,MAAM,uBAAuB,eAAe,CAAC;AAEpD;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C;;OAEG;IACH,QAAQ,CAAC,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAE/C;;;OAGG;IACH,QAAQ,CAAC,cAAc,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAE5C;;;;OAIG;IACH,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;IAEjC;;;;OAIG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;CACzB;AAED;;;GAGG;AACH,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAE5B;;OAEG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,SAAS,GAAG,YAAY,CAAC;CAC5C;AAED;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,kBAAkB,CAAC;AAEvD;;;;;GAKG;AACH,qBAAa,qBAAqB;IAChC,OAAO,CAAC,QAAQ,CAAC,iBAAiB,CAAoB;IAEtD,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAsB;IAErD,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAS;IAExC,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAU;IAE/B,YAAmB,OAAO,GAAE,4BAAiC,EAa5D;IAED;;OAEG;IACI,WAAW,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAExC;IAED;;OAEG;IACI,gBAAgB,CAAC,IAAI,EAAE,MAAM,GAAG,wBAAwB,CA+B9D;IAED;;;;;OAKG;IACI,MAAM,CAAC,aAAa,EAAE,aAAa,GAAG,qBAAqB,CAEjE;IAED;;OAEG;IACI,YAAY,CAAC,KAAK,EAAE,kBAAkB,GAAG,qBAAqB,CAEpE;IAED;;OAEG;IACI,iBAAiB,CACtB,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,kBAAkB,GACxB,kBAAkB,CAUpB;IAED;;OAEG;IACH,OAAO,CAAC,WAAW;IAkDnB;;;OAGG;IACH,OAAO,CAAC,uBAAuB;CAOhC;AAED;;GAEG;AACH,wBAAgB,2BAA2B,CACzC,OAAO,GAAE,4BAAiC,GACzC,qBAAqB,CAEvB;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CACjC,aAAa,EAAE,aAAa,GAC3B,qBAAqB,CAEvB"}
@@ -0,0 +1,176 @@
1
+ /**
2
+ * Default configuration paths and key fragments that should
3
+ * be treated as sensitive.
4
+ *
5
+ * Matching is case-insensitive.
6
+ */
7
+ export const DEFAULT_SENSITIVE_PATTERNS = [
8
+ "password",
9
+ "passwd",
10
+ "secret",
11
+ "token",
12
+ "access_token",
13
+ "refresh_token",
14
+ "api_key",
15
+ "apikey",
16
+ "private_key",
17
+ "privatekey",
18
+ "client_secret",
19
+ "authorization",
20
+ "credential",
21
+ "credentials",
22
+ ];
23
+ /**
24
+ * Default value used when a sensitive configuration value
25
+ * is redacted.
26
+ */
27
+ export const DEFAULT_REDACTION_VALUE = "[REDACTED]";
28
+ /**
29
+ * Redacts sensitive configuration values.
30
+ *
31
+ * This class deliberately operates on copies and never mutates
32
+ * the original configuration object.
33
+ */
34
+ export class ConfigurationRedactor {
35
+ sensitivePatterns;
36
+ sensitivePaths;
37
+ redactionValue;
38
+ deep;
39
+ constructor(options = {}) {
40
+ this.sensitivePatterns = [
41
+ ...DEFAULT_SENSITIVE_PATTERNS,
42
+ ...(options.sensitivePatterns ?? []),
43
+ ].map((pattern) => normalizePattern(pattern));
44
+ this.sensitivePaths = new Set((options.sensitivePaths ?? []).map((path) => normalizePath(path)));
45
+ this.redactionValue = options.redactionValue ?? DEFAULT_REDACTION_VALUE;
46
+ this.deep = options.deep ?? true;
47
+ }
48
+ /**
49
+ * Determines whether a configuration path is sensitive.
50
+ */
51
+ isSensitive(path) {
52
+ return this.checkSensitivity(path).sensitive;
53
+ }
54
+ /**
55
+ * Provides detailed sensitivity information.
56
+ */
57
+ checkSensitivity(path) {
58
+ const normalizedPath = normalizePath(path);
59
+ if (this.sensitivePaths.has(normalizedPath)) {
60
+ return {
61
+ sensitive: true,
62
+ reason: "exact-path",
63
+ };
64
+ }
65
+ const pathSegments = normalizedPath.split(".");
66
+ for (const segment of pathSegments) {
67
+ if (this.matchesSensitivePattern(segment)) {
68
+ return {
69
+ sensitive: true,
70
+ reason: "pattern",
71
+ };
72
+ }
73
+ }
74
+ if (this.matchesSensitivePattern(normalizedPath)) {
75
+ return {
76
+ sensitive: true,
77
+ reason: "pattern",
78
+ };
79
+ }
80
+ return {
81
+ sensitive: false,
82
+ };
83
+ }
84
+ /**
85
+ * Redacts a complete Configuration instance.
86
+ *
87
+ * The returned object is safe to use for logging and
88
+ * diagnostics.
89
+ */
90
+ redact(configuration) {
91
+ return this.redactValue(configuration.toObject(), "");
92
+ }
93
+ /**
94
+ * Redacts a plain configuration object.
95
+ */
96
+ redactObject(value) {
97
+ return this.redactValue(value, "");
98
+ }
99
+ /**
100
+ * Redacts a single configuration value at a known path.
101
+ */
102
+ redactValueAtPath(path, value) {
103
+ if (this.isSensitive(path)) {
104
+ return this.redactionValue;
105
+ }
106
+ if (!this.deep) {
107
+ return value;
108
+ }
109
+ return this.redactValue(value, path);
110
+ }
111
+ /**
112
+ * Recursively redacts objects and arrays.
113
+ */
114
+ redactValue(value, parentPath) {
115
+ if (value === null || value === undefined) {
116
+ return value;
117
+ }
118
+ if (typeof value === "string" ||
119
+ typeof value === "number" ||
120
+ typeof value === "boolean") {
121
+ if (parentPath && this.isSensitive(parentPath)) {
122
+ return this.redactionValue;
123
+ }
124
+ return value;
125
+ }
126
+ if (Array.isArray(value)) {
127
+ if (!this.deep) {
128
+ return value;
129
+ }
130
+ return value.map((item, index) => this.redactValue(item, parentPath ? `${parentPath}.${index}` : String(index)));
131
+ }
132
+ const result = {};
133
+ for (const [key, childValue] of Object.entries(value)) {
134
+ const path = parentPath ? `${parentPath}.${key}` : key;
135
+ if (this.isSensitive(path)) {
136
+ result[key] = this.redactionValue;
137
+ continue;
138
+ }
139
+ result[key] = this.deep ? this.redactValue(childValue, path) : childValue;
140
+ }
141
+ return result;
142
+ }
143
+ /**
144
+ * Checks whether a path segment matches one of the
145
+ * configured sensitive patterns.
146
+ */
147
+ matchesSensitivePattern(value) {
148
+ const normalized = normalizePattern(value);
149
+ return this.sensitivePatterns.some((pattern) => normalized.includes(pattern));
150
+ }
151
+ }
152
+ /**
153
+ * Creates a ConfigurationRedactor.
154
+ */
155
+ export function createConfigurationRedactor(options = {}) {
156
+ return new ConfigurationRedactor(options);
157
+ }
158
+ /**
159
+ * Redacts configuration using the default redaction rules.
160
+ */
161
+ export function redactConfiguration(configuration) {
162
+ return createConfigurationRedactor().redact(configuration);
163
+ }
164
+ /**
165
+ * Normalizes a configuration path.
166
+ */
167
+ function normalizePath(path) {
168
+ return path.trim().replace(/\s+/g, "").toLowerCase();
169
+ }
170
+ /**
171
+ * Normalizes a sensitivity pattern.
172
+ */
173
+ function normalizePattern(pattern) {
174
+ return pattern.trim().replace(/\s+/g, "").toLowerCase();
175
+ }
176
+ //# sourceMappingURL=configurationRedactor.redactor.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"configurationRedactor.redactor.js","sourceRoot":"","sources":["../../../src/configuration/error/configurationRedactor.redactor.ts"],"names":[],"mappings":"AAKA;;;;;GAKG;AACH,MAAM,CAAC,MAAM,0BAA0B,GAAsB;IAC3D,UAAU;IACV,QAAQ;IACR,QAAQ;IACR,OAAO;IACP,cAAc;IACd,eAAe;IACf,SAAS;IACT,QAAQ;IACR,aAAa;IACb,YAAY;IACZ,eAAe;IACf,eAAe;IACf,YAAY;IACZ,aAAa;CACd,CAAC;AAEF;;;GAGG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,YAAY,CAAC;AAqDpD;;;;;GAKG;AACH,MAAM,OAAO,qBAAqB;IACf,iBAAiB,CAAoB;IAErC,cAAc,CAAsB;IAEpC,cAAc,CAAS;IAEvB,IAAI,CAAU;IAE/B,YAAmB,OAAO,GAAiC,EAAE;QAC3D,IAAI,CAAC,iBAAiB,GAAG;YACvB,GAAG,0BAA0B;YAC7B,GAAG,CAAC,OAAO,CAAC,iBAAiB,IAAI,EAAE,CAAC;SACrC,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC,CAAC;QAE9C,IAAI,CAAC,cAAc,GAAG,IAAI,GAAG,CAC3B,CAAC,OAAO,CAAC,cAAc,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,CAClE,CAAC;QAEF,IAAI,CAAC,cAAc,GAAG,OAAO,CAAC,cAAc,IAAI,uBAAuB,CAAC;QAExE,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,IAAI,IAAI,IAAI,CAAC;IACnC,CAAC;IAED;;OAEG;IACI,WAAW,CAAC,IAAY;QAC7B,OAAO,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,CAAC,SAAS,CAAC;IAC/C,CAAC;IAED;;OAEG;IACI,gBAAgB,CAAC,IAAY;QAClC,MAAM,c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AG,CAAC,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC;QAC5E,CAAC;QAED,OAAO,MAAM,CAAC;IAChB,CAAC;IAED;;;OAGG;IACK,uBAAuB,CAAC,KAAa;QAC3C,MAAM,UAAU,GAAG,gBAAgB,CAAC,KAAK,CAAC,CAAC;QAE3C,OAAO,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAC7C,UAAU,CAAC,QAAQ,CAAC,OAAO,CAAC,CAC7B,CAAC;IACJ,CAAC;CACF;AAED;;GAEG;AACH,MAAM,UAAU,2BAA2B,CACzC,OAAO,GAAiC,EAAE;IAE1C,OAAO,IAAI,qBAAqB,CAAC,OAAO,CAAC,CAAC;AAC5C,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,mBAAmB,CACjC,aAA4B;IAE5B,OAAO,2BAA2B,EAAE,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC;AAC7D,CAAC;AAED;;GAEG;AACH,SAAS,aAAa,CAAC,IAAY;IACjC,OAAO,IAAI,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;AACvD,CAAC;AAED;;GAEG;AACH,SAAS,gBAAgB,CAAC,OAAe;IACvC,OAAO,OAAO,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,WAAW,EAAE,CAAC;AAC1D,CAAC"}
@@ -0,0 +1,10 @@
1
+ /**
2
+ * @zudojs/core/configuration/error
3
+ *
4
+ * Configuration errors and redaction.
5
+ */
6
+ export { ConfigurationError, ConfigurationSourceError, ConfigurationMissingError, ConfigurationTypeError, ConfigurationSchemaError, ConfigurationConflictError, } from "./configurationError.error.js";
7
+ export type { ConfigurationErrorIssue } from "./configurationError.error.js";
8
+ export { ConfigurationRedactor, createConfigurationRedactor, redactConfiguration, DEFAULT_SENSITIVE_PATTERNS, DEFAULT_REDACTION_VALUE, } from "./configurationRedactor.redactor.js";
9
+ export type { ConfigurationRedactorOptions, ConfigurationSensitivity, RedactedConfiguration, } from "./configurationRedactor.redactor.js";
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/configuration/error/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,kBAAkB,EAClB,wBAAwB,EACxB,yBAAyB,EACzB,sBAAsB,EACtB,wBAAwB,EACxB,0BAA0B,GAC3B,MAAM,+BAA+B,CAAC;AAEvC,YAAY,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AAE7E,OAAO,EACL,qBAAqB,EACrB,2BAA2B,EAC3B,mBAAmB,EACnB,0BAA0B,EAC1B,uBAAuB,GACxB,MAAM,qCAAqC,CAAC;AAE7C,YAAY,EACV,4BAA4B,EAC5B,wBAAwB,EACxB,qBAAqB,GACtB,MAAM,qCAAqC,CAAC"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @zudojs/core/configuration/error
3
+ *
4
+ * Configuration errors and redaction.
5
+ */
6
+ export { ConfigurationError, ConfigurationSourceError, ConfigurationMissingError, ConfigurationTypeError, ConfigurationSchemaError, ConfigurationConflictError, } from "./configurationError.error.js";
7
+ export { ConfigurationRedactor, createConfigurationRedactor, redactConfiguration, DEFAULT_SENSITIVE_PATTERNS, DEFAULT_REDACTION_VALUE, } from "./configurationRedactor.redactor.js";
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/configuration/error/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EACL,kBAAkB,EAClB,wBAAwB,EACxB,yBAAyB,EACzB,sBAAsB,EACtB,wBAAwB,EACxB,0BAA0B,GAC3B,MAAM,+BAA+B,CAAC;AAIvC,OAAO,EACL,qBAAqB,EACrB,2BAA2B,EAC3B,mBAAmB,EACnB,0BAA0B,EAC1B,uBAAuB,GACxB,MAAM,qCAAqC,CAAC"}
@@ -0,0 +1,174 @@
1
+ import type { Configuration } from "../core/configuration.js";
2
+ import type { ConfigurationLoadResult } from "../loader/configurationLoader.loader.js";
3
+ import type { ConfigurationValidationReport } from "../schema/configurationValidation.validator.js";
4
+ import type { ConfigurationManagerState } from "../configurationManager.manager.js";
5
+ /**
6
+ * Base contract for all configuration events.
7
+ */
8
+ export interface ConfigurationEvent {
9
+ /**
10
+ * Unique event name.
11
+ */
12
+ readonly type: string;
13
+ /**
14
+ * Time at which the event occurred.
15
+ */
16
+ readonly timestamp: Date;
17
+ /**
18
+ * Configuration manager state associated with the event.
19
+ */
20
+ readonly state: ConfigurationManagerState;
21
+ }
22
+ /**
23
+ * Emitted before configuration initialization begins.
24
+ */
25
+ export interface ConfigurationInitializingEvent extends ConfigurationEvent {
26
+ readonly type: "configuration.initializing";
27
+ }
28
+ /**
29
+ * Emitted after configuration sources have been loaded.
30
+ */
31
+ export interface ConfigurationLoadedEvent extends ConfigurationEvent {
32
+ readonly type: "configuration.loaded";
33
+ /**
34
+ * Result produced by the configuration loader.
35
+ */
36
+ readonly result: ConfigurationLoadResult;
37
+ /**
38
+ * Loaded configuration.
39
+ */
40
+ readonly configuration: Configuration;
41
+ }
42
+ /**
43
+ * Emitted after configuration validation succeeds.
44
+ */
45
+ export interface ConfigurationValidatedEvent extends ConfigurationEvent {
46
+ readonly type: "configuration.validated";
47
+ /**
48
+ * Validation report.
49
+ */
50
+ readonly validation: ConfigurationValidationReport;
51
+ /**
52
+ * Validated configuration.
53
+ */
54
+ readonly configuration: Configuration;
55
+ }
56
+ /**
57
+ * Emitted when configuration initialization completes
58
+ * successfully.
59
+ */
60
+ export interface ConfigurationReadyEvent extends ConfigurationEvent {
61
+ readonly type: "configuration.ready";
62
+ /**
63
+ * Active configuration.
64
+ */
65
+ readonly configuration: Configuration;
66
+ /**
67
+ * Validation report.
68
+ */
69
+ readonly validation: ConfigurationValidationReport;
70
+ }
71
+ /**
72
+ * Emitted when configuration initialization or reload fails.
73
+ */
74
+ export interface ConfigurationFailedEvent extends ConfigurationEvent {
75
+ readonly type: "configuration.failed";
76
+ /**
77
+ * Error that caused the failure.
78
+ */
79
+ readonly error: unknown;
80
+ /**
81
+ * Configuration that was active before the failure,
82
+ * when available.
83
+ */
84
+ readonly previousConfiguration?: Configuration;
85
+ }
86
+ /**
87
+ * Emitted before a configuration reload begins.
88
+ */
89
+ export interface ConfigurationReloadingEvent extends ConfigurationEvent {
90
+ readonly type: "configuration.reloading";
91
+ /**
92
+ * Configuration currently in use.
93
+ */
94
+ readonly previousConfiguration: Configuration;
95
+ }
96
+ /**
97
+ * Emitted after a configuration reload succeeds.
98
+ */
99
+ export interface ConfigurationReloadedEvent extends ConfigurationEvent {
100
+ readonly type: "configuration.reloaded";
101
+ /**
102
+ * Previous configuration.
103
+ */
104
+ readonly previousConfiguration: Configuration;
105
+ /**
106
+ * New active configuration.
107
+ */
108
+ readonly configuration: Configuration;
109
+ /**
110
+ * Load result for the new configuration.
111
+ */
112
+ readonly load: ConfigurationLoadResult;
113
+ /**
114
+ * Validation result for the new configuration.
115
+ */
116
+ readonly validation: ConfigurationValidationReport;
117
+ }
118
+ /**
119
+ * Union of all configuration lifecycle events.
120
+ */
121
+ export type ConfigurationLifecycleEvent = ConfigurationInitializingEvent | ConfigurationLoadedEvent | ConfigurationValidatedEvent | ConfigurationReadyEvent | ConfigurationFailedEvent | ConfigurationReloadingEvent | ConfigurationReloadedEvent;
122
+ /**
123
+ * Configuration event type names.
124
+ */
125
+ export declare const ConfigurationEventType: Readonly<{
126
+ readonly INITIALIZING: "configuration.initializing";
127
+ readonly LOADED: "configuration.loaded";
128
+ readonly VALIDATED: "configuration.validated";
129
+ readonly READY: "configuration.ready";
130
+ readonly FAILED: "configuration.failed";
131
+ readonly RELOADING: "configuration.reloading";
132
+ readonly RELOADED: "configuration.reloaded";
133
+ }>;
134
+ /**
135
+ * Type representing a valid configuration event name.
136
+ */
137
+ export type ConfigurationEventTypeValue = (typeof ConfigurationEventType)[keyof typeof ConfigurationEventType];
138
+ /**
139
+ * Configuration event listener.
140
+ */
141
+ export type ConfigurationEventListener<T extends ConfigurationLifecycleEvent = ConfigurationLifecycleEvent> = (event: T) => void | Promise<void>;
142
+ /**
143
+ * Creates the base metadata shared by configuration events.
144
+ */
145
+ export declare function createConfigurationEventBase(type: string, state: ConfigurationManagerState): ConfigurationEvent;
146
+ /**
147
+ * Creates a configuration initializing event.
148
+ */
149
+ export declare function createConfigurationInitializingEvent(state: ConfigurationManagerState): ConfigurationInitializingEvent;
150
+ /**
151
+ * Creates a configuration loaded event.
152
+ */
153
+ export declare function createConfigurationLoadedEvent(state: ConfigurationManagerState, result: ConfigurationLoadResult): ConfigurationLoadedEvent;
154
+ /**
155
+ * Creates a configuration validated event.
156
+ */
157
+ export declare function createConfigurationValidatedEvent(state: ConfigurationManagerState, configuration: Configuration, validation: ConfigurationValidationReport): ConfigurationValidatedEvent;
158
+ /**
159
+ * Creates a configuration ready event.
160
+ */
161
+ export declare function createConfigurationReadyEvent(state: ConfigurationManagerState, configuration: Configuration, validation: ConfigurationValidationReport): ConfigurationReadyEvent;
162
+ /**
163
+ * Creates a configuration failed event.
164
+ */
165
+ export declare function createConfigurationFailedEvent(state: ConfigurationManagerState, error: unknown, previousConfiguration?: Configuration): ConfigurationFailedEvent;
166
+ /**
167
+ * Creates a configuration reloading event.
168
+ */
169
+ export declare function createConfigurationReloadingEvent(state: ConfigurationManagerState, previousConfiguration: Configuration): ConfigurationReloadingEvent;
170
+ /**
171
+ * Creates a configuration reloaded event.
172
+ */
173
+ export declare function createConfigurationReloadedEvent(state: ConfigurationManagerState, previousConfiguration: Configuration, configuration: Configuration, load: ConfigurationLoadResult, validation: ConfigurationValidationReport): ConfigurationReloadedEvent;
174
+ //# sourceMappingURL=configurationEvents.events.d.ts.map