@cdklabs/cdk-ssm-documents 0.0.55 → 0.0.56

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 (283) hide show
  1. package/.jsii +12 -12
  2. package/lib/construct/synth-utils.js +1 -1
  3. package/lib/document/automation-document.js +1 -1
  4. package/lib/document/command-document.js +1 -1
  5. package/lib/document/document-builder.js +2 -2
  6. package/lib/document/ssm-document.js +1 -1
  7. package/lib/domain/aws-service.js +1 -1
  8. package/lib/domain/choice.js +1 -1
  9. package/lib/domain/data-type.js +1 -1
  10. package/lib/domain/enum/install-action.js +2 -2
  11. package/lib/domain/enum/install-uninstall-repair.js +2 -2
  12. package/lib/domain/enum/installation-type.js +2 -2
  13. package/lib/domain/enum/package-name.js +2 -2
  14. package/lib/domain/input.js +1 -1
  15. package/lib/domain/operation.js +1 -1
  16. package/lib/domain/platform.js +1 -1
  17. package/lib/domain/precondition.js +1 -1
  18. package/lib/incident-response/incident-response.js +3 -3
  19. package/lib/interface/approve-hook.js +2 -2
  20. package/lib/interface/auth-method.js +3 -3
  21. package/lib/interface/aws-invoker.js +2 -2
  22. package/lib/interface/downloadable-content.js +8 -8
  23. package/lib/interface/environment.js +3 -3
  24. package/lib/interface/execute-automation-hook/api-execute-automation-hook.js +1 -1
  25. package/lib/interface/observer.js +1 -1
  26. package/lib/interface/on-failure.js +6 -6
  27. package/lib/interface/pause-hook.js +2 -2
  28. package/lib/interface/run-command-hook/api-run-command-hook.js +1 -1
  29. package/lib/interface/run-document-location.js +2 -2
  30. package/lib/interface/sleep-hook.js +2 -2
  31. package/lib/interface/step-ref.js +1 -1
  32. package/lib/interface/variables/boolean-variable.js +2 -2
  33. package/lib/interface/variables/map-list-variable.js +2 -2
  34. package/lib/interface/variables/number-variable.js +2 -2
  35. package/lib/interface/variables/secure-string-variable.js +4 -4
  36. package/lib/interface/variables/string-list-variable.js +2 -2
  37. package/lib/interface/variables/string-map-variable.js +2 -2
  38. package/lib/interface/variables/string-variable.js +4 -4
  39. package/lib/interface/variables/variable.js +2 -2
  40. package/lib/interface/webhook.js +1 -1
  41. package/lib/parent-steps/automation/approve-step.js +1 -1
  42. package/lib/parent-steps/automation/assert-aws-resource-step.js +1 -1
  43. package/lib/parent-steps/automation/aws-api-step.js +1 -1
  44. package/lib/parent-steps/automation/branch-step.js +1 -1
  45. package/lib/parent-steps/automation/change-instance-state-step.js +3 -3
  46. package/lib/parent-steps/automation/copy-image-step.js +1 -1
  47. package/lib/parent-steps/automation/create-image-step.js +1 -1
  48. package/lib/parent-steps/automation/create-stack-step.js +3 -3
  49. package/lib/parent-steps/automation/create-tags-step.js +3 -3
  50. package/lib/parent-steps/automation/delete-image-step.js +1 -1
  51. package/lib/parent-steps/automation/delete-stack-step.js +1 -1
  52. package/lib/parent-steps/automation/execute-automation-step.js +1 -1
  53. package/lib/parent-steps/automation/execute-script-step.js +5 -5
  54. package/lib/parent-steps/automation/execute-state-machine-step.js +1 -1
  55. package/lib/parent-steps/automation/invoke-lambda-function-step.js +1 -1
  56. package/lib/parent-steps/automation/invoke-webhook-step.js +1 -1
  57. package/lib/parent-steps/automation/pause-step.js +1 -1
  58. package/lib/parent-steps/automation/run-command-step.js +3 -3
  59. package/lib/parent-steps/automation/run-instance-step.js +1 -1
  60. package/lib/parent-steps/automation/sleep-step.js +1 -1
  61. package/lib/parent-steps/automation/update-variable.js +1 -1
  62. package/lib/parent-steps/automation/wait-for-resource-step.js +1 -1
  63. package/lib/parent-steps/automation-step.js +1 -1
  64. package/lib/parent-steps/command/applications-step.js +1 -1
  65. package/lib/parent-steps/command/configure-docker-step.js +1 -1
  66. package/lib/parent-steps/command/configure-package-step.js +1 -1
  67. package/lib/parent-steps/command/domain-join-step.js +1 -1
  68. package/lib/parent-steps/command/download-content-step.js +1 -1
  69. package/lib/parent-steps/command/ps-module-step.js +1 -1
  70. package/lib/parent-steps/command/run-docker-action-step.js +1 -1
  71. package/lib/parent-steps/command/run-document-step.js +1 -1
  72. package/lib/parent-steps/command/run-powershell-script-step.js +1 -1
  73. package/lib/parent-steps/command/run-shell-script-step.js +1 -1
  74. package/lib/parent-steps/command/software-inventory-step.js +1 -1
  75. package/lib/parent-steps/command/update-agent-step.js +1 -1
  76. package/lib/parent-steps/command/update-ssm-agent-step.js +1 -1
  77. package/lib/parent-steps/command-step.js +1 -1
  78. package/lib/parent-steps/step.js +1 -1
  79. package/lib/patterns/automation/composite-step.js +2 -2
  80. package/lib/patterns/automation/reboot-instance-and-wait.js +1 -1
  81. package/lib/patterns/automation/string-step.js +1 -1
  82. package/lib/patterns/document/string-document.js +1 -1
  83. package/lib/patterns/document/timed-document.js +1 -1
  84. package/lib/samples/hello-world.js +1 -1
  85. package/lib/simulation/automation/approve-simulation.js +1 -1
  86. package/lib/simulation/automation/assert-aws-resource-simulation.js +1 -1
  87. package/lib/simulation/automation/automation-simulation-base.js +1 -1
  88. package/lib/simulation/automation/aws-api-simulation.js +1 -1
  89. package/lib/simulation/automation/branch-simulation.js +1 -1
  90. package/lib/simulation/automation/change-instance-state-simulation.js +1 -1
  91. package/lib/simulation/automation/copy-image-simulation.js +1 -1
  92. package/lib/simulation/automation/create-image-simulation.js +1 -1
  93. package/lib/simulation/automation/create-stack-simulation.js +1 -1
  94. package/lib/simulation/automation/create-tags-simulation.js +1 -1
  95. package/lib/simulation/automation/delete-image-simulation.js +1 -1
  96. package/lib/simulation/automation/delete-stack-simulation.js +1 -1
  97. package/lib/simulation/automation/execute-script-simulation.js +1 -1
  98. package/lib/simulation/automation/execute-state-machine-simulation.js +1 -1
  99. package/lib/simulation/automation/invoke-lambda-function-simulation.js +1 -1
  100. package/lib/simulation/automation/invoke-webhook-simulation.js +1 -1
  101. package/lib/simulation/automation/pause-simulation.js +1 -1
  102. package/lib/simulation/automation/run-command-simulation.js +1 -1
  103. package/lib/simulation/automation/run-instance-simulation.js +1 -1
  104. package/lib/simulation/automation/sleep-simulation.js +1 -1
  105. package/lib/simulation/automation/update-variable-simulation.js +1 -1
  106. package/lib/simulation/automation/wait-for-resource-simulation.js +1 -1
  107. package/lib/simulation/automation-step-simulation.js +1 -1
  108. package/lib/simulation/command/command-simulation-base.js +1 -1
  109. package/lib/simulation/command/ps-module-simulation.js +1 -1
  110. package/lib/simulation/command/run-powershell-script-simulation.js +1 -1
  111. package/lib/simulation/command/run-shell-script-simulation.js +1 -1
  112. package/lib/simulation/command-step-simulation.js +1 -1
  113. package/lib/simulation/document/automation-simulation.js +1 -1
  114. package/lib/simulation/document/command-simulation.js +1 -1
  115. package/lib/simulation/simulation.js +1 -1
  116. package/node_modules/@aws-sdk/client-cloudformation/package.json +34 -34
  117. package/node_modules/@aws-sdk/client-cloudwatch/package.json +36 -36
  118. package/node_modules/@aws-sdk/client-ec2/README.md +14 -0
  119. package/node_modules/@aws-sdk/client-ec2/dist-cjs/index.js +41 -0
  120. package/node_modules/@aws-sdk/client-ec2/dist-cjs/schemas/schemas_0.js +156 -78
  121. package/node_modules/@aws-sdk/client-ec2/dist-es/EC2.js +6 -0
  122. package/node_modules/@aws-sdk/client-ec2/dist-es/commands/GetCapacityManagerMonitoredTagKeysCommand.js +16 -0
  123. package/node_modules/@aws-sdk/client-ec2/dist-es/commands/UpdateCapacityManagerMonitoredTagKeysCommand.js +16 -0
  124. package/node_modules/@aws-sdk/client-ec2/dist-es/commands/index.js +2 -0
  125. package/node_modules/@aws-sdk/client-ec2/dist-es/models/enums.js +8 -0
  126. package/node_modules/@aws-sdk/client-ec2/dist-es/pagination/GetCapacityManagerMonitoredTagKeysPaginator.js +4 -0
  127. package/node_modules/@aws-sdk/client-ec2/dist-es/pagination/index.js +1 -0
  128. package/node_modules/@aws-sdk/client-ec2/dist-es/schemas/schemas_0.js +96 -18
  129. package/node_modules/@aws-sdk/client-ec2/dist-types/EC2.d.ts +23 -0
  130. package/node_modules/@aws-sdk/client-ec2/dist-types/EC2Client.d.ts +4 -2
  131. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerMetricDataCommand.d.ts +9 -2
  132. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerMetricDimensionsCommand.d.ts +9 -2
  133. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetCapacityManagerMonitoredTagKeysCommand.d.ts +87 -0
  134. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetConsoleScreenshotCommand.d.ts +1 -1
  135. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/GetDeclarativePoliciesReportSummaryCommand.d.ts +1 -2
  136. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ModifyTrafficMirrorFilterNetworkServicesCommand.d.ts +1 -1
  137. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/ModifyTrafficMirrorFilterRuleCommand.d.ts +1 -1
  138. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/UpdateCapacityManagerMonitoredTagKeysCommand.d.ts +91 -0
  139. package/node_modules/@aws-sdk/client-ec2/dist-types/commands/index.d.ts +2 -0
  140. package/node_modules/@aws-sdk/client-ec2/dist-types/models/enums.d.ts +16 -0
  141. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_5.d.ts +126 -79
  142. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_6.d.ts +81 -122
  143. package/node_modules/@aws-sdk/client-ec2/dist-types/models/models_7.d.ts +168 -3
  144. package/node_modules/@aws-sdk/client-ec2/dist-types/pagination/GetCapacityManagerMonitoredTagKeysPaginator.d.ts +7 -0
  145. package/node_modules/@aws-sdk/client-ec2/dist-types/pagination/index.d.ts +1 -0
  146. package/node_modules/@aws-sdk/client-ec2/dist-types/schemas/schemas_0.d.ts +8 -0
  147. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2.d.ts +55 -0
  148. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/EC2Client.d.ts +12 -0
  149. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetCapacityManagerMonitoredTagKeysCommand.d.ts +51 -0
  150. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetConsoleScreenshotCommand.d.ts +1 -1
  151. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/GetDeclarativePoliciesReportSummaryCommand.d.ts +4 -2
  152. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ModifyTrafficMirrorFilterNetworkServicesCommand.d.ts +1 -1
  153. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/ModifyTrafficMirrorFilterRuleCommand.d.ts +1 -1
  154. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/UpdateCapacityManagerMonitoredTagKeysCommand.d.ts +51 -0
  155. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/commands/index.d.ts +2 -0
  156. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/enums.d.ts +10 -0
  157. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_5.d.ts +23 -18
  158. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_6.d.ts +19 -34
  159. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/models/models_7.d.ts +43 -0
  160. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/pagination/GetCapacityManagerMonitoredTagKeysPaginator.d.ts +11 -0
  161. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/pagination/index.d.ts +1 -0
  162. package/node_modules/@aws-sdk/client-ec2/dist-types/ts3.4/schemas/schemas_0.d.ts +8 -0
  163. package/node_modules/@aws-sdk/client-ec2/package.json +36 -36
  164. package/node_modules/@aws-sdk/client-iam/package.json +35 -35
  165. package/node_modules/@aws-sdk/client-lambda/dist-cjs/models/errors.js +52 -1
  166. package/node_modules/@aws-sdk/client-lambda/dist-cjs/schemas/schemas_0.js +29 -8
  167. package/node_modules/@aws-sdk/client-lambda/dist-es/models/errors.js +48 -0
  168. package/node_modules/@aws-sdk/client-lambda/dist-es/schemas/schemas_0.js +22 -1
  169. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/InvokeCommand.d.ts +9 -0
  170. package/node_modules/@aws-sdk/client-lambda/dist-types/commands/InvokeWithResponseStreamCommand.d.ts +9 -0
  171. package/node_modules/@aws-sdk/client-lambda/dist-types/models/errors.d.ts +66 -0
  172. package/node_modules/@aws-sdk/client-lambda/dist-types/models/models_0.d.ts +6 -6
  173. package/node_modules/@aws-sdk/client-lambda/dist-types/schemas/schemas_0.d.ts +3 -0
  174. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/models/errors.d.ts +30 -0
  175. package/node_modules/@aws-sdk/client-lambda/dist-types/ts3.4/schemas/schemas_0.d.ts +3 -0
  176. package/node_modules/@aws-sdk/client-lambda/package.json +38 -38
  177. package/node_modules/@aws-sdk/client-s3/dist-cjs/index.js +5 -0
  178. package/node_modules/@aws-sdk/client-s3/dist-es/models/enums.js +5 -0
  179. package/node_modules/@aws-sdk/client-s3/dist-types/commands/CreateBucketCommand.d.ts +1 -1
  180. package/node_modules/@aws-sdk/client-s3/dist-types/commands/GetBucketLocationCommand.d.ts +1 -1
  181. package/node_modules/@aws-sdk/client-s3/dist-types/models/enums.d.ts +5 -0
  182. package/node_modules/@aws-sdk/client-s3/dist-types/ts3.4/models/enums.d.ts +5 -0
  183. package/node_modules/@aws-sdk/client-s3/package.json +50 -50
  184. package/node_modules/@aws-sdk/client-sns/package.json +33 -33
  185. package/node_modules/@aws-sdk/client-sqs/dist-cjs/index.js +2 -0
  186. package/node_modules/@aws-sdk/client-sqs/dist-es/commands/ReceiveMessageCommand.js +2 -0
  187. package/node_modules/@aws-sdk/client-sqs/package.json +36 -36
  188. package/node_modules/@aws-sdk/client-ssm/package.json +34 -34
  189. package/node_modules/@aws-sdk/core/dist-cjs/index.js +17 -0
  190. package/node_modules/@aws-sdk/core/dist-cjs/submodules/client/index.js +17 -0
  191. package/node_modules/@aws-sdk/core/dist-es/submodules/client/index.js +1 -0
  192. package/node_modules/@aws-sdk/core/dist-es/submodules/client/longPollMiddleware.js +15 -0
  193. package/node_modules/@aws-sdk/core/dist-types/submodules/client/index.d.ts +1 -0
  194. package/node_modules/@aws-sdk/core/dist-types/submodules/client/longPollMiddleware.d.ts +14 -0
  195. package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/index.d.ts +1 -0
  196. package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/client/longPollMiddleware.d.ts +15 -0
  197. package/node_modules/@aws-sdk/core/package.json +11 -11
  198. package/node_modules/@aws-sdk/crc64-nvme/package.json +2 -2
  199. package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
  200. package/node_modules/@aws-sdk/credential-provider-http/package.json +10 -10
  201. package/node_modules/@aws-sdk/credential-provider-ini/package.json +14 -14
  202. package/node_modules/@aws-sdk/credential-provider-login/package.json +8 -8
  203. package/node_modules/@aws-sdk/credential-provider-node/package.json +12 -12
  204. package/node_modules/@aws-sdk/credential-provider-process/package.json +6 -6
  205. package/node_modules/@aws-sdk/credential-provider-sso/package.json +8 -8
  206. package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +7 -7
  207. package/node_modules/@aws-sdk/middleware-bucket-endpoint/package.json +5 -5
  208. package/node_modules/@aws-sdk/middleware-expect-continue/package.json +4 -4
  209. package/node_modules/@aws-sdk/middleware-flexible-checksums/package.json +10 -10
  210. package/node_modules/@aws-sdk/middleware-host-header/package.json +4 -4
  211. package/node_modules/@aws-sdk/middleware-location-constraint/package.json +3 -3
  212. package/node_modules/@aws-sdk/middleware-logger/package.json +3 -3
  213. package/node_modules/@aws-sdk/middleware-recursion-detection/package.json +4 -4
  214. package/node_modules/@aws-sdk/middleware-sdk-ec2/package.json +8 -8
  215. package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +11 -11
  216. package/node_modules/@aws-sdk/middleware-sdk-sqs/package.json +4 -4
  217. package/node_modules/@aws-sdk/middleware-ssec/package.json +3 -3
  218. package/node_modules/@aws-sdk/middleware-user-agent/package.json +8 -8
  219. package/node_modules/@aws-sdk/nested-clients/package.json +32 -32
  220. package/node_modules/@aws-sdk/region-config-resolver/package.json +5 -5
  221. package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +6 -6
  222. package/node_modules/@aws-sdk/token-providers/package.json +7 -7
  223. package/node_modules/@aws-sdk/types/package.json +2 -2
  224. package/node_modules/@aws-sdk/util-endpoints/package.json +5 -5
  225. package/node_modules/@aws-sdk/util-format-url/package.json +4 -4
  226. package/node_modules/@aws-sdk/util-user-agent-browser/package.json +3 -3
  227. package/node_modules/@aws-sdk/util-user-agent-node/package.json +5 -5
  228. package/node_modules/{strnum → @aws-sdk/xml-builder/node_modules/strnum}/package.json +1 -1
  229. package/node_modules/@aws-sdk/xml-builder/package.json +2 -2
  230. package/node_modules/@smithy/config-resolver/package.json +2 -2
  231. package/node_modules/@smithy/middleware-retry/package.json +2 -2
  232. package/node_modules/@smithy/util-defaults-mode-node/package.json +2 -2
  233. package/node_modules/@smithy/util-endpoints/dist-cjs/index.js +154 -61
  234. package/node_modules/@smithy/util-endpoints/dist-es/bdd/BinaryDecisionDiagram.js +15 -0
  235. package/node_modules/@smithy/util-endpoints/dist-es/decideEndpoint.js +41 -0
  236. package/node_modules/@smithy/util-endpoints/dist-es/index.js +2 -0
  237. package/node_modules/@smithy/util-endpoints/dist-es/lib/coalesce.js +8 -0
  238. package/node_modules/@smithy/util-endpoints/dist-es/lib/index.js +3 -0
  239. package/node_modules/@smithy/util-endpoints/dist-es/lib/ite.js +3 -0
  240. package/node_modules/@smithy/util-endpoints/dist-es/lib/split.js +13 -0
  241. package/node_modules/@smithy/util-endpoints/dist-es/lib/substring.js +1 -1
  242. package/node_modules/@smithy/util-endpoints/dist-es/utils/endpointFunctions.js +4 -1
  243. package/node_modules/@smithy/util-endpoints/dist-es/utils/evaluateExpression.js +20 -5
  244. package/node_modules/@smithy/util-endpoints/dist-es/utils/evaluateTemplate.js +3 -6
  245. package/node_modules/@smithy/util-endpoints/dist-es/utils/getReferenceValue.js +1 -5
  246. package/node_modules/@smithy/util-endpoints/dist-types/bdd/BinaryDecisionDiagram.d.ts +22 -0
  247. package/node_modules/@smithy/util-endpoints/dist-types/decideEndpoint.d.ts +7 -0
  248. package/node_modules/@smithy/util-endpoints/dist-types/index.d.ts +2 -0
  249. package/node_modules/@smithy/util-endpoints/dist-types/lib/coalesce.d.ts +7 -0
  250. package/node_modules/@smithy/util-endpoints/dist-types/lib/index.d.ts +3 -0
  251. package/node_modules/@smithy/util-endpoints/dist-types/lib/ite.d.ts +6 -0
  252. package/node_modules/@smithy/util-endpoints/dist-types/lib/split.d.ts +11 -0
  253. package/node_modules/@smithy/util-endpoints/dist-types/utils/endpointFunctions.d.ts +4 -0
  254. package/node_modules/@smithy/util-endpoints/dist-types/utils/getReferenceValue.d.ts +3 -1
  255. package/node_modules/@smithy/util-endpoints/package.json +1 -1
  256. package/node_modules/@smithy/util-retry/dist-cjs/index.js +6 -0
  257. package/node_modules/@smithy/util-retry/dist-es/AdaptiveRetryStrategy.js +3 -0
  258. package/node_modules/@smithy/util-retry/dist-es/StandardRetryStrategy.js +3 -0
  259. package/node_modules/@smithy/util-retry/dist-types/AdaptiveRetryStrategy.d.ts +5 -0
  260. package/node_modules/@smithy/util-retry/dist-types/StandardRetryStrategy.d.ts +5 -0
  261. package/node_modules/@smithy/util-retry/package.json +1 -1
  262. package/node_modules/path-expression-matcher/README.md +214 -62
  263. package/node_modules/path-expression-matcher/lib/pem.cjs +1 -1
  264. package/node_modules/path-expression-matcher/lib/pem.d.cts +111 -0
  265. package/node_modules/path-expression-matcher/lib/pem.min.js +1 -1
  266. package/node_modules/path-expression-matcher/lib/pem.min.js.map +1 -1
  267. package/node_modules/path-expression-matcher/package.json +1 -1
  268. package/node_modules/path-expression-matcher/src/Expression.js +2 -2
  269. package/node_modules/path-expression-matcher/src/ExpressionSet.js +209 -0
  270. package/node_modules/path-expression-matcher/src/Matcher.js +235 -177
  271. package/node_modules/path-expression-matcher/src/index.d.ts +199 -194
  272. package/node_modules/path-expression-matcher/src/index.js +3 -2
  273. package/package.json +10 -10
  274. package/node_modules/strnum/.github/SECURITY.md +0 -5
  275. package/node_modules/strnum/.vscode/launch.json +0 -25
  276. package/node_modules/strnum/algo.stflow +0 -84
  277. package/node_modules/strnum/tests/infinity_test.js +0 -18
  278. package/node_modules/strnum/tests/strnum_test.js +0 -175
  279. package/node_modules/strnum/tests/temp.js +0 -8
  280. /package/node_modules/{strnum → @aws-sdk/xml-builder/node_modules/strnum}/CHANGELOG.md +0 -0
  281. /package/node_modules/{strnum → @aws-sdk/xml-builder/node_modules/strnum}/LICENSE +0 -0
  282. /package/node_modules/{strnum → @aws-sdk/xml-builder/node_modules/strnum}/README.md +0 -0
  283. /package/node_modules/{strnum → @aws-sdk/xml-builder/node_modules/strnum}/strnum.js +0 -0
