@adaas/a-concept 0.0.28 → 0.0.30

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 (179) hide show
  1. package/dist/examples/fe-be/channels/Test.channel.d.ts +6 -0
  2. package/dist/examples/fe-be/channels/Test.channel.js +14 -0
  3. package/dist/examples/fe-be/channels/Test.channel.js.map +1 -0
  4. package/dist/examples/fe-be/components/BE-Controller.component.d.ts +4 -0
  5. package/dist/examples/fe-be/components/BE-Controller.component.js +24 -0
  6. package/dist/examples/fe-be/components/BE-Controller.component.js.map +1 -0
  7. package/dist/examples/fe-be/components/FE.component.d.ts +4 -0
  8. package/dist/examples/fe-be/components/FE.component.js +31 -0
  9. package/dist/examples/fe-be/components/FE.component.js.map +1 -0
  10. package/dist/examples/fe-be/components/UserActions.component.d.ts +5 -0
  11. package/dist/examples/fe-be/components/UserActions.component.js +25 -0
  12. package/dist/examples/fe-be/components/UserActions.component.js.map +1 -0
  13. package/dist/examples/fe-be/concept.d.ts +0 -0
  14. package/dist/examples/fe-be/concept.js +2 -0
  15. package/dist/examples/fe-be/concept.js.map +1 -0
  16. package/dist/examples/fe-be/containers/ServerApp.container.d.ts +3 -0
  17. package/dist/examples/fe-be/containers/ServerApp.container.js +8 -0
  18. package/dist/examples/fe-be/containers/ServerApp.container.js.map +1 -0
  19. package/dist/examples/fe-be/containers/WebApp.container.d.ts +3 -0
  20. package/dist/examples/fe-be/containers/WebApp.container.js +8 -0
  21. package/dist/examples/fe-be/containers/WebApp.container.js.map +1 -0
  22. package/dist/examples/multi-container/channels/Direct.channel.d.ts +9 -0
  23. package/dist/examples/multi-container/channels/Direct.channel.js +32 -0
  24. package/dist/examples/multi-container/channels/Direct.channel.js.map +1 -0
  25. package/dist/examples/multi-container/concept.d.ts +0 -0
  26. package/dist/examples/multi-container/concept.js +2 -0
  27. package/dist/examples/multi-container/concept.js.map +1 -0
  28. package/dist/examples/multi-container/containers/Command.container.d.ts +11 -0
  29. package/dist/examples/multi-container/containers/Command.container.js +51 -0
  30. package/dist/examples/multi-container/containers/Command.container.js.map +1 -0
  31. package/dist/examples/multi-container/containers/Schedule.container.d.ts +15 -0
  32. package/dist/examples/multi-container/containers/Schedule.container.js +67 -0
  33. package/dist/examples/multi-container/containers/Schedule.container.js.map +1 -0
  34. package/dist/examples/simple/components/A.component.js.map +1 -1
  35. package/dist/examples/simple/containers/Main.container.js +7 -3
  36. package/dist/examples/simple/containers/Main.container.js.map +1 -1
  37. package/dist/examples/simple/entities/EntityA.entity.d.ts +8 -0
  38. package/dist/examples/simple/entities/EntityA.entity.js +22 -0
  39. package/dist/examples/simple/entities/EntityA.entity.js.map +1 -0
  40. package/dist/examples/simple-http-server/contexts/http-request.context.d.ts +0 -1
  41. package/dist/examples/simple-http-server/contexts/http-request.context.js +6 -8
  42. package/dist/examples/simple-http-server/contexts/http-request.context.js.map +1 -1
  43. package/dist/index.d.ts +8 -2
  44. package/dist/index.js +16 -7
  45. package/dist/index.js.map +1 -1
  46. package/dist/src/base/A-Config/components/ConfigReader.component.d.ts +2 -1
  47. package/dist/src/base/A-Config/components/ConfigReader.component.js +12 -12
  48. package/dist/src/base/A-Config/components/ConfigReader.component.js.map +1 -1
  49. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.d.ts +14 -0
  50. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.js +53 -0
  51. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.js.map +1 -0
  52. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.types.d.ts +2 -0
  53. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.types.js +3 -0
  54. package/dist/src/decorators/A-Abstraction/A-Abstraction.decorator.types.js.map +1 -0
  55. package/dist/src/decorators/A-Connect/A-Connect.decorator.d.ts +19 -0
  56. package/dist/src/decorators/A-Connect/A-Connect.decorator.js +31 -0
  57. package/dist/src/decorators/A-Connect/A-Connect.decorator.js.map +1 -0
  58. package/dist/src/decorators/A-Connect/A-Connect.decorator.types.d.ts +1 -0
  59. package/dist/src/decorators/A-Connect/A-Connect.decorator.types.js +3 -0
  60. package/dist/src/decorators/A-Connect/A-Connect.decorator.types.js.map +1 -0
  61. package/dist/src/decorators/A-Entity/A-Entity-List.decorator.d.ts +1 -0
  62. package/dist/src/decorators/A-Entity/A-Entity-List.decorator.js +8 -0
  63. package/dist/src/decorators/A-Entity/A-Entity-List.decorator.js.map +1 -0
  64. package/dist/src/decorators/A-Entity/A-Entity.decorator.types.d.ts +14 -0
  65. package/dist/src/decorators/A-Entity/A-Entity.decorator.types.js +3 -0
  66. package/dist/src/decorators/A-Entity/A-Entity.decorator.types.js.map +1 -0
  67. package/dist/src/decorators/A-Feature/A-Feature-Extend.decorator.js +9 -0
  68. package/dist/src/decorators/A-Feature/A-Feature-Extend.decorator.js.map +1 -1
  69. package/dist/src/decorators/A-Feature/A-Feature.decorator.types.d.ts +28 -0
  70. package/dist/src/decorators/A-Inject/A-Inject.decorator.d.ts +2 -3
  71. package/dist/src/decorators/A-Inject/A-Inject.decorator.js.map +1 -1
  72. package/dist/src/decorators/A-Inject/A-Inject.decorator.types.d.ts +44 -0
  73. package/dist/src/global/A-Channel/A-Channel.class.d.ts +8 -10
  74. package/dist/src/global/A-Channel/A-Channel.class.js +12 -26
  75. package/dist/src/global/A-Channel/A-Channel.class.js.map +1 -1
  76. package/dist/src/global/A-Channel/A-Channel.types.d.ts +32 -0
  77. package/dist/src/global/A-Component/A-Component.class.d.ts +2 -1
  78. package/dist/src/global/A-Component/A-Component.class.js +1 -0
  79. package/dist/src/global/A-Component/A-Component.class.js.map +1 -1
  80. package/dist/src/global/A-Component/A-Component.meta.d.ts +8 -0
  81. package/dist/src/global/A-Component/A-Component.meta.js +27 -1
  82. package/dist/src/global/A-Component/A-Component.meta.js.map +1 -1
  83. package/dist/src/global/A-Component/A-Component.types.d.ts +19 -34
  84. package/dist/src/global/A-Component/A-Component.types.js +1 -7
  85. package/dist/src/global/A-Component/A-Component.types.js.map +1 -1
  86. package/dist/src/global/A-Concept/A_Concept.class.d.ts +7 -7
  87. package/dist/src/global/A-Concept/A_Concept.class.js +30 -30
  88. package/dist/src/global/A-Concept/A_Concept.class.js.map +1 -1
  89. package/dist/src/global/A-Concept/A_Concept.types.d.ts +42 -2
  90. package/dist/src/global/A-Concept/A_Concept.types.js.map +1 -1
  91. package/dist/src/global/A-Container/A-Container.class.d.ts +1 -8
  92. package/dist/src/global/A-Container/A-Container.class.js +1 -31
  93. package/dist/src/global/A-Container/A-Container.class.js.map +1 -1
  94. package/dist/src/global/A-Container/A-Container.meta.d.ts +8 -0
  95. package/dist/src/global/A-Container/A-Container.meta.js +29 -0
  96. package/dist/src/global/A-Container/A-Container.meta.js.map +1 -1
  97. package/dist/src/global/A-Container/A-Container.types.d.ts +23 -7
  98. package/dist/src/global/A-Container/A-Container.types.js +2 -1
  99. package/dist/src/global/A-Container/A-Container.types.js.map +1 -1
  100. package/dist/src/global/A-Context/A-Context.class.js +6 -35
  101. package/dist/src/global/A-Context/A-Context.class.js.map +1 -1
  102. package/dist/src/global/A-Entity/A-Entity.class.d.ts +1 -2
  103. package/dist/src/global/A-Entity/A-Entity.class.js +6 -7
  104. package/dist/src/global/A-Entity/A-Entity.class.js.map +1 -1
  105. package/dist/src/global/A-Entity/A-Entity.types.d.ts +4 -5
  106. package/dist/src/global/A-Entity/A-Entity.types.js.map +1 -1
  107. package/dist/src/global/A-Feature/A-Feature.class.d.ts +30 -6
  108. package/dist/src/global/A-Feature/A-Feature.class.js +49 -40
  109. package/dist/src/global/A-Feature/A-Feature.class.js.map +1 -1
  110. package/dist/src/global/A-Feature/A-Feature.types.d.ts +2 -24
  111. package/dist/src/global/A-Feature/A-Feature.types.js +21 -0
  112. package/dist/src/global/A-Feature/A-Feature.types.js.map +1 -1
  113. package/dist/src/global/A-Fragment/A-Fragment.class.d.ts +8 -0
  114. package/dist/src/global/A-Fragment/A-Fragment.class.js +10 -0
  115. package/dist/src/global/A-Fragment/A-Fragment.class.js.map +1 -1
  116. package/dist/src/global/A-Scope/A-Scope.class.d.ts +7 -5
  117. package/dist/src/global/A-Scope/A-Scope.class.js +33 -10
  118. package/dist/src/global/A-Scope/A-Scope.class.js.map +1 -1
  119. package/dist/src/global/A-Scope/A-Scope.types.d.ts +2 -1
  120. package/dist/src/global/A-Stage/A-Stage.class.d.ts +69 -0
  121. package/dist/src/global/A-Stage/A-Stage.class.js +176 -0
  122. package/dist/src/global/A-Stage/A-Stage.class.js.map +1 -0
  123. package/dist/src/global/A-Stage/A-Stage.types.d.ts +83 -0
  124. package/dist/src/global/A-Stage/A-Stage.types.js +59 -0
  125. package/dist/src/global/A-Stage/A-Stage.types.js.map +1 -0
  126. package/dist/src/helpers/StepsManager.class.d.ts +15 -0
  127. package/dist/src/helpers/StepsManager.class.js +85 -0
  128. package/dist/src/helpers/StepsManager.class.js.map +1 -0
  129. package/examples/fe-be/channels/Test.channel.ts +24 -0
  130. package/examples/fe-be/components/BE-Controller.component.ts +20 -0
  131. package/examples/fe-be/components/FE.component.ts +13 -0
  132. package/examples/fe-be/concept.ts +0 -0
  133. package/examples/fe-be/containers/ServerApp.container.ts +8 -0
  134. package/examples/fe-be/containers/WebApp.container.ts +13 -0
  135. package/examples/multi-container/channels/Direct.channel.ts +39 -0
  136. package/examples/multi-container/concept.ts +0 -0
  137. package/examples/multi-container/containers/Command.container.ts +41 -0
  138. package/examples/multi-container/containers/Schedule.container.ts +57 -0
  139. package/examples/simple/components/A.component.ts +2 -1
  140. package/examples/simple/containers/Main.container.ts +11 -3
  141. package/examples/simple/entities/EntityA.entity.ts +16 -0
  142. package/examples/simple-http-server/contexts/http-request.context.ts +6 -6
  143. package/index.ts +12 -3
  144. package/package.json +1 -1
  145. package/src/base/A-Config/components/ConfigReader.component.ts +12 -11
  146. package/src/decorators/A-Abstraction/A-Abstraction.decorator.ts +82 -0
  147. package/src/decorators/{A-Stage/A-Stage.decorator.types.ts → A-Abstraction/A-Abstraction.decorator.types.ts} +1 -3
  148. package/src/decorators/A-Connect/A-Connect.decorator.ts +71 -0
  149. package/src/decorators/A-Connect/A-Connect.decorator.types.ts +6 -0
  150. package/src/decorators/A-Entity/A-Entity-List.decorator.ts +12 -0
  151. package/src/decorators/A-Entity/A-Entity.decorator.types.ts +18 -0
  152. package/src/decorators/A-Feature/A-Feature-Extend.decorator.ts +10 -0
  153. package/src/decorators/A-Feature/A-Feature.decorator.types.ts +36 -0
  154. package/src/decorators/A-Inject/A-Inject.decorator.ts +7 -7
  155. package/src/decorators/A-Inject/A-Inject.decorator.types.ts +47 -1
  156. package/src/global/A-Channel/A-Channel.class.ts +25 -28
  157. package/src/global/A-Channel/A-Channel.types.ts +53 -0
  158. package/src/global/A-Component/A-Component.class.ts +10 -2
  159. package/src/global/A-Component/A-Component.meta.ts +42 -1
  160. package/src/global/A-Component/A-Component.types.ts +20 -40
  161. package/src/global/A-Concept/A_Concept.class.ts +52 -31
  162. package/src/global/A-Concept/A_Concept.types.ts +48 -3
  163. package/src/global/A-Container/A-Container.class.ts +3 -39
  164. package/src/global/A-Container/A-Container.meta.ts +41 -4
  165. package/src/global/A-Container/A-Container.types.ts +28 -7
  166. package/src/global/A-Context/A-Context.class.ts +9 -49
  167. package/src/global/A-Entity/A-Entity.class.ts +8 -6
  168. package/src/global/A-Entity/A-Entity.types.ts +4 -5
  169. package/src/global/A-Feature/A-Feature.class.ts +73 -61
  170. package/src/global/A-Feature/A-Feature.types.ts +24 -23
  171. package/src/global/A-Fragment/A-Fragment.class.ts +15 -0
  172. package/src/global/A-Scope/A-Scope.class.ts +58 -25
  173. package/src/global/A-Scope/A-Scope.types.ts +2 -1
  174. package/src/global/A-Stage/A-Stage.class.ts +225 -0
  175. package/src/global/A-Stage/A-Stage.types.ts +106 -0
  176. package/src/helpers/StepsManager.class.ts +104 -0
  177. package/tests/channel.ts +213 -0
  178. package/tests/log.ts +88 -40
  179. package/src/decorators/A-Stage/A-Stage.decorator.ts +0 -84
