@bpmn-ld/bpmn-ld 0.0.0-stage → 0.1.0

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 (319) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +125 -2
  3. package/contexts/combined.jsonld +3 -0
  4. package/contexts/core.jsonld +170 -0
  5. package/contexts/di.jsonld +37 -0
  6. package/dist/analyze/analyze.d.ts +3 -0
  7. package/dist/analyze/analyze.js +11 -0
  8. package/dist/analyze/findings.d.ts +8 -0
  9. package/dist/analyze/findings.js +1 -0
  10. package/dist/analyze/report.d.ts +3 -0
  11. package/dist/analyze/report.js +9 -0
  12. package/dist/analyze/rules/ad-hoc-completion-condition.d.ts +2 -0
  13. package/dist/analyze/rules/ad-hoc-completion-condition.js +7 -0
  14. package/dist/analyze/rules/cannot-reach-end.d.ts +2 -0
  15. package/dist/analyze/rules/cannot-reach-end.js +28 -0
  16. package/dist/analyze/rules/compensation-association.d.ts +2 -0
  17. package/dist/analyze/rules/compensation-association.js +13 -0
  18. package/dist/analyze/rules/dead-end.d.ts +2 -0
  19. package/dist/analyze/rules/dead-end.js +13 -0
  20. package/dist/analyze/rules/end-event.d.ts +2 -0
  21. package/dist/analyze/rules/end-event.js +8 -0
  22. package/dist/analyze/rules/error-catch.d.ts +2 -0
  23. package/dist/analyze/rules/error-catch.js +14 -0
  24. package/dist/analyze/rules/escalation-catch.d.ts +2 -0
  25. package/dist/analyze/rules/escalation-catch.js +14 -0
  26. package/dist/analyze/rules/gateway-cardinality.d.ts +3 -0
  27. package/dist/analyze/rules/gateway-cardinality.js +17 -0
  28. package/dist/analyze/rules/index.d.ts +4 -0
  29. package/dist/analyze/rules/index.js +21 -0
  30. package/dist/analyze/rules/instantiating-gateway.d.ts +2 -0
  31. package/dist/analyze/rules/instantiating-gateway.js +14 -0
  32. package/dist/analyze/rules/non-interrupting-start.d.ts +2 -0
  33. package/dist/analyze/rules/non-interrupting-start.js +14 -0
  34. package/dist/analyze/rules/reachability.d.ts +2 -0
  35. package/dist/analyze/rules/reachability.js +25 -0
  36. package/dist/analyze/rules/rule.d.ts +7 -0
  37. package/dist/analyze/rules/rule.js +1 -0
  38. package/dist/analyze/rules/signal-catch.d.ts +2 -0
  39. package/dist/analyze/rules/signal-catch.js +12 -0
  40. package/dist/analyze/rules/split-join-pairing.d.ts +3 -0
  41. package/dist/analyze/rules/split-join-pairing.js +50 -0
  42. package/dist/analyze/rules/start-event.d.ts +2 -0
  43. package/dist/analyze/rules/start-event.js +8 -0
  44. package/dist/analyze/rules/task-message-flow.d.ts +2 -0
  45. package/dist/analyze/rules/task-message-flow.js +19 -0
  46. package/dist/analyze/scope-graph.d.ts +56 -0
  47. package/dist/analyze/scope-graph.js +89 -0
  48. package/dist/analyze-cli.d.ts +1 -0
  49. package/dist/analyze-cli.js +5 -0
  50. package/dist/analyze-run.d.ts +12 -0
  51. package/dist/analyze-run.js +85 -0
  52. package/dist/bpmn-ld-cli.d.ts +1 -0
  53. package/dist/bpmn-ld-cli.js +90 -0
  54. package/dist/build-cli.d.ts +1 -0
  55. package/dist/build-cli.js +2 -0
  56. package/dist/build.d.ts +3 -0
  57. package/dist/build.js +38 -0
  58. package/dist/check-xml/check.d.ts +3 -0
  59. package/dist/check-xml/check.js +11 -0
  60. package/dist/check-xml/lint.d.ts +2 -0
  61. package/dist/check-xml/lint.js +47 -0
  62. package/dist/check-xml/moddle.d.ts +6 -0
  63. package/dist/check-xml/moddle.js +23 -0
  64. package/dist/check-xml/types.d.ts +20 -0
  65. package/dist/check-xml/types.js +1 -0
  66. package/dist/check-xml/xsd.d.ts +2 -0
  67. package/dist/check-xml/xsd.js +25 -0
  68. package/dist/check-xml-cli.d.ts +1 -0
  69. package/dist/check-xml-cli.js +5 -0
  70. package/dist/check-xml-run.d.ts +10 -0
  71. package/dist/check-xml-run.js +77 -0
  72. package/dist/convert/analyze-output.d.ts +3 -0
  73. package/dist/convert/analyze-output.js +8 -0
  74. package/dist/convert/convert.d.ts +19 -0
  75. package/dist/convert/convert.js +96 -0
  76. package/dist/convert/errors.d.ts +5 -0
  77. package/dist/convert/errors.js +8 -0
  78. package/dist/convert/extensions.d.ts +23 -0
  79. package/dist/convert/extensions.js +103 -0
  80. package/dist/convert/mapping-check.d.ts +15 -0
  81. package/dist/convert/mapping-check.js +66 -0
  82. package/dist/convert/mapping.d.ts +52 -0
  83. package/dist/convert/mapping.js +273 -0
  84. package/dist/convert/namespaces.d.ts +2 -0
  85. package/dist/convert/namespaces.js +19 -0
  86. package/dist/convert/validate-output.d.ts +2 -0
  87. package/dist/convert/validate-output.js +28 -0
  88. package/dist/convert/warnings.d.ts +9 -0
  89. package/dist/convert/warnings.js +67 -0
  90. package/dist/convert/xml-reader.d.ts +11 -0
  91. package/dist/convert/xml-reader.js +84 -0
  92. package/dist/convert-cli.d.ts +1 -0
  93. package/dist/convert-cli.js +5 -0
  94. package/dist/convert-run.d.ts +10 -0
  95. package/dist/convert-run.js +125 -0
  96. package/dist/coverage-cli.d.ts +1 -0
  97. package/dist/coverage-cli.js +8 -0
  98. package/dist/coverage-mappings.d.ts +3 -0
  99. package/dist/coverage-mappings.js +34 -0
  100. package/dist/coverage-scope.d.ts +11 -0
  101. package/dist/coverage-scope.js +187 -0
  102. package/dist/coverage-xsd.d.ts +15 -0
  103. package/dist/coverage-xsd.js +55 -0
  104. package/dist/coverage.d.ts +35 -0
  105. package/dist/coverage.js +152 -0
  106. package/dist/docs-cli.d.ts +1 -0
  107. package/dist/docs-cli.js +18 -0
  108. package/dist/docs.d.ts +8 -0
  109. package/dist/docs.js +136 -0
  110. package/dist/eval/checks.d.ts +19 -0
  111. package/dist/eval/checks.js +252 -0
  112. package/dist/eval/regenerate.d.ts +10 -0
  113. package/dist/eval/regenerate.js +48 -0
  114. package/dist/eval-regenerate-cli.d.ts +1 -0
  115. package/dist/eval-regenerate-cli.js +16 -0
  116. package/dist/export/data.d.ts +10 -0
  117. package/dist/export/data.js +127 -0
  118. package/dist/export/diagram.d.ts +8 -0
  119. package/dist/export/diagram.js +112 -0
  120. package/dist/export/element.d.ts +27 -0
  121. package/dist/export/element.js +175 -0
  122. package/dist/export/export.d.ts +22 -0
  123. package/dist/export/export.js +124 -0
  124. package/dist/export/extensions.d.ts +18 -0
  125. package/dist/export/extensions.js +122 -0
  126. package/dist/export/layout-export.d.ts +4 -0
  127. package/dist/export/layout-export.js +25 -0
  128. package/dist/export/mapping-check.d.ts +39 -0
  129. package/dist/export/mapping-check.js +175 -0
  130. package/dist/export/normalize.d.ts +3 -0
  131. package/dist/export/normalize.js +67 -0
  132. package/dist/export-cli.d.ts +1 -0
  133. package/dist/export-cli.js +5 -0
  134. package/dist/export-run.d.ts +10 -0
  135. package/dist/export-run.js +157 -0
  136. package/dist/index.d.ts +10 -0
  137. package/dist/index.js +10 -0
  138. package/dist/install-skill-run.d.ts +8 -0
  139. package/dist/install-skill-run.js +30 -0
  140. package/dist/install-skill.d.ts +23 -0
  141. package/dist/install-skill.js +76 -0
  142. package/dist/layout/collaboration.d.ts +36 -0
  143. package/dist/layout/collaboration.js +152 -0
  144. package/dist/layout/di.d.ts +15 -0
  145. package/dist/layout/di.js +52 -0
  146. package/dist/layout/extract.d.ts +2 -0
  147. package/dist/layout/extract.js +99 -0
  148. package/dist/layout/lanes.d.ts +30 -0
  149. package/dist/layout/lanes.js +112 -0
  150. package/dist/layout/layering.d.ts +7 -0
  151. package/dist/layout/layering.js +53 -0
  152. package/dist/layout/layout.d.ts +12 -0
  153. package/dist/layout/layout.js +299 -0
  154. package/dist/layout/model.d.ts +52 -0
  155. package/dist/layout/model.js +10 -0
  156. package/dist/layout/placement.d.ts +25 -0
  157. package/dist/layout/placement.js +256 -0
  158. package/dist/layout/standalone.d.ts +8 -0
  159. package/dist/layout/standalone.js +50 -0
  160. package/dist/layout-cli.d.ts +1 -0
  161. package/dist/layout-cli.js +5 -0
  162. package/dist/layout-run.d.ts +9 -0
  163. package/dist/layout-run.js +105 -0
  164. package/dist/loader.d.ts +5 -0
  165. package/dist/loader.js +7 -0
  166. package/dist/namespace.d.ts +5 -0
  167. package/dist/namespace.js +5 -0
  168. package/dist/ontology.d.ts +19 -0
  169. package/dist/ontology.js +94 -0
  170. package/dist/paths.d.ts +1 -0
  171. package/dist/paths.js +2 -0
  172. package/dist/render/geometry.d.ts +40 -0
  173. package/dist/render/geometry.js +81 -0
  174. package/dist/render/renderer.d.ts +31 -0
  175. package/dist/render/renderer.js +369 -0
  176. package/dist/render/symbols.d.ts +10 -0
  177. package/dist/render/symbols.js +26 -0
  178. package/dist/render/text.d.ts +20 -0
  179. package/dist/render/text.js +28 -0
  180. package/dist/render-cli.d.ts +1 -0
  181. package/dist/render-cli.js +7 -0
  182. package/dist/render-run.d.ts +9 -0
  183. package/dist/render-run.js +161 -0
  184. package/dist/render.d.ts +4 -0
  185. package/dist/render.js +4 -0
  186. package/dist/schema-overrides.d.ts +14 -0
  187. package/dist/schema-overrides.js +36 -0
  188. package/dist/schema-validate.d.ts +5 -0
  189. package/dist/schema-validate.js +8 -0
  190. package/dist/schema.d.ts +6 -0
  191. package/dist/schema.js +114 -0
  192. package/dist/shacl.d.ts +15 -0
  193. package/dist/shacl.js +37 -0
  194. package/dist/validate-cli.d.ts +1 -0
  195. package/dist/validate-cli.js +5 -0
  196. package/dist/validate-run.d.ts +8 -0
  197. package/dist/validate-run.js +58 -0
  198. package/dist/validate.d.ts +11 -0
  199. package/dist/validate.js +94 -0
  200. package/dist/versioning-cli.d.ts +1 -0
  201. package/dist/versioning-cli.js +18 -0
  202. package/dist/versioning.d.ts +17 -0
  203. package/dist/versioning.js +45 -0
  204. package/ontology/core.ttl +993 -0
  205. package/ontology/di.ttl +167 -0
  206. package/package.json +76 -4
  207. package/schema/bpmn-ld.schema.json +15230 -0
  208. package/shapes/core.shapes.ttl +398 -0
  209. package/skills/bpmn-ld/SKILL.md +154 -0
  210. package/skills/bpmn-ld/evals/models/order-approval-di.jsonld +296 -0
  211. package/skills/bpmn-ld/evals/models/refund-di.bpmn +82 -0
  212. package/skills/bpmn-ld/evals/models/refund.bpmn +18 -0
  213. package/skills/bpmn-ld/evals/outputs/explain-collaboration.md +22 -0
  214. package/skills/bpmn-ld/evals/outputs/explain-order-approval.md +24 -0
  215. package/skills/bpmn-ld/evals/outputs/explain-refund.md +17 -0
  216. package/skills/bpmn-ld/evals/outputs/generate-activity-compensation.jsonld +39 -0
  217. package/skills/bpmn-ld/evals/outputs/generate-ad-hoc-sub-process.jsonld +52 -0
  218. package/skills/bpmn-ld/evals/outputs/generate-boundary-event.jsonld +27 -0
  219. package/skills/bpmn-ld/evals/outputs/generate-collaboration.jsonld +49 -0
  220. package/skills/bpmn-ld/evals/outputs/generate-conditions.jsonld +93 -0
  221. package/skills/bpmn-ld/evals/outputs/generate-diagram-properties.jsonld +340 -0
  222. package/skills/bpmn-ld/evals/outputs/generate-error.jsonld +217 -0
  223. package/skills/bpmn-ld/evals/outputs/generate-escalation.jsonld +231 -0
  224. package/skills/bpmn-ld/evals/outputs/generate-event-definition-ref.jsonld +67 -0
  225. package/skills/bpmn-ld/evals/outputs/generate-event-sub-process.jsonld +54 -0
  226. package/skills/bpmn-ld/evals/outputs/generate-exclusive-choice.jsonld +32 -0
  227. package/skills/bpmn-ld/evals/outputs/generate-instantiating-gateway.jsonld +24 -0
  228. package/skills/bpmn-ld/evals/outputs/generate-lane-partition.jsonld +46 -0
  229. package/skills/bpmn-ld/evals/outputs/generate-link-event.expect.json +11 -0
  230. package/skills/bpmn-ld/evals/outputs/generate-link-event.jsonld +57 -0
  231. package/skills/bpmn-ld/evals/outputs/generate-loop.jsonld +30 -0
  232. package/skills/bpmn-ld/evals/outputs/generate-message.jsonld +61 -0
  233. package/skills/bpmn-ld/evals/outputs/generate-parallel-branches.jsonld +25 -0
  234. package/skills/bpmn-ld/evals/outputs/generate-process-attributes.jsonld +49 -0
  235. package/skills/bpmn-ld/evals/outputs/generate-script-task.jsonld +18 -0
  236. package/skills/bpmn-ld/evals/outputs/generate-signal.jsonld +178 -0
  237. package/skills/bpmn-ld/evals/outputs/generate-sub-process.jsonld +31 -0
  238. package/skills/bpmn-ld/evals/outputs/generate-targeted-compensation.jsonld +40 -0
  239. package/skills/bpmn-ld/evals/outputs/generate-task-implementation.jsonld +18 -0
  240. package/skills/bpmn-ld/evals/outputs/generate-task-message-references.jsonld +49 -0
  241. package/skills/bpmn-ld/evals/outputs/generate-transaction.jsonld +48 -0
  242. package/skills/bpmn-ld/evals/outputs/modify-order-approval.jsonld +376 -0
  243. package/skills/bpmn-ld/evals/outputs/modify-refund.jsonld +373 -0
  244. package/skills/bpmn-ld/evals/outputs/order-approval.jsonld +29 -0
  245. package/skills/bpmn-ld/evals/outputs/refine-order-approval.jsonld +377 -0
  246. package/skills/bpmn-ld/evals/prompts/explain-collaboration.md +3 -0
  247. package/skills/bpmn-ld/evals/prompts/explain-order-approval.md +3 -0
  248. package/skills/bpmn-ld/evals/prompts/explain-refund.md +3 -0
  249. package/skills/bpmn-ld/evals/prompts/generate-activity-compensation.md +1 -0
  250. package/skills/bpmn-ld/evals/prompts/generate-ad-hoc-sub-process.md +1 -0
  251. package/skills/bpmn-ld/evals/prompts/generate-boundary-event.md +1 -0
  252. package/skills/bpmn-ld/evals/prompts/generate-collaboration.md +1 -0
  253. package/skills/bpmn-ld/evals/prompts/generate-conditions.md +1 -0
  254. package/skills/bpmn-ld/evals/prompts/generate-diagram-properties.md +1 -0
  255. package/skills/bpmn-ld/evals/prompts/generate-error.md +1 -0
  256. package/skills/bpmn-ld/evals/prompts/generate-escalation.md +1 -0
  257. package/skills/bpmn-ld/evals/prompts/generate-event-definition-ref.md +1 -0
  258. package/skills/bpmn-ld/evals/prompts/generate-event-sub-process.md +1 -0
  259. package/skills/bpmn-ld/evals/prompts/generate-exclusive-choice.md +1 -0
  260. package/skills/bpmn-ld/evals/prompts/generate-instantiating-gateway.md +1 -0
  261. package/skills/bpmn-ld/evals/prompts/generate-lane-partition.md +1 -0
  262. package/skills/bpmn-ld/evals/prompts/generate-link-event.md +1 -0
  263. package/skills/bpmn-ld/evals/prompts/generate-loop.md +1 -0
  264. package/skills/bpmn-ld/evals/prompts/generate-message.md +1 -0
  265. package/skills/bpmn-ld/evals/prompts/generate-parallel-branches.md +1 -0
  266. package/skills/bpmn-ld/evals/prompts/generate-process-attributes.md +1 -0
  267. package/skills/bpmn-ld/evals/prompts/generate-script-task.md +1 -0
  268. package/skills/bpmn-ld/evals/prompts/generate-signal.md +1 -0
  269. package/skills/bpmn-ld/evals/prompts/generate-sub-process.md +1 -0
  270. package/skills/bpmn-ld/evals/prompts/generate-targeted-compensation.md +1 -0
  271. package/skills/bpmn-ld/evals/prompts/generate-task-implementation.md +1 -0
  272. package/skills/bpmn-ld/evals/prompts/generate-task-message-references.md +1 -0
  273. package/skills/bpmn-ld/evals/prompts/generate-transaction.md +1 -0
  274. package/skills/bpmn-ld/evals/prompts/modify-order-approval.md +4 -0
  275. package/skills/bpmn-ld/evals/prompts/modify-refund.md +4 -0
  276. package/skills/bpmn-ld/evals/prompts/order-approval.md +1 -0
  277. package/skills/bpmn-ld/evals/prompts/refine-order-approval.md +8 -0
  278. package/skills/bpmn-ld/examples/positive/activity-compensation.jsonld +39 -0
  279. package/skills/bpmn-ld/examples/positive/ad-hoc-sub-process.jsonld +52 -0
  280. package/skills/bpmn-ld/examples/positive/boundary-event.jsonld +27 -0
  281. package/skills/bpmn-ld/examples/positive/collaboration.jsonld +49 -0
  282. package/skills/bpmn-ld/examples/positive/conditions.jsonld +93 -0
  283. package/skills/bpmn-ld/examples/positive/diagram-properties.jsonld +340 -0
  284. package/skills/bpmn-ld/examples/positive/error.jsonld +208 -0
  285. package/skills/bpmn-ld/examples/positive/escalation.jsonld +231 -0
  286. package/skills/bpmn-ld/examples/positive/event-definition-ref.jsonld +142 -0
  287. package/skills/bpmn-ld/examples/positive/event-sub-process.jsonld +54 -0
  288. package/skills/bpmn-ld/examples/positive/exclusive-choice.jsonld +32 -0
  289. package/skills/bpmn-ld/examples/positive/instantiating-gateway.jsonld +24 -0
  290. package/skills/bpmn-ld/examples/positive/lane-partition.jsonld +46 -0
  291. package/skills/bpmn-ld/examples/positive/link-event.expect.json +10 -0
  292. package/skills/bpmn-ld/examples/positive/link-event.jsonld +138 -0
  293. package/skills/bpmn-ld/examples/positive/loop.jsonld +30 -0
  294. package/skills/bpmn-ld/examples/positive/message.jsonld +60 -0
  295. package/skills/bpmn-ld/examples/positive/order-approval.jsonld +29 -0
  296. package/skills/bpmn-ld/examples/positive/parallel-branches.jsonld +25 -0
  297. package/skills/bpmn-ld/examples/positive/process-attributes.jsonld +49 -0
  298. package/skills/bpmn-ld/examples/positive/script-task.jsonld +18 -0
  299. package/skills/bpmn-ld/examples/positive/signal.jsonld +150 -0
  300. package/skills/bpmn-ld/examples/positive/sub-process.jsonld +31 -0
  301. package/skills/bpmn-ld/examples/positive/targeted-compensation.jsonld +40 -0
  302. package/skills/bpmn-ld/examples/positive/task-implementation.jsonld +18 -0
  303. package/skills/bpmn-ld/examples/positive/task-message-references.jsonld +151 -0
  304. package/skills/bpmn-ld/examples/positive/transaction.jsonld +48 -0
  305. package/skills/bpmn-ld/references/clarification-and-refinement.md +60 -0
  306. package/skills/bpmn-ld/references/common-mistakes.md +110 -0
  307. package/skills/bpmn-ld/references/explain-and-document.md +36 -0
  308. package/skills/bpmn-ld/references/modify-existing-model.md +49 -0
  309. package/skills/bpmn-ld/references/patterns.md +292 -0
  310. package/skills/bpmn-ld/references/render-output.md +1 -0
  311. package/skills/bpmn-ld/references/rule-catalogue.md +183 -0
  312. package/skills/bpmn-ld/references/vocabulary-summary.md +65 -0
  313. package/skills/bpmn-ld/template.jsonld +14 -0
  314. package/templates/combined.jsonld +3 -0
  315. package/templates/core.jsonld +170 -0
  316. package/templates/core.shapes.ttl +398 -0
  317. package/templates/core.ttl +993 -0
  318. package/templates/di.jsonld +37 -0
  319. package/templates/di.ttl +167 -0