@@ -189,169 +189,81 @@ export interface MatcherSnapshot {
189
189
  }
190
190
 
191
191
  /**
192
- * ReadOnlyMatcher - A safe, read-only view over a {@link Matcher} instance.
192
+ * MatcherView - A lightweight read-only view over a {@link Matcher} instance.
193
193
  *
194
- * Returned by {@link Matcher.readOnly}. Exposes all query and inspection
195
- * methods but **throws a `TypeError`** if any state-mutating method is called
196
- * (`push`, `pop`, `reset`, `updateCurrent`, `restore`). Direct property
197
- * writes are also blocked.
194
+ * Created once by {@link Matcher} and reused across all callbacks no allocation
195
+ * on every invocation. Holds a direct reference to the parent Matcher's internal
196
+ * state so it always reflects the current parser position with zero copying or
197
+ * freezing overhead.
198
198
  *
199
- * Pass this to consumers that only need to inspect or match the current path
200
- * so they cannot accidentally corrupt the parser state.
199
+ * Mutation methods (`push`, `pop`, `reset`, `updateCurrent`, `restore`) are simply
200
+ * absent from this class, so misuse is caught at compile time by TypeScript rather
201
+ * than at runtime.
202
+ *
203
+ * Obtain via {@link Matcher#readOnly} — the same instance is returned every time.
201
204
  *
202
205
  * @example
203
206
  * ```typescript
204
207
  * const matcher = new Matcher();
208
+ * const view: MatcherView = matcher.readOnly();
209
+ *
205
210
  * matcher.push("root", {});
206
211
  * matcher.push("users", {});
207
212
  * matcher.push("user", { id: "123" });
208
213
  *
209
- * const ro: ReadOnlyMatcher = matcher.readOnly();
210
- *
211
- * ro.matches(expr); // ✓ works
212
- * ro.getCurrentTag(); // "user"
213
- * ro.getDepth(); // ✓ 3
214
- * ro.push("child", {}); // ✗ TypeError: Cannot call 'push' on a read-only Matcher
215
- * ro.reset(); // ✗ TypeError: Cannot call 'reset' on a read-only Matcher
214
+ * view.matches(expr); // ✓ true
215
+ * view.getCurrentTag(); // ✓ "user"
216
+ * view.getDepth(); // ✓ 3
217
+ * // view.push(...) // Property 'push' does not exist on type 'MatcherView'
216
218
  * ```
217
219
  */