@@ -16,6 +16,7 @@ const A_Context_class_1 = require("../A-Context/A-Context.class");
16
16
  *
17
17
  */
18
18
  class A_Component {
19
+ constructor(params) { }
19
20
  call(scope, param1, param2) {
20
21
  return __awaiter(this, void 0, void 0, function* () {
21
22
  const feature = typeof param1 === 'string'
@@ -1 +1 @@
1
- {"version":3,"file":"A-Component.class.js","sourceRoot":"","sources":["../../../../src/global/A-Component/A-Component.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,kEAAyD;AAIzD;;;GAGG;AACH,MAAa,WAAW;IAsCd,IAAI,CACN,KAAc,EACd,MAAyH,EACzH,MAAqE;;YAGrE,MAAM,OAAO,GAAW,OAAO,MAAM,KAAK,QAAQ;gBAC9C,CAAC,CAAC,MAAM;gBACR,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;YAClB,MAAM,MAAM,GAAiE,OAAO,MAAM,KAAK,QAAQ;gBACnG,CAAC,CAAC,MAAM,IAAI,EAAE;gBACd,CAAC,CAAC,MAAM,CAAC;YAEb,MAAM,UAAU,GAAG,2BAAS,CAAC,OAAO,CAAC,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;YAEnE,OAAO,MAAM,UAAU,CAAC,OAAO,EAAE,CAAC;QACtC,CAAC;KAAA;CACJ;AAvDD,kCAuDC"}
1
+ {"version":3,"file":"A-Component.class.js","sourceRoot":"","sources":["../../../../src/global/A-Component/A-Component.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,kEAAyD;AAMzD;;;GAGG;AACH,MAAa,WAAW;IAGpB,YACI,MAA8D,IAC9D,CAAC;IAoCC,IAAI,CACN,KAAc,EACd,MAAyH,EACzH,MAAqE;;YAGrE,MAAM,OAAO,GAAW,OAAO,MAAM,KAAK,QAAQ;gBAC9C,CAAC,CAAC,MAAM;gBACR,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;YAClB,MAAM,MAAM,GAAiE,OAAO,MAAM,KAAK,QAAQ;gBACnG,CAAC,CAAC,MAAM,IAAI,EAAE;gBACd,CAAC,CAAC,MAAM,CAAC;YAEb,MAAM,UAAU,GAAG,2BAAS,CAAC,OAAO,CAAC,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;YAEnE,OAAO,MAAM,UAAU,CAAC,OAAO,EAAE,CAAC;QACtC,CAAC;KAAA;CACJ;AA1DD,kCA0DC"}
@@ -1,3 +1,4 @@
1
+ import { A_TYPES__ConceptAbstractionMeta, A_TYPES__ConceptStage } from "../A-Concept/A_Concept.types";
1
2
  import { A_Meta } from "../A-Meta/A-Meta.class";
2
3
  import { A_TYPES__ComponentMeta, A_TYPES__ComponentMetaExtension } from "./A-Component.types";
3
4
  export declare class A_ComponentMeta extends A_Meta<A_TYPES__ComponentMeta> {
@@ -8,4 +9,11 @@ export declare class A_ComponentMeta extends A_Meta<A_TYPES__ComponentMeta> {
8
9
  * @returns
9
10
  */
10
11
  extensions(feature: string): A_TYPES__ComponentMetaExtension[];
12
+ /**
13
+ * Returns a set of instructions to run proper methods in Component during A-Concept Stage
14
+ *
15
+ * @param stage
16
+ * @returns
17
+ */
18
+ abstractions(abstraction: A_TYPES__ConceptStage): A_TYPES__ConceptAbstractionMeta[];
11
19
  }
@@ -24,12 +24,38 @@ class A_ComponentMeta extends A_Meta_class_1.A_Meta {
24
24
  // component: constructor,
25
25
  name: extension.name,
26
26
  handler: extension.handler,
27
- args
27
+ args,
28
+ behavior: extension.behavior,
29
+ before: extension.before || [],
30
+ after: extension.after || []
28
31
  });
29
32
  });
30
33
  });
31
34
  return steps;
32
35
  }
36
+ /**
37
+ * Returns a set of instructions to run proper methods in Component during A-Concept Stage
38
+ *
39
+ * @param stage
40
+ * @returns
41
+ */
42
+ abstractions(abstraction) {
43
+ const steps = [];
44
+ const abstractions = this.get(A_Component_types_1.A_TYPES__ComponentMetaKey.ABSTRACTIONS);
45
+ const injections = this.get(A_Component_types_1.A_TYPES__ComponentMetaKey.INJECTIONS);
46
+ // const constructor = A_Context.component(this);
47
+ abstractions === null || abstractions === void 0 ? void 0 : abstractions
48
+ // returns all extensions that match the feature
49
+ .find(`CONCEPT_ABSTRACTION::${abstraction}`).forEach(([handler, extensions]) => {
50
+ extensions.forEach(extension => {
51
+ const args = (injections === null || injections === void 0 ? void 0 : injections.get(extension.handler)) || [];
52
+ steps.push(Object.assign(Object.assign({}, extension), {
53
+ // component: constructor,
54
+ args }));
55
+ });
56
+ });
57
+ return steps;
58
+ }
33
59
  }