@@ -0,0 +1,93 @@
1
+ {
2
+ "@context": [
3
+ "../../../../contexts/core.jsonld",
4
+ {
5
+ "@base": "https://example.org/models/conditions/"
6
+ }
7
+ ],
8
+ "@graph": [
9
+ {
10
+ "id": "Process_Intake",
11
+ "type": "Process",
12
+ "name": "Application intake",
13
+ "flowElements": [
14
+ {
15
+ "id": "ApplicationSubmitted",
16
+ "type": "StartEvent",
17
+ "name": "Application submitted"
18
+ },
19
+ {
20
+ "id": "CheckIncome",
21
+ "type": "UserTask",
22
+ "name": "Check income"
23
+ },
24
+ {
25
+ "id": "AwaitLimit",
26
+ "type": "IntermediateCatchEvent",
27
+ "name": "Credit limit approved",
28
+ "eventDefinitions": [
29
+ {
30
+ "id": "LimitApprovedCondition",
31
+ "type": "ConditionalEventDefinition",
32
+ "condition": {
33
+ "type": "FormalExpression",
34
+ "language": "https://www.w3.org/TR/xpath20/",
35
+ "body": "applicant/creditLimit > 0"
36
+ }
37
+ }
38
+ ]
39
+ },
40
+ {
41
+ "id": "WithdrawnWhileChecking",
42
+ "type": "BoundaryEvent",
43
+ "name": "Application withdrawn",
44
+ "attachedToRef": "CheckIncome",
45
+ "eventDefinitions": [
46
+ {
47
+ "id": "WithdrawnCondition",
48
+ "type": "ConditionalEventDefinition",
49
+ "condition": {
50
+ "type": "FormalExpression",
51
+ "body": "application/withdrawn"
52
+ }
53
+ }
54
+ ]
55
+ },
56
+ {
57
+ "id": "ApplicationAccepted",
58
+ "type": "EndEvent",
59
+ "name": "Application accepted"
60
+ },
61
+ {
62
+ "id": "ApplicationDropped",
63
+ "type": "EndEvent",
64
+ "name": "Application dropped"
65
+ },
66
+ {
67
+ "id": "Flow_1",
68
+ "type": "SequenceFlow",
69
+ "sourceRef": "ApplicationSubmitted",
70
+ "targetRef": "CheckIncome"
71
+ },
72
+ {
73
+ "id": "Flow_2",
74
+ "type": "SequenceFlow",
75
+ "sourceRef": "CheckIncome",
76
+ "targetRef": "AwaitLimit"
77
+ },
78
+ {
79
+ "id": "Flow_3",
80
+ "type": "SequenceFlow",
81
+ "sourceRef": "AwaitLimit",
82
+ "targetRef": "ApplicationAccepted"
83
+ },
84
+ {
85
+ "id": "Flow_4",
86
+ "type": "SequenceFlow",
87
+ "sourceRef": "WithdrawnWhileChecking",
88
+ "targetRef": "ApplicationDropped"
89
+ }
90
+ ]
91
+ }
92
+ ]
93
+ }
@@ -0,0 +1,340 @@
1
+ {
2
+ "@context": [
3
+ "../../../../contexts/core.jsonld",
4
+ "../../../../contexts/di.jsonld",
5
+ {
6
+ "@base": "https://example.org/models/order-exchange/"
7
+ }
8
+ ],
9
+ "@graph": [
10
+ {
11
+ "id": "Collaboration_1",
12
+ "type": "Collaboration",
13
+ "participants": [
14
+ {
15
+ "id": "Participant_Customer",
16
+ "type": "Participant",
17
+ "name": "Customer",
18
+ "processRef": "Process_Customer"
19
+ },
20
+ {
21
+ "id": "Participant_Shop",
22
+ "type": "Participant",
23
+ "name": "Shop",
24
+ "processRef": "Process_Shop"
25
+ }
26
+ ],
27
+ "messageFlows": [
28
+ {
29
+ "id": "MessageFlow_Order",
30
+ "type": "MessageFlow",
31
+ "name": "Order",
32
+ "sourceRef": "SendOrder",
33
+ "targetRef": "ReceiveOrder"
34
+ },
35
+ {
36
+ "id": "MessageFlow_Confirmation",
37
+ "type": "MessageFlow",
38
+ "name": "Confirmation",
39
+ "sourceRef": "Participant_Shop",
40
+ "targetRef": "Participant_Customer"
41
+ }
42
+ ]
43
+ },
44
+ {
45
+ "id": "Process_Customer",
46
+ "type": "Process",
47
+ "name": "Customer process",
48
+ "flowElements": [
49
+ {
50
+ "id": "CustomerStart",
51
+ "type": "StartEvent",
52
+ "name": "Needs goods"
53
+ },
54
+ {
55
+ "id": "SendOrder",
56
+ "type": "SendTask",
57
+ "name": "Send order"
58
+ },
59
+ {
60
+ "id": "CustomerEnd",
61
+ "type": "EndEvent",
62
+ "name": "Goods ordered"
63
+ },
64
+ {
65
+ "id": "CustomerFlow_1",
66
+ "type": "SequenceFlow",
67
+ "sourceRef": "CustomerStart",
68
+ "targetRef": "SendOrder"
69
+ },
70
+ {
71
+ "id": "CustomerFlow_2",
72
+ "type": "SequenceFlow",
73
+ "sourceRef": "SendOrder",
74
+ "targetRef": "CustomerEnd"
75
+ }
76
+ ]
77
+ },
78
+ {
79
+ "id": "Process_Shop",
80
+ "type": "Process",
81
+ "name": "Shop process",
82
+ "flowElements": [
83
+ {
84
+ "id": "ShopStart",
85
+ "type": "StartEvent",
86
+ "name": "Shop open"
87
+ },
88
+ {
89
+ "id": "ReceiveOrder",
90
+ "type": "ReceiveTask",
91
+ "name": "Receive order"
92
+ },
93
+ {
94
+ "id": "ShopEnd",
95
+ "type": "EndEvent",
96
+ "name": "Order accepted"
97
+ },
98
+ {
99
+ "id": "ShopFlow_1",
100
+ "type": "SequenceFlow",
101
+ "sourceRef": "ShopStart",
102
+ "targetRef": "ReceiveOrder"
103
+ },
104
+ {
105
+ "id": "ShopFlow_2",
106
+ "type": "SequenceFlow",
107
+ "sourceRef": "ReceiveOrder",
108
+ "targetRef": "ShopEnd"
109
+ }
110
+ ]
111
+ },
112
+ {
113
+ "id": "Diagram_Collaboration_1",
114
+ "type": "BPMNDiagram",
115
+ "name": "Order exchange",
116
+ "resolution": 96,
117
+ "plane": {
118
+ "id": "Plane_Collaboration_1",
119
+ "type": "BPMNPlane",
120
+ "bpmnElement": "Collaboration_1",
121
+ "planeElements": [
122
+ {
123
+ "id": "Shape_Participant_Customer",
124
+ "type": "BPMNShape",
125
+ "bpmnElement": "Participant_Customer",
126
+ "isHorizontal": true,
127
+ "bounds": {
128
+ "type": "Bounds",
129
+ "x": 100,
130
+ "y": 100,
131
+ "width": 362,
132
+ "height": 120
133
+ }
134
+ },
135
+ {
136
+ "id": "Shape_CustomerStart",
137
+ "type": "BPMNShape",
138
+ "bpmnElement": "CustomerStart",
139
+ "bounds": {
140
+ "type": "Bounds",
141
+ "x": 150,
142
+ "y": 142,
143
+ "width": 36,
144
+ "height": 36
145
+ }
146
+ },
147
+ {
148
+ "id": "Shape_SendOrder",
149
+ "type": "BPMNShape",
150
+ "bpmnElement": "SendOrder",
151
+ "bounds": {
152
+ "type": "Bounds",
153
+ "x": 246,
154
+ "y": 120,
155
+ "width": 100,
156
+ "height": 80
157
+ }
158
+ },
159
+ {
160
+ "id": "Shape_CustomerEnd",
161
+ "type": "BPMNShape",
162
+ "bpmnElement": "CustomerEnd",
163
+ "bounds": {
164
+ "type": "Bounds",
165
+ "x": 406,
166
+ "y": 142,
167
+ "width": 36,
168
+ "height": 36
169
+ }
170
+ },
171
+ {
172
+ "id": "Shape_Participant_Shop",
173
+ "type": "BPMNShape",
174
+ "bpmnElement": "Participant_Shop",
175
+ "isHorizontal": true,
176
+ "bounds": {
177
+ "type": "Bounds",
178
+ "x": 100,
179
+ "y": 270,
180
+ "width": 362,
181
+ "height": 120
182
+ }
183
+ },
184
+ {
185
+ "id": "Shape_ShopStart",
186
+ "type": "BPMNShape",
187
+ "bpmnElement": "ShopStart",
188
+ "bounds": {
189
+ "type": "Bounds",
190
+ "x": 150,
191
+ "y": 312,
192
+ "width": 36,
193
+ "height": 36
194
+ }
195
+ },
196
+ {
197
+ "id": "Shape_ReceiveOrder",
198
+ "type": "BPMNShape",
199
+ "bpmnElement": "ReceiveOrder",
200
+ "bounds": {
201
+ "type": "Bounds",
202
+ "x": 246,
203
+ "y": 290,
204
+ "width": 100,
205
+ "height": 80
206
+ }
207
+ },
208
+ {
209
+ "id": "Shape_ShopEnd",
210
+ "type": "BPMNShape",
211
+ "bpmnElement": "ShopEnd",
212
+ "bounds": {
213
+ "type": "Bounds",
214
+ "x": 406,
215
+ "y": 312,
216
+ "width": 36,
217
+ "height": 36
218
+ }
219
+ },
220
+ {
221
+ "id": "Edge_CustomerFlow_1",
222
+ "type": "BPMNEdge",
223
+ "bpmnElement": "CustomerFlow_1",
224
+ "sourceElement": "Shape_CustomerStart",
225
+ "targetElement": "Shape_SendOrder",
226
+ "waypoints": [
227
+ {
228
+ "type": "Point",
229
+ "x": 186,
230
+ "y": 160
231
+ },
232
+ {
233
+ "type": "Point",
234
+ "x": 246,
235
+ "y": 160
236
+ }
237
+ ]
238
+ },
239
+ {
240
+ "id": "Edge_CustomerFlow_2",
241
+ "type": "BPMNEdge",
242
+ "bpmnElement": "CustomerFlow_2",
243
+ "sourceElement": "Shape_SendOrder",
244
+ "targetElement": "Shape_CustomerEnd",
245
+ "waypoints": [
246
+ {
247
+ "type": "Point",
248
+ "x": 346,
249
+ "y": 160
250
+ },
251
+ {
252
+ "type": "Point",
253
+ "x": 406,
254
+ "y": 160
255
+ }
256
+ ]
257
+ },
258
+ {
259
+ "id": "Edge_ShopFlow_1",
260
+ "type": "BPMNEdge",
261
+ "bpmnElement": "ShopFlow_1",
262
+ "sourceElement": "Shape_ShopStart",
263
+ "targetElement": "Shape_ReceiveOrder",
264
+ "waypoints": [
265
+ {
266
+ "type": "Point",
267
+ "x": 186,
268
+ "y": 330
269
+ },
270
+ {
271
+ "type": "Point",
272
+ "x": 246,
273
+ "y": 330
274
+ }
275
+ ]
276
+ },
277
+ {
278
+ "id": "Edge_ShopFlow_2",
279
+ "type": "BPMNEdge",
280
+ "bpmnElement": "ShopFlow_2",
281
+ "sourceElement": "Shape_ReceiveOrder",
282
+ "targetElement": "Shape_ShopEnd",
283
+ "waypoints": [
284
+ {
285
+ "type": "Point",
286
+ "x": 346,
287
+ "y": 330
288
+ },
289
+ {
290
+ "type": "Point",
291
+ "x": 406,
292
+ "y": 330
293
+ }
294
+ ]
295
+ },
296
+ {
297
+ "id": "Edge_MessageFlow_Order",
298
+ "type": "BPMNEdge",
299
+ "bpmnElement": "MessageFlow_Order",
300
+ "sourceElement": "Shape_SendOrder",
301
+ "targetElement": "Shape_ReceiveOrder",
302
+ "waypoints": [
303
+ {
304
+ "type": "Point",
305
+ "x": 296,
306
+ "y": 200
307
+ },
308
+ {
309
+ "type": "Point",
310
+ "x": 296,
311
+ "y": 290
312
+ }
313
+ ],
314
+ "messageVisibleKind": "initiating"
315
+ },
316
+ {
317
+ "id": "Edge_MessageFlow_Confirmation",
318
+ "type": "BPMNEdge",
319
+ "bpmnElement": "MessageFlow_Confirmation",
320
+ "sourceElement": "Shape_Participant_Shop",
321
+ "targetElement": "Shape_Participant_Customer",
322
+ "waypoints": [
323
+ {
324
+ "type": "Point",
325
+ "x": 281,
326
+ "y": 270
327
+ },
328
+ {
329
+ "type": "Point",
330
+ "x": 281,
331
+ "y": 220
332
+ }
333
+ ],
334
+ "messageVisibleKind": "non_initiating"
335
+ }
336
+ ]
337
+ }
338
+ }
339
+ ]
340
+ }
@@ -0,0 +1,217 @@
1
+ {
2
+ "@context": [
3
+ "../../../../contexts/core.jsonld",
4
+ {
5
+ "@base": "https://example.org/models/error-payment/"
6
+ }
7
+ ],
8
+ "@graph": [
9
+ {
10
+ "id": "Error_CardExpired",
11
+ "type": "Error",
12
+ "name": "Card expired",
13
+ "errorCode": "CARD_EXPIRED"
14
+ },
15
+ {
16
+ "id": "Error_PaymentDeclined",
17
+ "type": "Error",
18
+ "name": "Payment declined",
19
+ "errorCode": "PAYMENT_DECLINED"
20
+ },
21
+ {
22
+ "id": "Process_Payment",
23
+ "type": "Process",
24
+ "name": "Payment process",
25
+ "flowElements": [
26
+ {
27
+ "id": "PaymentRequested",
28
+ "type": "StartEvent",
29
+ "name": "Payment requested"
30
+ },
31
+ {
32
+ "id": "ChargeCard",
33
+ "type": "SubProcess",
34
+ "name": "Charge card",
35
+ "flowElements": [
36
+ {
37
+ "id": "ChargeStart",
38
+ "type": "StartEvent",
39
+ "name": "Start charge"
40
+ },
41
+ {
42
+ "id": "AuthoriseCard",
43
+ "type": "UserTask",
44
+ "name": "Authorise card"
45
+ },
46
+ {
47
+ "id": "AuthorisationResult",
48
+ "type": "ExclusiveGateway",
49
+ "name": "Authorisation result",
50
+ "default": "ChargeFlow_4"
51
+ },
52
+ {
53
+ "id": "DeclinedEnd",
54
+ "type": "EndEvent",
55
+ "name": "Payment declined",
56
+ "eventDefinitions": [
57
+ {
58
+ "type": "ErrorEventDefinition",
59
+ "errorRef": "Error_PaymentDeclined"
60
+ }
61
+ ]
62
+ },
63
+ {
64
+ "id": "ExpiredEnd",
65
+ "type": "EndEvent",
66
+ "name": "Card expired",
67
+ "eventDefinitions": [
68
+ {
69
+ "type": "ErrorEventDefinition",
70
+ "errorRef": "Error_CardExpired"
71
+ }
72
+ ]
73
+ },
74
+ {
75
+ "id": "ChargeEnd",
76
+ "type": "EndEvent",
77
+ "name": "Charged"
78
+ },
79
+ {
80
+ "id": "ChargeFlow_1",
81
+ "type": "SequenceFlow",
82
+ "sourceRef": "ChargeStart",
83
+ "targetRef": "AuthoriseCard"
84
+ },
85
+ {
86
+ "id": "ChargeFlow_2",
87
+ "type": "SequenceFlow",
88
+ "sourceRef": "AuthoriseCard",
89
+ "targetRef": "AuthorisationResult"
90
+ },
91
+ {
92
+ "id": "ChargeFlow_3",
93
+ "type": "SequenceFlow",
94
+ "name": "Declined",
95
+ "sourceRef": "AuthorisationResult",
96
+ "targetRef": "DeclinedEnd",
97
+ "conditionExpression": {
98
+ "type": "FormalExpression",
99
+ "body": "declined"
100
+ }
101
+ },
102
+ {
103
+ "id": "ChargeFlow_4",
104
+ "type": "SequenceFlow",
105
+ "name": "Authorised",
106
+ "sourceRef": "AuthorisationResult",
107
+ "targetRef": "ChargeEnd"
108
+ },
109
+ {
110
+ "id": "ChargeFlow_5",
111
+ "type": "SequenceFlow",
112
+ "name": "Expired",
113
+ "sourceRef": "AuthorisationResult",
114
+ "targetRef": "ExpiredEnd",
115
+ "conditionExpression": {
116
+ "type": "FormalExpression",
117
+ "body": "expired"
118
+ }
119
+ }
120
+ ]
121
+ },
122
+ {
123
+ "id": "DeclinedCaught",
124
+ "type": "BoundaryEvent",
125
+ "name": "Payment declined",
126
+ "attachedToRef": "ChargeCard",
127
+ "eventDefinitions": [
128
+ {
129
+ "type": "ErrorEventDefinition",
130
+ "errorRef": "Error_PaymentDeclined"
131
+ }
132
+ ]
133
+ },
134
+ {
135
+ "id": "NotifyCustomer",
136
+ "type": "UserTask",
137
+ "name": "Notify customer"
138
+ },
139
+ {
140
+ "id": "PaymentTaken",
141
+ "type": "EndEvent",
142
+ "name": "Payment taken"
143
+ },
144
+ {
145
+ "id": "PaymentRefused",
146
+ "type": "EndEvent",
147
+ "name": "Payment refused"
148
+ },
149
+ {
150
+ "id": "ExpiredHandling",
151
+ "type": "SubProcess",
152
+ "name": "Handle expired card",
153
+ "triggeredByEvent": true,
154
+ "flowElements": [
155
+ {
156
+ "id": "ExpiredCaught",
157
+ "type": "StartEvent",
158
+ "name": "Card expired",
159
+ "eventDefinitions": [
160
+ {
161
+ "type": "ErrorEventDefinition",
162
+ "errorRef": "Error_CardExpired"
163
+ }
164
+ ]
165
+ },
166
+ {
167
+ "id": "RequestNewCard",
168
+ "type": "UserTask",
169
+ "name": "Request new card"
170
+ },
171
+ {
172
+ "id": "ExpiredHandled",
173
+ "type": "EndEvent",
174
+ "name": "New card requested"
175
+ },
176
+ {
177
+ "id": "ExpiredFlow_1",
178
+ "type": "SequenceFlow",
179
+ "sourceRef": "ExpiredCaught",
180
+ "targetRef": "RequestNewCard"
181
+ },
182
+ {
183
+ "id": "ExpiredFlow_2",
184
+ "type": "SequenceFlow",
185
+ "sourceRef": "RequestNewCard",
186
+ "targetRef": "ExpiredHandled"
187
+ }
188
+ ]
189
+ },
190
+ {
191
+ "id": "PaymentFlow_1",
192
+ "type": "SequenceFlow",
193
+ "sourceRef": "PaymentRequested",
194
+ "targetRef": "ChargeCard"
195
+ },
196
+ {
197
+ "id": "PaymentFlow_2",
198
+ "type": "SequenceFlow",
199
+ "sourceRef": "ChargeCard",
200
+ "targetRef": "PaymentTaken"
201
+ },
202
+ {
203
+ "id": "PaymentFlow_3",
204
+ "type": "SequenceFlow",
205
+ "sourceRef": "DeclinedCaught",
206
+ "targetRef": "NotifyCustomer"
207
+ },
208
+ {
209
+ "id": "PaymentFlow_4",
210
+ "type": "SequenceFlow",
211
+ "sourceRef": "NotifyCustomer",
212
+ "targetRef": "PaymentRefused"
213
+ }
214
+ ]
215
+ }
216
+ ]
217
+ }