218
- export interface ReadOnlyMatcher {
220
+ export class MatcherView {
219
221
  /**
220
- * Default path separator (read-only)
222
+ * Default path separator (read-only, delegates to parent Matcher)
221
223
  */
222
224
  readonly separator: string;
223
225
 
224
- /**
225
- * Current path stack (each node is a frozen copy)
226
- */
227
- readonly path: ReadonlyArray<Readonly<PathNode>>;
228
-
229
- // ── Query methods ───────────────────────────────────────────────────────────
230
-
231
- /**
232
- * Get current tag name
233
- * @returns Current tag name or undefined if path is empty
234
- */
235
226
  getCurrentTag(): string | undefined;
236
-
237
- /**
238
- * Get current namespace
239
- * @returns Current namespace or undefined if not present or path is empty
240
- */
241
227
  getCurrentNamespace(): string | undefined;
242
-
243
- /**
244
- * Get current node's attribute value
245
- * @param attrName - Attribute name
246
- * @returns Attribute value or undefined
247
- */
248
228
  getAttrValue(attrName: string): any;
249
-
250
- /**
251
- * Check if current node has an attribute
252
- * @param attrName - Attribute name
253
- */
254
229
  hasAttr(attrName: string): boolean;
255
-
256
- /**
257
- * Get current node's sibling position (child index in parent)
258
- * @returns Position index or -1 if path is empty
259
- */
260
230
  getPosition(): number;
261
-
262
- /**
263
- * Get current node's repeat counter (occurrence count of this tag name)
264
- * @returns Counter value or -1 if path is empty
265
- */
266
231
  getCounter(): number;
267
-
268
- /**
269
- * Get current node's sibling index (alias for getPosition for backward compatibility)
270
- * @returns Index or -1 if path is empty
271
- * @deprecated Use getPosition() or getCounter() instead
272
- */
232
+ /** @deprecated Use getPosition() or getCounter() instead */
273
233
  getIndex(): number;
274
-
275
- /**
276
- * Get current path depth
277
- * @returns Number of nodes in the path
278
- */
279
234
  getDepth(): number;
280
-
281
- /**
282
- * Get path as string
283
- * @param separator - Optional separator (uses default if not provided)
284
- * @param includeNamespace - Whether to include namespace in output
285
- * @returns Path string (e.g., "root.users.user" or "ns:root.ns:users.user")
286
- */
287
235
  toString(separator?: string, includeNamespace?: boolean): string;
288
-
289
- /**
290
- * Get path as array of tag names
291
- * @returns Array of tag names
292
- */
293
236
  toArray(): string[];
294
-
295
- /**
296
- * Match current path against an Expression
297
- * @param expression - The expression to match against
298
- * @returns True if current path matches the expression
299
- */
300
237
  matches(expression: Expression): boolean;
301
-
302
- /**
303
- * Create a snapshot of current state
304
- * @returns State snapshot that can be restored later
305
- */
306
- snapshot(): MatcherSnapshot;
307
-
308
- // ── Blocked mutating methods ────────────────────────────────────────────────
309
- // These are present in the type so callers get a compile-time error with a
310
- // helpful message instead of a silent "property does not exist" error.
311
-
312
- /**
313
- * @throws {TypeError} Always – mutation is not allowed on a read-only view.
314
- */
315
- push(tagName: string, attrValues?: Record<string, any> | null, namespace?: string | null): never;
316
-
317
- /**
318
- * @throws {TypeError} Always – mutation is not allowed on a read-only view.
319
- */
320
- pop(): never;
321
-
322
- /**
323
- * @throws {TypeError} Always – mutation is not allowed on a read-only view.
324
- */
325
- updateCurrent(attrValues: Record<string, any>): never;
326
-
327
- /**
328
- * @throws {TypeError} Always – mutation is not allowed on a read-only view.
329
- */
330
- reset(): never;
331
-
332
- /**
333
- * @throws {TypeError} Always – mutation is not allowed on a read-only view.
334
- */
335
- restore(snapshot: MatcherSnapshot): never;
238
+ matchesAny(exprSet: ExpressionSet): boolean;
336
239
  }
337
240
 
338
241
  /**
339
- * Matcher - Tracks current path in XML/JSON tree and matches against Expressions
340
- *
242
+ * @deprecated Use {@link MatcherView} instead.
243
+ * Alias kept for backward compatibility with code that references `ReadOnlyMatcher`.
244
+ */
245
+ export type ReadOnlyMatcher = MatcherView;
246
+
247
+ /**
248
+ * Matcher - Tracks current path in XML/JSON tree and matches against Expressions.
249
+ *
341
250
  * The matcher maintains a stack of nodes representing the current path from root to
342
251
  * current tag. It only stores attribute values for the current (top) node to minimize
343
252
  * memory usage.
344
- *
253
+ *
254
+ * Use {@link Matcher#readOnly} to obtain a {@link MatcherView} safe to pass to
255
+ * user callbacks — the same instance is reused on every call with no allocation overhead.
256
+ *
345
257
  * @example
346
258
  * ```typescript
347
259
  * const matcher = new Matcher();
348
260
  * matcher.push("root", {});
349
261
  * matcher.push("users", {});
350
262
  * matcher.push("user", { id: "123", type: "admin" });
351
- *
263
+ *
352
264
  * const expr = new Expression("root.users.user");
353
265
  * matcher.matches(expr); // true
354
- *
266
+ *
355
267
  * matcher.pop();
356
268
  * matcher.matches(expr); // false
357
269
  * ```
@@ -362,11 +274,6 @@ export class Matcher {
362
274
  */
363
275
  readonly separator: string;
364
276
 
365
- /**
366
- * Current path stack
367
- */
368
- readonly path: PathNode[];
369
-
370
277
  /**
371
278
  * Create a new Matcher
372
279
  * @param options - Configuration options
@@ -374,11 +281,11 @@ export class Matcher {
374
281
  constructor(options?: MatcherOptions);
375
282
 
376
283
  /**
377
- * Push a new tag onto the path
284
+ * Push a new tag onto the path.
378
285
  * @param tagName - Name of the tag
379
286
  * @param attrValues - Attribute key-value pairs for current node (optional)
380
287
  * @param namespace - Namespace for the tag (optional)
381
- *
288
+ *
382
289
  * @example
383
290
  * ```typescript
384
291
  * matcher.push("user", { id: "123", type: "admin" });
@@ -389,130 +296,228 @@ export class Matcher {
389
296
  push(tagName: string, attrValues?: Record<string, any> | null, namespace?: string | null): void;
390
297
 
391
298
  /**
392
- * Pop the last tag from the path
299
+ * Pop the last tag from the path.
393
300
  * @returns The popped node or undefined if path is empty
394
301
  */
395
302
  pop(): PathNode | undefined;
396
303
 
397
304
  /**
398
- * Update current node's attribute values
399
- * Useful when attributes are parsed after push
305
+ * Update current node's attribute values.
306
+ * Useful when attributes are parsed after push.
400
307
  * @param attrValues - Attribute values
401
308
  */
402
309
  updateCurrent(attrValues: Record<string, any>): void;
403
310
 
404
311
  /**
405
- * Get current tag name
406
- * @returns Current tag name or undefined if path is empty
312
+ * Reset the path to empty.
407
313
  */
408
- getCurrentTag(): string | undefined;
314
+ reset(): void;
409
315
 
410
316
  /**
411
- * Get current namespace
412
- * @returns Current namespace or undefined if not present or path is empty
317
+ * Create a snapshot of current state.
318
+ * @returns State snapshot that can be restored later
413
319
  */
414
- getCurrentNamespace(): string | undefined;
320
+ snapshot(): MatcherSnapshot;
415
321
 
416
322
  /**
417
- * Get current node's attribute value
418
- * @param attrName - Attribute name
419
- * @returns Attribute value or undefined
323
+ * Restore state from snapshot.
324
+ * @param snapshot - State snapshot from previous snapshot() call
420
325
  */
421
- getAttrValue(attrName: string): any;
326
+ restore(snapshot: MatcherSnapshot): void;
422
327
 
423
- /**
424
- * Check if current node has an attribute
425
- * @param attrName - Attribute name
426
- */
328
+ getCurrentTag(): string | undefined;
329
+ getCurrentNamespace(): string | undefined;
330
+ getAttrValue(attrName: string): any;
427
331
  hasAttr(attrName: string): boolean;
332
+ getPosition(): number;
333
+ getCounter(): number;
334
+ /** @deprecated Use getPosition() or getCounter() instead */
335
+ getIndex(): number;
336
+ getDepth(): number;
337
+ toString(separator?: string, includeNamespace?: boolean): string;
338
+ toArray(): string[];
339
+ matches(expression: Expression): boolean;
340
+ matchesAny(exprSet: ExpressionSet): boolean;
428
341
 
429
342
  /**
430
- * Get current node's sibling position (child index in parent)
431
- * @returns Position index or -1 if path is empty
343
+ * Return the read-only {@link MatcherView} for this matcher.
344
+ *
345
+ * The same instance is returned on every call — no allocation occurs.
346
+ * Pass this to user callbacks; it always reflects current parser state.
347
+ *
348
+ * @example
349
+ * ```typescript
350
+ * const view = matcher.readOnly();
351
+ * // same reference every time — safe to cache
352
+ * view === matcher.readOnly(); // true
353
+ * ```
432
354
  */
433
- getPosition(): number;
355
+ readOnly(): MatcherView;
356
+ }
434
357
 