34
60
  exports.A_ComponentMeta = A_ComponentMeta;
35
61
  //# sourceMappingURL=A-Component.meta.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"A-Component.meta.js","sourceRoot":"","sources":["../../../../src/global/A-Component/A-Component.meta.ts"],"names":[],"mappings":";;;AAAA,yDAAgD;AAChD,2DAAyH;AAGzH,MAAa,eAAgB,SAAQ,qBAA8B;IAK/D;;;;;OAKG;IACH,UAAU,CACN,OAAe;QAEf,MAAM,KAAK,GAAsC,EAAE,CAAC;QAEpD,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,UAAU,CAAC,CAAC;QAClE,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,UAAU,CAAC,CAAC;QAElE,iDAAiD;QAGjD,UAAU,aAAV,UAAU,uBAAV,UAAU;QACN,gDAAgD;SAC9C,IAAI,CAAC,OAAO,EACb,OAAO,CAAC,CAAC,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,EAAE;YAC/B,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE;gBAC3B,MAAM,IAAI,GAAG,CAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,GAAG,CAAC,SAAS,CAAC,OAAO,CAAC,KAAI,EAAE,CAAC;gBAEtD,KAAK,CAAC,IAAI,CAAC;oBACP,0BAA0B;oBAC1B,IAAI,EAAE,SAAS,CAAC,IAAI;oBACpB,OAAO,EAAE,SAAS,CAAC,OAAO;oBAC1B,IAAI;iBACP,CAA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OAKG;IACH,YAAY,CACR,WAAkC;QAElC,MAAM,KAAK,GAAsC,EAAE,CAAC;QAEpD,MAAM,YAAY,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,YAAY,CAAC,CAAC;QACtE,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,UAAU,CAAC,CAAC;QAElE,iDAAiD;QAGjD,YAAY,aAAZ,YAAY,uBAAZ,YAAY;QACR,gDAAgD;SAC9C,IAAI,CAAC,wBAAwB,WAAW,EAAE,EAC3C,OAAO,CAAC,CAAC,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,EAAE;YAC/B,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE;gBAC3B,MAAM,IAAI,GAAG,CAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,GAAG,CAAC,SAAS,CAAC,OAAO,CAAC,KAAI,EAAE,CAAC;gBAEtD,KAAK,CAAC,IAAI,iCACH,SAAS;oBACZ,0BAA0B;oBAC1B,IAAI,IACN,CAAC;YAEP,CAAC,CAAC,CAAC;QACP,CAAC,CAAC,CAAC;QAGP,OAAO,KAAK,CAAC;IACjB,CAAC;CACJ;AAnFD,0CAmFC"}