358
+ /**
359
+ * ExpressionSet - An indexed collection of Expressions for efficient bulk matching
360
+ *
361
+ * Pre-indexes expressions at insertion time by depth and terminal tag name so
362
+ * that `matchesAny()` performs an O(1) bucket lookup rather than a full O(E)
363
+ * linear scan on every tag.
364
+ *
365
+ * Three internal buckets are maintained automatically:
366
+ * - **exact** — expressions with a fixed depth and a concrete terminal tag
367
+ * - **depth-wildcard** — fixed depth but terminal tag is `*`
368
+ * - **deep-wildcard** — expressions containing `..` (cannot be depth-indexed)
369
+ *
370
+ * @example
371
+ * ```typescript
372
+ * import { Expression, ExpressionSet, Matcher } from 'fast-xml-tagger';
373
+ *
374
+ * // Build once at config time
375
+ * const stopNodes = new ExpressionSet();
376
+ * stopNodes
377
+ * .add(new Expression('root.users.user'))
378
+ * .add(new Expression('root.config.*'))
379
+ * .add(new Expression('..script'))
380
+ * .seal(); // prevent accidental mutation during parsing
381
+ *
382
+ * // Query on every tag — hot path
383
+ * if (stopNodes.matchesAny(matcher)) {
384
+ * // handle stop node
385
+ * }
386
+ * ```
387
+ */
388
+ export class ExpressionSet {
435
389
  /**
436
- * Get current node's repeat counter (occurrence count of this tag name)
437
- * @returns Counter value or -1 if path is empty
390
+ * Create an empty ExpressionSet.
438
391
  */
439
- getCounter(): number;
392
+ constructor();
440
393
 
441
394
  /**
442
- * Get current node's sibling index (alias for getPosition for backward compatibility)
443
- * @returns Index or -1 if path is empty
444
- * @deprecated Use getPosition() or getCounter() instead
395
+ * Number of expressions currently in the set.
445
396
  */
446
- getIndex(): number;
397
+ readonly size: number;
447
398
 
448
399
  /**
449
- * Get current path depth
450
- * @returns Number of nodes in the path
400
+ * Whether the set has been sealed against further modifications.
451
401
  */
452
- getDepth(): number;
402
+ readonly isSealed: boolean;
453
403
 
454
404
  /**
455
- * Get path as string
456
- * @param separator - Optional separator (uses default if not provided)
457
- * @param includeNamespace - Whether to include namespace in output
458
- * @returns Path string (e.g., "root.users.user" or "ns:root.ns:users.user")
405
+ * Add a single Expression to the set.
406
+ *
407
+ * Duplicate patterns (same `expression.pattern` string) are silently ignored.
408
+ *
409
+ * @param expression - A pre-constructed Expression instance
410
+ * @returns `this` — for chaining
411
+ * @throws {TypeError} if the set has been sealed
412
+ *
413
+ * @example
414
+ * ```typescript
415
+ * set.add(new Expression('root.users.user'));
416
+ * set.add(new Expression('..script'));
417
+ * ```
459
418
  */
460
- toString(separator?: string, includeNamespace?: boolean): string;
419
+ add(expression: Expression): this;
461
420
 
462
421
  /**
463
- * Get path as array of tag names
464
- * @returns Array of tag names
422
+ * Add multiple expressions at once.
423
+ *
424
+ * @param expressions - Array of Expression instances
425
+ * @returns `this` — for chaining
426
+ * @throws {TypeError} if the set has been sealed
427
+ *
428
+ * @example
429
+ * ```typescript
430
+ * set.addAll([
431
+ * new Expression('root.users.user'),
432
+ * new Expression('root.config.setting'),
433
+ * ]);
434
+ * ```
465
435
  */
466
- toArray(): string[];
436
+ addAll(expressions: Expression[]): this;
467
437
 
468
438
  /**
469
- * Reset the path to empty
439
+ * Check whether an Expression with the same pattern is already present.
440
+ *
441
+ * @param expression - Expression to look up
442
+ * @returns `true` if the pattern was already added
470
443
  */
471
- reset(): void;
444
+ has(expression: Expression): boolean;
472
445
 
473
446
  /**
474
- * Match current path against an Expression
475
- * @param expression - The expression to match against
476
- * @returns True if current path matches the expression
477
- *
447
+ * Seal the set against further modifications.
448
+ *
449
+ * After calling `seal()`, any call to `add()` or `addAll()` will throw a
450
+ * `TypeError`. This is useful to prevent accidental mutation once the config
451
+ * has been fully built and parsing has started.
452
+ *
453
+ * @returns `this` — for chaining
454
+ *
478
455
  * @example
479
456
  * ```typescript
480
- * const expr = new Expression("root.users.user[id]");
481
- * const matcher = new Matcher();
482
- *
483
- * matcher.push("root");
484
- * matcher.push("users");
485
- * matcher.push("user", { id: "123" });
486
- *
487
- * matcher.matches(expr); // true
457
+ * const stopNodes = new ExpressionSet();
458
+ * stopNodes.addAll(patterns.map(p => new Expression(p))).seal();
459
+ *
460
+ * // Later — safe: reads are still allowed
461
+ * stopNodes.matchesAny(matcher);
462
+ *
463
+ * // Later — throws TypeError: ExpressionSet is sealed
464
+ * stopNodes.add(new Expression('root.extra'));
488
465
  * ```
489
466
  */
490
- matches(expression: Expression): boolean;
491
-
492
- /**
493
- * Create a snapshot of current state
494
- * @returns State snapshot that can be restored later
495
- */
496
- snapshot(): MatcherSnapshot;
467
+ seal(): this;
497
468
 
498
469
  /**
499
- * Restore state from snapshot
500
- * @param snapshot - State snapshot from previous snapshot() call
470
+ * Test whether the matcher's current path matches **any** expression in the set.
471
+ *
472
+ * Uses the pre-built index to evaluate only the relevant bucket(s):
473
+ * 1. Exact depth + tag — O(1) lookup
474
+ * 2. Depth-matched wildcard tag — O(1) lookup
475
+ * 3. Deep-wildcard expressions — always scanned (typically a small list)
476
+ *
477
+ * @param matcher - A `Matcher` instance or a `ReadOnlyMatcher` view
478
+ * @returns `true` if at least one expression matches the current path
479
+ *
480
+ * @example
481
+ * ```typescript
482
+ * // Replaces:
483
+ * // for (const expr of stopNodeExpressions) {
484
+ * // if (matcher.matches(expr)) return true;
485
+ * // }
486
+ *
487
+ * if (stopNodes.matchesAny(matcher)) {
488
+ * // current tag is a stop node
489
+ * }
490
+ * ```
501
491
  */
502
- restore(snapshot: MatcherSnapshot): void;
492
+ matchesAny(matcher: Matcher | MatcherView): boolean;
503
493
 
504
494
  /**
505
- * Return a read-only view of this matcher.
495
+ * Find the first expression in the set that matches the matcher's current path.
496
+ *
497
+ * Uses the pre-built index to evaluate only the relevant bucket(s):
498
+ * 1. Exact depth + tag — O(1) lookup
499
+ * 2. Depth-matched wildcard tag — O(1) lookup
500
+ * 3. Deep-wildcard expressions — always scanned (typically a small list)
501
+ *
502
+ * @param matcher - A `Matcher` instance or a `ReadOnlyMatcher` view
503
+ * @returns Expression if at least one expression matches the current path
504
+ *
505
+ * @example
506
+ * ```typescript
507
+ * const node = stopNodes.findMatch(matcher);
508
+ * ```
506
509
  */
507
- readOnly(): ReadOnlyMatcher;
510
+ findMatch(matcher: Matcher | MatcherView): Expression;
508
511
  }