@@ -1,9 +1,11 @@
1
- import { A_Entity } from "../A-Entity/A-Entity.class";
2
- import { A_Feature } from "../A-Feature/A-Feature.class";
1
+ import { A_TYPES__A_InjectDecorator_Meta } from "../../decorators/A-Inject/A-Inject.decorator.types";
3
2
  import { A_Fragment } from "../A-Fragment/A-Fragment.class";
4
3
  import { A_Meta } from "../A-Meta/A-Meta.class";
5
- import { A_Scope } from "../A-Scope/A-Scope.class";
6
- import { A_Component } from "./A-Component.class";
4
+ import { A_TYPES__A_ExtendDecorator_BehaviorConfig, A_TYPES__A_ExtendDecorator_Meta } from "../../decorators/A-Feature/A-Feature.decorator.types";
5
+ import { A_TYPES__ConceptAbstraction } from "../A-Concept/A_Concept.types";
6
+ export type A_TYPES__ComponentConstructor<_Exports extends Array<String>> = {
7
+ exports: _Exports;
8
+ };
7
9
  export type A_TYPES__ComponentCallParams<T extends string> = {
8
10
  name: T;
9
11
  fragments: Array<A_Fragment>;
@@ -20,7 +22,7 @@ export type A_TYPES__ComponentMeta = {
20
22
  *
21
23
  * Where value is the extension instructions
22
24
  */
23
- [Key: string]: A_TYPES__ComponentMeta_ExtensionItem[];
25
+ [Key: string]: A_TYPES__A_ExtendDecorator_Meta[];
24
26
  }>;
25
27
  [A_TYPES__ComponentMetaKey.FEATURES]: any[];
26
28
  [A_TYPES__ComponentMetaKey.INJECTIONS]: A_Meta<{
@@ -29,14 +31,22 @@ export type A_TYPES__ComponentMeta = {
29
31
  *
30
32
  * Where value is the list of injections
31
33
  */
32
- [Key: string]: A_TYPES__ComponentMeta_InjectionParams;
34
+ [Key: string]: A_TYPES__A_InjectDecorator_Meta;
35
+ }>;
36
+ [A_TYPES__ComponentMetaKey.ABSTRACTIONS]: A_Meta<{
37
+ /**
38
+ * Where Key is the name of the stage
39
+ *
40
+ * Where value is the list of injections
41
+ */
42
+ [Key: string]: A_TYPES__ConceptAbstraction[];
33
43
  }>;
34
44
  };
35
45
  export declare enum A_TYPES__ComponentMetaKey {
36
46
  EXTENSIONS = "a-component-extensions",
37
47
  FEATURES = "a-component-features",
38
48
  INJECTIONS = "a-component-injections",
39
- STAGES = "a-component-stages"
49
+ ABSTRACTIONS = "a-component-abstractions"
40
50
  }
41
51
  export type A_TYPES__ComponentMetaExtension = {
42
52
  /**
@@ -50,30 +60,5 @@ export type A_TYPES__ComponentMetaExtension = {
50
60
  /**
51
61
  * The arguments that will be passed to the handler
52
62
  */
53
- args: A_TYPES__ComponentMeta_InjectionParams;
54
- };
55
- export type A_TYPES__ComponentMeta_ExtensionItem = {
56
- name: string;
57
- handler: string;
58
- };
59
- export type A_TYPES__ComponentMeta_InjectionParams = Array<{
60
- target: A_TYPES__ComponentMeta_InjectionParam;
61
- } | {
62
- target: {
63
- new (...args: any[]): A_Entity;
64
- };
65
- instructions: Partial<A_TYPES__ComponentMeta_EntityInjectionInstructions>;
66
- }>;
67
- export type A_TYPES__ComponentMeta_EntityInjectionInstructions = {
68
- aseid: string;
69
- id: string;
70
- };
71
- export type A_TYPES__ComponentMeta_InjectionParam = {
72
- new (...args: any[]): A_Fragment;
73
- } | {
74
- new (...args: any[]): A_Component;
75
- } | {
76
- new (...args: any[]): A_Scope;
77
- } | {
78
- new (...args: any[]): A_Feature;
79
- };
63
+ args: A_TYPES__A_InjectDecorator_Meta;
64
+ } & A_TYPES__A_ExtendDecorator_BehaviorConfig;
@@ -6,12 +6,6 @@ var A_TYPES__ComponentMetaKey;
6
6
  A_TYPES__ComponentMetaKey["EXTENSIONS"] = "a-component-extensions";
7
7
  A_TYPES__ComponentMetaKey["FEATURES"] = "a-component-features";
8
8
  A_TYPES__ComponentMetaKey["INJECTIONS"] = "a-component-injections";
9
- A_TYPES__ComponentMetaKey["STAGES"] = "a-component-stages";
9
+ A_TYPES__ComponentMetaKey["ABSTRACTIONS"] = "a-component-abstractions";
10
10
  })(A_TYPES__ComponentMetaKey || (exports.A_TYPES__ComponentMetaKey = A_TYPES__ComponentMetaKey = {}));
11
- // |
12
- // typeof A_Fragment
13
- // | typeof A_Component
14
- // // | { new(...args: any[]): any }
15
- // | typeof A_Scope
16
- // | typeof A_Feature;
17
11
  //# sourceMappingURL=A-Component.types.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"A-Component.types.js","sourceRoot":"","sources":["../../../../src/global/A-Component/A-Component.types.ts"],"names":[],"mappings":";;;AA0CA,IAAY,yBAKX;AALD,WAAY,yBAAyB;IACjC,kEAAqC,CAAA;IACrC,8DAAiC,CAAA;IACjC,kEAAqC,CAAA;IACrC,0DAA6B,CAAA;AACjC,CAAC,EALW,yBAAyB,yCAAzB,yBAAyB,QAKpC;AA2CD,KAAK;AACL,oBAAoB;AACpB,uBAAuB;AACvB,oCAAoC;AACpC,mBAAmB;AACnB,sBAAsB"}
1
+ {"version":3,"file":"A-Component.types.js","sourceRoot":"","sources":["../../../../src/global/A-Component/A-Component.types.ts"],"names":[],"mappings":";;;AAqDA,IAAY,yBAKX;AALD,WAAY,yBAAyB;IACjC,kEAAqC,CAAA;IACrC,8DAAiC,CAAA;IACjC,kEAAqC,CAAA;IACrC,sEAAyC,CAAA;AAC7C,CAAC,EALW,yBAAyB,yCAAzB,yBAAyB,QAKpC"}
@@ -18,36 +18,36 @@ export declare class A_Concept<_Features extends A_Container<any>[] = any> {
18
18
  /**
19
19
  * Load the concept. This step runs before any other steps to ensure that all components are loaded.
20
20
  */
21
- static get Load(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
21
+ static Load(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
22
22
  /**
23
23
  * Publish the concept to ADAAS platform. (Or any other place defined in the concept)
24
24
  *
25
25
  * [!] To extend the logic just create a custom containers and override the default behavior.
26
26
  */
27
- static get Publish(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
27
+ static Publish(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
28
28
  /**
29
29
  * Deploy the concept to the environment.
30
30
  */
31
- static get Deploy(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
31
+ static Deploy(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
32
32
  /**
33
33
  * Compiles the Concept in case there are some containers that require that.
34
34
  *
35
35
  * Can be used for static websites or any other concept that requires a build step.
36
36
  *
37
37
  */
38
- static get Build(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
38
+ static Build(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
39
39
  /**
40
40
  * Main execution of the concept.
41
41
  */
42
- static get Run(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
42
+ static Run(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
43
43
  /**
44
44
  * Start the concept. Uses for servers or any other background services.
45
45
  */
46
- static get Start(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
46
+ static Start(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
47
47
  /**
48
48
  * Stop the concept. Uses for servers or any other background services.
49
49
  */
50
- static get Stop(): (config?: Partial<import("../../..").A_TYPES__A_StageDecoratorConfig>) => (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_StageDecoratorDescriptor) => void;
50
+ static Stop(): (target: A_Container<any> | import("../A-Component/A-Component.class").A_Component, propertyKey: string, descriptor: import("../../..").A_TYPES__A_AbstractionDecoratorDescriptor) => void;
51
51
  protected containers: A_Container<any>[];
52
52
  constructor(props: A_TYPES__IConceptConstructor<_Features>);
53
53
  get namespace(): string;
@@ -13,7 +13,7 @@ exports.A_Concept = void 0;
13
13
  const A_Concept_types_1 = require("./A_Concept.types");
14
14
  const A_Context_class_1 = require("../A-Context/A-Context.class");
15
15
  const A_Container_types_1 = require("../A-Container/A-Container.types");
16
- const A_Stage_decorator_1 = require("../../decorators/A-Stage/A-Stage.decorator");
16
+ const A_Abstraction_decorator_1 = require("../../decorators/A-Abstraction/A-Abstraction.decorator");
17
17
  // export type RunParams<T> = T extends A_Container<any, infer Params> ? Params : never;
18
18
  /**
19
19
  * A_Concept is a placeholder for the concept of the ani program.
@@ -34,22 +34,22 @@ class A_Concept {
34
34
  /**
35
35
  * Load the concept. This step runs before any other steps to ensure that all components are loaded.
36
36
  */
37
- static get Load() {
38
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Load);
37
+ static Load() {
38
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Load);
39
39
  }
40
40
  /**
41
41
  * Publish the concept to ADAAS platform. (Or any other place defined in the concept)
42
42
  *
43
43
  * [!] To extend the logic just create a custom containers and override the default behavior.
44
44
  */
45
- static get Publish() {
46
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Publish);
45
+ static Publish() {
46
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Publish);
47
47
  }
48
48
  /**
49
49
  * Deploy the concept to the environment.
50
50
  */
51
- static get Deploy() {
52
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Deploy);
51
+ static Deploy() {
52
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Deploy);
53
53
  }
54
54
  /**
55
55
  * Compiles the Concept in case there are some containers that require that.
@@ -57,26 +57,26 @@ class A_Concept {
57
57
  * Can be used for static websites or any other concept that requires a build step.
58
58
  *
59
59
  */
60
- static get Build() {
61
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Build);
60
+ static Build() {
61
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Build);
62
62
  }
63
63
  /**
64
64
  * Main execution of the concept.
65
65
  */
66
- static get Run() {
67
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Run);
66
+ static Run() {
67
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Run);
68
68
  }
69
69
  /**
70
70
  * Start the concept. Uses for servers or any other background services.
71
71
  */
72
- static get Start() {
73
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Start);
72
+ static Start() {
73
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Start);
74
74
  }
75
75
  /**
76
76
  * Stop the concept. Uses for servers or any other background services.
77
77
  */
78
- static get Stop() {
79
- return (0, A_Stage_decorator_1.A_Stage)(A_Concept_types_1.A_TYPES__ConceptStage.Stop);
78
+ static Stop() {
79
+ return (0, A_Abstraction_decorator_1.A_Abstraction)(A_Concept_types_1.A_TYPES__ConceptStage.Stop);
80
80
  }
81
81
  constructor(props) {
82
82
  this.props = props;
@@ -142,29 +142,29 @@ class A_Concept {
142
142
  }
143
143
  runStage(method, params) {
144
144
  return __awaiter(this, void 0, void 0, function* () {
145
- const stages = [];
145
+ const abstractions = [];
146
146
  this.containers.map(container => {
147
147
  const meta = A_Context_class_1.A_Context.meta(container);
148
- const containerStages = meta.get(A_Container_types_1.A_TYPES__ContainerMetaKey.STAGES);
149
- if (containerStages) {
150
- for (const [name, stage] of containerStages) {
151
- if (stage.name === method) {
152
- stages.push({
153
- name,
154
- container,
155
- });
156
- }
157
- }
158
- }
148
+ const containerAbstractions = meta
149
+ .abstractions(method)
150
+ .map(step => (Object.assign({ component: container }, step)));
151
+ const containerScope = A_Context_class_1.A_Context.scope(container);
152
+ const componentsAbstractions = containerScope.components
153
+ .map(component => A_Context_class_1.A_Context.meta(component).abstractions(method).map(step => (Object.assign({ component }, step))))
154
+ .flat();
155
+ abstractions.push({
156
+ container,
157
+ runners: [
158
+ ...containerAbstractions.map(step => (Object.assign(Object.assign({}, step), { component: container }))),
159
+ ...componentsAbstractions
160
+ ]
161
+ });
159
162
  });
160
163
  const scope = A_Context_class_1.A_Context.allocate(this, {
161
164
  components: params.components,
162
165
  fragments: params.fragments,
163
166
  parent: A_Context_class_1.A_Context.scope(this)
164
167
  });
165
- for (const stage of stages) {
166
- yield stage.container[stage.name](params);
167
- }
168
168
  });
169
169
  }
170
170
  execute(params) {
@@ -1 +1 @@
1
- {"version":3,"file":"A_Concept.class.js","sourceRoot":"","sources":["../../../../src/global/A-Concept/A_Concept.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,uDAAqH;AACrH,kEAAyD;AAIzD,wEAA6E;AAC7E,6FAAgF;AAKhF,wFAAwF;AAIxF;;;;;;;;;;;GAWG;AACH,MAAa,SAAS;IAIlB,iFAAiF;IACjF,iFAAiF;IACjF,iFAAiF;IACjF;;OAEG;IACH,MAAM,KAAK,IAAI;QACX,OAAO,IAAA,2BAAO,EAAC,uCAAqB,CAAC,IAAI,CAAC,CAAC;IAC/C,CAAC;IAED;;;;OAIG;IACH,MAAM,KAAK,OAAO;QACd,OAAO,IAAA,2BAAO,EAAC,uCAAqB,CAAC,OAAO,CAAC,CAAC;IAClD,CAAC;IAED;;OAEG;IACH,MAAM,KAAK,MAAM;QACb,OAAO,IAAA,2BAAO,EAAC,uCAAqB,CAAC,MAAM,CAAC,CAAC;IACjD,CAAC;IAED;;;;;OAKG;IACH,MAAM,KAAK,KAAK;QACZ,OA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,EAAE,CAAC;YAG1C,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE;gBAC5B,MAAM,IAAI,GAAG,2BAAS,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;gBAEvC,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,QAAQ,CAAC,CAAA;YAEhD,CAAC,CAAC,CAAC;QAGP,CAAC;KAAA;CAEJ;AAhND,8BAgNC"}
1
+ {"version":3,"file":"A_Concept.class.js","sourceRoot":"","sources":["../../../../src/global/A-Concept/A_Concept.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,uDAAqH;AACrH,kEAAyD;AAIzD,wEAA6E;AAC7E,+GAAkG;AAOlG,wFAAwF;AAIxF;;;;;;;;;;;GAWG;AACH,MAAa,SAAS;IAIlB,iFAAiF;IACjF,iFAAiF;IACjF,iFAAiF;IACjF;;OAEG;IACH,MAAM,CAAC,IAAI;QACP,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,IAAI,CAAC,CAAC;IACrD,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,OAAO;QACV,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,OAAO,CAAC,CAAC;IACxD,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,MAAM;QACT,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,MAAM,CAAC,CAAC;IACvD,CAAC;IAED;;;;;OAKG;IACH,MAAM,CAAC,KAAK;QACR,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,KAAK,CAAC,CAAC;IACtD,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,GAAG;QACN,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,GAAG,CAAC,CAAC;IACpD,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,KAAK;QACR,OAAO,IAAA,uCAAa,EAAC,uCAAqB,CAAC,KAAK,CAAC,CAAC;IACtD,CAAC;IAED;;OAEG;IACH,MAAM,CA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2BAAS,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;gBAEvC,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,QAAQ,CAAC,CAAA;YAEhD,CAAC,CAAC,CAAC;QAGP,CAAC;KAAA;CAEJ;AAjOD,8BAiOC"}
@@ -1,5 +1,9 @@
1
+ import { A_TYPES__A_InjectDecorator_Meta } from "../../decorators/A-Inject/A-Inject.decorator.types";
1
2
  import { A_Container } from "../A-Container/A-Container.class";
2
3
  import { A_Fragment } from "../A-Fragment/A-Fragment.class";
4
+ import { A_Entity } from "../A-Entity/A-Entity.class";
5
+ import { A_Component } from "../A-Component/A-Component.class";
6
+ import { A_TYPES__A_ExtendDecorator_BehaviorConfig } from "../../decorators/A-Feature/A-Feature.decorator.types";
3
7
  export declare enum A_TYPES__ConceptStage {
4
8
  Run = "run",
5
9
  Build = "build",
@@ -26,16 +30,52 @@ export interface A_TYPES__IConceptConstructor<T extends Array<A_Container<any>>>
26
30
  */
27
31
  containers?: T;
28
32
  }
33
+ /**
34
+ * Uses as a transfer object to pass configurations to Feature constructor
35
+ */
36
+ export type A_TYPES__ConceptAbstractionMeta = {
37
+ /**
38
+ * The name of original Extension Definition
39
+ */
40
+ name: string;
41
+ /**
42
+ * The name of the handler that will be used to apply the extension
43
+ */
44
+ handler: string;
45
+ /**
46
+ * The arguments that will be passed to the handler
47
+ */
48
+ args: A_TYPES__A_InjectDecorator_Meta;
49
+ } & A_TYPES__A_ExtendDecorator_BehaviorConfig;
50
+ /**
51
+ * Uses to define the extension that will be applied to the Concept
52
+ */
53
+ export type A_TYPES__ConceptAbstraction = {
54
+ /**
55
+ * The name of original Extension Definition
56
+ */
57
+ name: string;
58
+ /**
59
+ * The name of the handler that will be used to apply the extension
60
+ */
61
+ handler: string;
62
+ } & A_TYPES__A_ExtendDecorator_BehaviorConfig;
29
63
  export type A_TYPES__ConceptStageParams = {
30
64
  fragments: Array<A_Fragment>;
31
65
  components: Array<{
32
- new (...args: any[]): any;
66
+ new (...args: any[]): A_Component;
67
+ }>;
68
+ entities: Array<{
69
+ new (...args: any[]): A_Entity;
33
70
  }>;
34
71
  };
35
72
  export type A_TYPES__ConceptCallParams<T extends string> = {
36
73
  name: T;
37
74
  fragments: Array<A_Fragment>;
38
75
  components: Array<{
39
- new (...args: any[]): any;
76
+ new (...args: any[]): A_Component;
77
+ }>;
78
+ entities: Array<{
79
+ new (...args: any[]): A_Entity<any, any, any>;
40
80
  }>;
41
81
  };
@@ -1 +1 @@
1
- {"version":3,"file":"A_Concept.types.js","sourceRoot":"","sources":["../../../../src/global/A-Concept/A_Concept.types.ts"],"names":[],"mappings":";;;AAIA,IAAY,qBAQX;AARD,WAAY,qBAAqB;IAC7B,oCAAW,CAAA;IACX,wCAAe,CAAA;IACf,4CAAmB,CAAA;IACnB,0CAAiB,CAAA;IACjB,sCAAa,CAAA;IACb,wCAAe,CAAA;IACf,sCAAa,CAAA;AACjB,CAAC,EARW,qBAAqB,qCAArB,qBAAqB,QAQhC;AAGD,uCAAuC;AACvC,6FAA6F;AAC7F,iDAAiD;AACjD,oDAAoD;AACpD,yCAAyC;AACzC,8BAA8B;AAC9B,oDAAoD;AACpD,kDAAkD;AAClD,WAAW;AAEX,IAAI;AAEJ,IAAY,uBAEX;AAFD,WAAY,uBAAuB;IAC/B,+DAAoC,CAAA;AACxC,CAAC,EAFW,uBAAuB,uCAAvB,uBAAuB,QAElC"}
1
+ {"version":3,"file":"A_Concept.types.js","sourceRoot":"","sources":["../../../../src/global/A-Concept/A_Concept.types.ts"],"names":[],"mappings":";;;AAQA,IAAY,qBAQX;AARD,WAAY,qBAAqB;IAC7B,oCAAW,CAAA;IACX,wCAAe,CAAA;IACf,4CAAmB,CAAA;IACnB,0CAAiB,CAAA;IACjB,sCAAa,CAAA;IACb,wCAAe,CAAA;IACf,sCAAa,CAAA;AACjB,CAAC,EARW,qBAAqB,qCAArB,qBAAqB,QAQhC;AAGD,uCAAuC;AACvC,6FAA6F;AAC7F,iDAAiD;AACjD,oDAAoD;AACpD,yCAAyC;AACzC,8BAA8B;AAC9B,oDAAoD;AACpD,kDAAkD;AAClD,WAAW;AAEX,IAAI;AAEJ,IAAY,uBAEX;AAFD,WAAY,uBAAuB;IAC/B,+DAAoC,CAAA;AACxC,CAAC,EAFW,uBAAuB,uCAAvB,uBAAuB,QAElC"}
@@ -13,7 +13,7 @@ import { A_TYPES__FeatureConstructor } from "../A-Feature/A-Feature.types";
13
13
  * - Microservice
14
14
  * - etc.
15
15
  */
16
- export declare class A_Container<_FeatureNames extends Array<string>> {
16
+ export declare class A_Container<_FeatureNames extends Array<string> = any> {
17
17
  protected readonly config: Partial<A_TYPES__ContainerConstructor<_FeatureNames>>;
18
18
  /**
19
19
  * Promise that will be resolved when the container is ready to be used.
@@ -27,13 +27,6 @@ export declare class A_Container<_FeatureNames extends Array<string>> {
27
27
  * Configuration of the container that will be used to run it.
28
28
  */
29
29
  config: Partial<A_TYPES__ContainerConstructor<_FeatureNames>>);
30
- protected hasInherited(cl: {
31
- new (...args: any[]): any;
32
- }): boolean;
33
- /**
34
- * Initializes the Namespace or can be used to reinitialize the Namespace
35
- */
36
- private init;
37
30
  /**
38
31
  * This method allows to call the lifecycle method of the container as well as any other Feature defined for it
39
32
  *
@@ -41,36 +41,6 @@ class A_Container {
41
41
  const components = config.components || [];
42
42
  const fragments = config.fragments || [];
43
43
  A_Context_class_1.A_Context.allocate(this, config);
44
- /**
45
- * Run Async Initialization
46
- */
47
- this.init();
48
- }
49
- hasInherited(cl) {
50
- return this.constructor === cl
51
- ? false
52
- : true;
53
- }
54
- /**
55
- * Initializes the Namespace or can be used to reinitialize the Namespace
56
- */
57
- init() {
58
- return __awaiter(this, void 0, void 0, function* () {
59
- if (!this.ready)
60
- this.ready = new Promise((resolve, reject) => __awaiter(this, void 0, void 0, function* () {
61
- try {
62
- yield this.onBeforeInit();
63
- yield this.onInit();
64
- yield this.onAfterInit();
65
- return resolve();
66
- }
67
- catch (error) {
68
- return reject(error);
69
- }
70
- }));
71
- else
72
- yield this.ready;
73
- });
74
44
  }
75
45
  call(param1, param2) {
76
46
  return __awaiter(this, void 0, void 0, function* () {
@@ -80,7 +50,7 @@ class A_Container {
80
50
  const params = typeof param1 === 'string'
81
51
  ? param2 || {}
82
52
  : param1;
83
- const newFeature = A_Context_class_1.A_Context.feature(this.Scope, this, feature, params);
53
+ const newFeature = A_Context_class_1.A_Context.feature(A_Context_class_1.A_Context.scope(this), this, feature, params);
84
54
  return yield newFeature.process();
85
55
  });
86
56
  }
@@ -1 +1 @@
1
- {"version":3,"file":"A-Container.class.js","sourceRoot":"","sources":["../../../../src/global/A-Container/A-Container.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,kEAAyD;AAMzD;;;;;;;;;;GAUG;AACH,MAAa,WAAW;IAYpB,IAAI,OAAO;QACP,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,IAAI,EAAS,CAAC;IAC5C,CAAC;IAED,IAAI,IAAI;QACJ,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,IAAI,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACrD,CAAC;IAED,IAAI,KAAK;QACL,OAAO,2BAAS,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACjC,CAAC;IAGD;IACI;;OAEG;IACH,MAA6D;QAE7D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QAErB,MAAM,UAAU,GAAG,MAAM,CAAC,UAAU,IAAI,EAAE,CAAC;QAC3C,MAAM,SAAS,GAAG,MAAM,CAAC,SAAS,IAAI,EAAE,CAAC;QAEzC,2BAAS,CAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;QAEjC;;WAEG;QACH,IAAI,CAAC,IAAI,EAAE,CAAC;IAChB,CAAC;IAGS,YAAY,CAAC,EAA2B;QAC9C,OAAO,IAAI,CAAC,WAAW,KAAK,EAAE;YAC1B,CAAC,CAAC,KAAK;YACP,CAAC,CAAC,IAAI,CAAA;IACd,CAAC;IAG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M,CAAC;QAEb,OAAO,2BAAS,CAAC,iBAAiB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;IAC1E,CAAC;IAID,iEAAiE;IACjE,iEAAiE;IACjE,iEAAiE;IAEjE;;;;OAIG;IACa,YAAY;;YACxB,OAAO;QACX,CAAC;KAAA;IAED;;OAEG;IACa,MAAM;;YAClB,OAAO;QACX,CAAC;KAAA;IAED;;;;OAIG;IACa,WAAW;;YACvB,OAAO;QACX,CAAC;KAAA;CAEJ;AA5MD,kCA4MC"}
1
+ {"version":3,"file":"A-Container.class.js","sourceRoot":"","sources":["../../../../src/global/A-Container/A-Container.class.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,kEAAyD;AAMzD;;;;;;;;;;GAUG;AACH,MAAa,WAAW;IAYpB,IAAI,OAAO;QACP,OAAO,IAAI,CAAC,MAAM,CAAC,OAAO,IAAI,EAAS,CAAC;IAC5C,CAAC;IAED,IAAI,IAAI;QACJ,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,IAAI,IAAI,CAAC,WAAW,CAAC,IAAI,CAAC;IACrD,CAAC;IAED,IAAI,KAAK;QACL,OAAO,2BAAS,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACjC,CAAC;IAGD;IACI;;OAEG;IACH,MAA6D;QAE7D,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QAErB,MAAM,UAAU,GAAG,MAAM,CAAC,UAAU,IAAI,EAAE,CAAC;QAC3C,MAAM,SAAS,GAAG,MAAM,CAAC,SAAS,IAAI,EAAE,CAAC;QAEzC,2BAAS,CAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC;IAGrC,CAAC;IAkCK,IAAI,CACN,MAAyH,EACzH,MAAqE;;YAGrE,MAAM,OAAO,GAAW,OAAO,MAAM,KAAK,QAAQ;gBAC9C,CAAC,CAAC,MAAM;gBACR,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;YAClB,MAAM,MAAM,GAAiE,OAAO,MAAM,KAAK,QAAQ;gBACnG,CAAC,CAAC,MAAM,IAAI,EAAE;gBACd,CAAC,CAAC,MAAM,CAAC;YAEb,MAAM,UAAU,GAAG,2BAAS,CAAC,OAAO,CAAC,2BAAS,CAAC,KAAK,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;YAEnF,OAAO,MAAM,UAAU,CAAC,OAAO,EAAE,CAAC;QACtC,CAAC;KAAA;IAkCD,OAAO,CACH,MAAyH,EACzH,MAAqE;QAGrE,MAAM,OAAO,GAAW,OAAO,MAAM,KAAK,QAAQ;YAC9C,CAAC,CAAC,MAAM;YACR,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC;QAClB,MAAM,MAAM,GAAiE,OAAO,MAAM,KAAK,QAAQ;YACnG,CAAC,CAAC,MAAM,IAAI,EAAE;YACd,CAAC,CAAC,MAAM,CAAC;QAEb,OAAO,2BAAS,CAAC,iBAAiB,CAAC,IAAI,CAAC,KAAK,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;IAC1E,CAAC;IAID,iEAAiE;IACjE,iEAAiE;IACjE,iEAAiE;IAEjE;;;;OAIG;IACa,YAAY;;YACxB,OAAO;QACX,CAAC;KAAA;IAED;;OAEG;IACa,MAAM;;YAClB,OAAO;QACX,CAAC;KAAA;IAED;;;;OAIG;IACa,WAAW;;YACvB,OAAO;QACX,CAAC;KAAA;CAEJ;AAxKD,kCAwKC"}
@@ -1,4 +1,12 @@
1
+ import { A_TYPES__ConceptAbstractionMeta, A_TYPES__ConceptStage } from "../A-Concept/A_Concept.types";
1
2
  import { A_Meta } from "../A-Meta/A-Meta.class";
2
3
  import { A_TYPES__ContainerMeta } from "./A-Container.types";
3
4
  export declare class A_ContainerMeta extends A_Meta<A_TYPES__ContainerMeta> {
5
+ /**
6
+ * Returns a set of instructions to run proper methods in Container during A-Concept Stage
7
+ *
8
+ * @param stage
9
+ * @returns
10
+ */
11
+ abstractions(abstraction: A_TYPES__ConceptStage): A_TYPES__ConceptAbstractionMeta[];
4
12
  }
@@ -2,7 +2,36 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.A_ContainerMeta = void 0;
4
4
  const A_Meta_class_1 = require("../A-Meta/A-Meta.class");
5
+ const A_Container_types_1 = require("./A-Container.types");
5
6
  class A_ContainerMeta extends A_Meta_class_1.A_Meta {
7
+ /**
8
+ * Returns a set of instructions to run proper methods in Container during A-Concept Stage
9
+ *
10
+ * @param stage
11
+ * @returns
12
+ */
13
+ abstractions(abstraction) {
14
+ const steps = [];
15
+ const abstractions = this.get(A_Container_types_1.A_TYPES__ContainerMetaKey.ABSTRACTIONS);
16
+ const injections = this.get(A_Container_types_1.A_TYPES__ContainerMetaKey.INJECTIONS);
17
+ // const constructor = A_Context.component(this);
18
+ abstractions === null || abstractions === void 0 ? void 0 : abstractions
19
+ // returns all extensions that match the feature
20
+ .find(`CONCEPT_ABSTRACTION::${abstraction}`).forEach(([handler, extensions]) => {
21
+ extensions.forEach(extension => {
22
+ const args = (injections === null || injections === void 0 ? void 0 : injections.get(extension.handler)) || [];
23
+ steps.push({
24
+ name: extension.name,
25
+ handler: extension.handler,
26
+ args,
27
+ before: extension.before,
28
+ behavior: extension.behavior,
29
+ after: extension.after
30
+ });
31
+ });
32
+ });
33
+ return steps;
34
+ }
6
35
  }
7
36
  exports.A_ContainerMeta = A_ContainerMeta;
8
37
  //# sourceMappingURL=A-Container.meta.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"A-Container.meta.js","sourceRoot":"","sources":["../../../../src/global/A-Container/A-Container.meta.ts"],"names":[],"mappings":";;;AAGA,yDAAgD;AAShD,MAAa,eAAgB,SAAQ,qBAA8B;CAGlE;AAHD,0CAGC"}
1
+ {"version":3,"file":"A-Container.meta.js","sourceRoot":"","sources":["../../../../src/global/A-Container/A-Container.meta.ts"],"names":[],"mappings":";;;AACA,yDAAgD;AAChD,2DAG6B;AAI7B,MAAa,eAAgB,SAAQ,qBAA8B;IAG/D;;;;;OAKG;IACH,YAAY,CACR,WAAkC;QAElC,MAAM,KAAK,GAAsC,EAAE,CAAC;QAEpD,MAAM,YAAY,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,YAAY,CAAC,CAAC;QACtE,MAAM,UAAU,GAAG,IAAI,CAAC,GAAG,CAAC,6CAAyB,CAAC,UAAU,CAAC,CAAC;QAElE,iDAAiD;QAGjD,YAAY,aAAZ,YAAY,uBAAZ,YAAY;QACR,gDAAgD;SAC9C,IAAI,CAAC,wBAAwB,WAAW,EAAE,EAC3C,OAAO,CAAC,CAAC,CAAC,OAAO,EAAE,UAAU,CAAC,EAAE,EAAE;YAC/B,UAAU,CAAC,OAAO,CAAC,SAAS,CAAC,EAAE;gBAC3B,MAAM,IAAI,GAAG,CAAA,UAAU,aAAV,UAAU,uBAAV,UAAU,CAAE,GAAG,CAAC,SAAS,CAAC,OAAO,CAAC,KAAI,EAAE,CAAC;gBAEtD,KAAK,CAAC,IAAI,CAAC;oBACP,IAAI,EAAE,SAAS,CAAC,IAAI;oBACpB,OAAO,EAAE,SAAS,CAAC,OAAO;oBAC1B,IAAI;oBACJ,MAAM,EAAE,SAAS,CAAC,MAAM;oBACxB,QAAQ,EAAE,SAAS,CAAC,QAAQ;oBAC5B,KAAK,EAAE,SAAS,CAAC,KAAK;iBACzB,CAAC,CAAC;YAEP,CAAC,CAAC,CAAC;QACP,CAAC,CAAC,CAAC;QAGP,OAAO,KAAK,CAAC;IACjB,CAAC;CAEJ;AA3CD,0CA2CC"}
@@ -1,5 +1,7 @@
1
- import { A_TYPES__ConceptStage } from "../A-Concept/A_Concept.types";
1
+ import { A_TYPES__A_InjectDecorator_Meta } from "../../decorators/A-Inject/A-Inject.decorator.types";
2
+ import { A_TYPES__ConceptAbstraction } from "../A-Concept/A_Concept.types";
2
3
  import { A_Fragment } from "../A-Fragment/A-Fragment.class";
4
+ import { A_Meta } from "../A-Meta/A-Meta.class";
3
5
  import { A_TYPES__ScopeConstructor } from "../A-Scope/A-Scope.types";
4
6
  export type A_TYPES__ContainerConstructor<_Exports extends Array<String>> = {
5
7
  name?: string;
@@ -14,16 +16,30 @@ export type A_TYPES__ContainerCallParams<T extends string> = {
14
16
  };
15
17
  export type A_TYPES__ContainerMeta = {
16
18
  [A_TYPES__ContainerMetaKey.FEATURES]: Map<string, A_TYPES__ContainerMeta_FeatureItem>;
17
- [A_TYPES__ContainerMetaKey.STAGES]: Map<string, A_TYPES__ContainerMeta_StageExtension>;
19
+ [A_TYPES__ContainerMetaKey.ABSTRACTIONS]: A_Meta<{
20
+ /**
21
+ * Where Key the regexp for what to apply the extension
22
+ * A set of container names or a wildcard, or a regexp
23
+ *
24
+ *
25
+ * Where value is the extension instructions
26
+ */
27
+ [Key: string]: A_TYPES__ConceptAbstraction[];
28
+ }>;
29
+ [A_TYPES__ContainerMetaKey.INJECTIONS]: A_Meta<{
30
+ /**
31
+ * Where Key is the name of the injection
32
+ *
33
+ * Where value is the list of injections
34
+ */
35
+ [Key: string]: A_TYPES__A_InjectDecorator_Meta;
36
+ }>;
18
37
  };
19
38
  export declare enum A_TYPES__ContainerMetaKey {
20
39
  FEATURES = "a-container-features",
21
- STAGES = "a-container-stages"
40
+ INJECTIONS = "a-container-injections",
41
+ ABSTRACTIONS = "a-container-abstractions"
22
42
  }
23
- export type A_TYPES__ContainerMeta_StageExtension = {
24
- name: A_TYPES__ConceptStage;
25
- handler: string;
26
- };
27
43
  export type A_TYPES__ContainerMeta_FeatureItem = {
28
44
  name: string;
29
45
  container: string;