509
512
 
510
513
  /**
511
- * Default export containing both Expression and Matcher
514
+ * Default export containing Expression, Matcher, and ExpressionSet
512
515
  */
513
516
  declare const _default: {
514
517
  Expression: typeof Expression;
515
518
  Matcher: typeof Matcher;
519
+ MatcherView: typeof MatcherView;
520
+ ExpressionSet: typeof ExpressionSet;
516
521
  };
517
522
 
518
523
  export default _default;
@@ -23,6 +23,7 @@
23
23
 
24
24
  import Expression from './Expression.js';
25
25
  import Matcher from './Matcher.js';
26
+ import ExpressionSet from './ExpressionSet.js';
26
27
 
27
- export { Expression, Matcher };
28
- export default { Expression, Matcher };
28
+ export { Expression, Matcher, ExpressionSet };
29
+ export default { Expression, Matcher, ExpressionSet };
package/package.json CHANGED
@@ -74,15 +74,15 @@
74
74
  "constructs": "^10.5.1"
75
75
  },
76
76
  "dependencies": {
77
- "@aws-sdk/client-cloudformation": "^3.1024.0",
78
- "@aws-sdk/client-cloudwatch": "^3.1024.0",
79
- "@aws-sdk/client-ec2": "^3.1024.0",
80
- "@aws-sdk/client-iam": "^3.1024.0",
81
- "@aws-sdk/client-lambda": "^3.1024.0",
82
- "@aws-sdk/client-s3": "^3.1024.0",
83
- "@aws-sdk/client-sns": "^3.1024.0",
84
- "@aws-sdk/client-sqs": "^3.1024.0",
85
- "@aws-sdk/client-ssm": "^3.1024.0",
77
+ "@aws-sdk/client-cloudformation": "^3.1029.0",
78
+ "@aws-sdk/client-cloudwatch": "^3.1029.0",
79
+ "@aws-sdk/client-ec2": "^3.1029.0",
80
+ "@aws-sdk/client-iam": "^3.1029.0",
81
+ "@aws-sdk/client-lambda": "^3.1029.0",
82
+ "@aws-sdk/client-s3": "^3.1029.0",
83
+ "@aws-sdk/client-sns": "^3.1029.0",
84
+ "@aws-sdk/client-sqs": "^3.1029.0",
85
+ "@aws-sdk/client-ssm": "^3.1029.0",
86
86
  "immutable": "^4.3.8",
87
87
  "js-yaml": "^4.1.1",
88
88
  "jsonpath": "^1.3.0",
@@ -116,7 +116,7 @@
116
116
  "publishConfig": {
117
117
  "access": "public"
118
118
  },
119
- "version": "0.0.55",
119
+ "version": "0.0.56",
120
120
  "jest": {
121
121
  "coverageProvider": "v8",
122
122
  "maxWorkers": 4,
@@ -1,5 +0,0 @@
1
- If you believe you have found a security vulnerability in this repository which can be potentially harful for the users in anyway, please do not report security vulnerabilities through public GitHub issues. Instead, please report it to us as described below.
2
-
3
- ## Security contact information
4
-
5
- To report a security vulnerability, please use the [Tidelift security contact](https://tidelift.com/security). Tidelift will coordinate the fix and disclosure.
@@ -1,25 +0,0 @@
1
- {
2
- "version": "0.2.0",
3
- "configurations": [
4
- {
5
- "type": "node",
6
- "request": "launch",
7
- "name": "Jasmine Tests",
8
- "program": "${workspaceFolder}/node_modules/jasmine/bin/jasmine.js",
9
- "args": [
10
- "${workspaceFolder}/spec/attr_spec.js"
11
- ],
12
- "internalConsoleOptions": "openOnSessionStart"
13
- },{
14
- "type": "node",
15
- "request": "launch",
16
- "name": "Jasmine Tests current test file",
17
- "program": "${workspaceFolder}/node_modules/jasmine/bin/jasmine.js",
18
- "args": [
19
- "${file}"
20
- ],
21
- "internalConsoleOptions": "openOnSessionStart"
22
- }
23
- ]
24
-
25
- }