@vived/core 1.4.2 → 1.4.4

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 (528) hide show
  1. package/README.md +142 -20
  2. package/dist/cjs/AppObject/AppObject.js +53 -0
  3. package/dist/cjs/AppObject/AppObject.js.map +1 -1
  4. package/dist/cjs/AppObject/AppObjectComponent.js +78 -0
  5. package/dist/cjs/AppObject/AppObjectComponent.js.map +1 -1
  6. package/dist/cjs/AppObject/AppObjectController.js +22 -0
  7. package/dist/cjs/AppObject/AppObjectController.js.map +1 -1
  8. package/dist/cjs/AppObject/AppObjectEntity.js +52 -0
  9. package/dist/cjs/AppObject/AppObjectEntity.js.map +1 -1
  10. package/dist/cjs/AppObject/AppObjectEntityRepo.js +75 -1
  11. package/dist/cjs/AppObject/AppObjectEntityRepo.js.map +1 -1
  12. package/dist/cjs/AppObject/AppObjectPM.js +46 -0
  13. package/dist/cjs/AppObject/AppObjectPM.js.map +1 -1
  14. package/dist/cjs/AppObject/AppObjectRepo.js +20 -0
  15. package/dist/cjs/AppObject/AppObjectRepo.js.map +1 -1
  16. package/dist/cjs/AppObject/AppObjectUC.js +23 -0
  17. package/dist/cjs/AppObject/AppObjectUC.js.map +1 -1
  18. package/dist/cjs/AppObject/AppObjectView.js +22 -0
  19. package/dist/cjs/AppObject/AppObjectView.js.map +1 -1
  20. package/dist/cjs/AppObject/getSingletonComponent.js +19 -0
  21. package/dist/cjs/AppObject/getSingletonComponent.js.map +1 -1
  22. package/dist/cjs/Entities/MemoizedAngle.js +21 -0
  23. package/dist/cjs/Entities/MemoizedAngle.js.map +1 -1
  24. package/dist/cjs/Entities/MemoizedBoolean.js +21 -0
  25. package/dist/cjs/Entities/MemoizedBoolean.js.map +1 -1
  26. package/dist/cjs/Entities/MemoizedColor.js +21 -0
  27. package/dist/cjs/Entities/MemoizedColor.js.map +1 -1
  28. package/dist/cjs/Entities/MemoizedNumber.js +21 -0
  29. package/dist/cjs/Entities/MemoizedNumber.js.map +1 -1
  30. package/dist/cjs/Entities/MemoizedQuaternion.js +21 -0
  31. package/dist/cjs/Entities/MemoizedQuaternion.js.map +1 -1
  32. package/dist/cjs/Entities/MemoizedString.js +21 -0
  33. package/dist/cjs/Entities/MemoizedString.js.map +1 -1
  34. package/dist/cjs/Entities/MemoizedVector2.js +21 -0
  35. package/dist/cjs/Entities/MemoizedVector2.js.map +1 -1
  36. package/dist/cjs/Entities/MemoizedVector3.js +21 -0
  37. package/dist/cjs/Entities/MemoizedVector3.js.map +1 -1
  38. package/dist/cjs/Entities/ObservableEntity.js +17 -0
  39. package/dist/cjs/Entities/ObservableEntity.js.map +1 -1
  40. package/dist/cjs/Entities/ObserverList.js +21 -0
  41. package/dist/cjs/Entities/ObserverList.js.map +1 -1
  42. package/dist/cjs/Entities/RangedNumber.js +29 -0
  43. package/dist/cjs/Entities/RangedNumber.js.map +1 -1
  44. package/dist/cjs/ExampleFeature/Adapters/examplePmAdapter.js +64 -0
  45. package/dist/cjs/ExampleFeature/Adapters/examplePmAdapter.js.map +1 -0
  46. package/dist/cjs/ExampleFeature/Adapters/exampleSingletonPmAdapter.js +60 -0
  47. package/dist/cjs/ExampleFeature/Adapters/exampleSingletonPmAdapter.js.map +1 -0
  48. package/dist/cjs/ExampleFeature/Adapters/index.js +19 -0
  49. package/dist/cjs/ExampleFeature/Adapters/index.js.map +1 -0
  50. package/dist/cjs/ExampleFeature/Controllers/index.js +19 -0
  51. package/dist/cjs/ExampleFeature/Controllers/index.js.map +1 -0
  52. package/dist/cjs/ExampleFeature/Controllers/setExampleText.js +48 -0
  53. package/dist/cjs/ExampleFeature/Controllers/setExampleText.js.map +1 -0
  54. package/dist/cjs/ExampleFeature/Controllers/toggleExampleBoolean.js +47 -0
  55. package/dist/cjs/ExampleFeature/Controllers/toggleExampleBoolean.js.map +1 -0
  56. package/dist/cjs/ExampleFeature/Entities/ExampleEntity.js +90 -0
  57. package/dist/cjs/ExampleFeature/Entities/ExampleEntity.js.map +1 -0
  58. package/dist/cjs/ExampleFeature/Entities/ExampleRepo.js +113 -0
  59. package/dist/cjs/ExampleFeature/Entities/ExampleRepo.js.map +1 -0
  60. package/dist/cjs/ExampleFeature/Entities/ExampleSingletonEntity.js +69 -0
  61. package/dist/cjs/ExampleFeature/Entities/ExampleSingletonEntity.js.map +1 -0
  62. package/dist/cjs/ExampleFeature/Entities/index.js +20 -0
  63. package/dist/cjs/ExampleFeature/Entities/index.js.map +1 -0
  64. package/dist/cjs/ExampleFeature/Factory/index.js +18 -0
  65. package/dist/cjs/ExampleFeature/Factory/index.js.map +1 -0
  66. package/dist/cjs/ExampleFeature/Factory/setupExampleFeature.js +29 -0
  67. package/dist/cjs/ExampleFeature/Factory/setupExampleFeature.js.map +1 -0
  68. package/dist/cjs/ExampleFeature/Mocks/MockEditExampleStringUC.js +47 -0
  69. package/dist/cjs/ExampleFeature/Mocks/MockEditExampleStringUC.js.map +1 -0
  70. package/dist/cjs/ExampleFeature/Mocks/MockExamplePM.js +48 -0
  71. package/dist/cjs/ExampleFeature/Mocks/MockExamplePM.js.map +1 -0
  72. package/dist/cjs/ExampleFeature/Mocks/MockExampleSingletonPM.js +59 -0
  73. package/dist/cjs/ExampleFeature/Mocks/MockExampleSingletonPM.js.map +1 -0
  74. package/dist/cjs/ExampleFeature/Mocks/MockToggleExampleBooleanUC.js +57 -0
  75. package/dist/cjs/ExampleFeature/Mocks/MockToggleExampleBooleanUC.js.map +1 -0
  76. package/dist/cjs/ExampleFeature/Mocks/index.js +21 -0
  77. package/dist/cjs/ExampleFeature/Mocks/index.js.map +1 -0
  78. package/dist/cjs/ExampleFeature/PMs/ExamplePM.js +97 -0
  79. package/dist/cjs/ExampleFeature/PMs/ExamplePM.js.map +1 -0
  80. package/dist/cjs/ExampleFeature/PMs/ExampleSingletonPM.js +102 -0
  81. package/dist/cjs/ExampleFeature/PMs/ExampleSingletonPM.js.map +1 -0
  82. package/dist/cjs/ExampleFeature/PMs/index.js +19 -0
  83. package/dist/cjs/ExampleFeature/PMs/index.js.map +1 -0
  84. package/dist/cjs/ExampleFeature/UCs/EditExampleStringUC.js +87 -0
  85. package/dist/cjs/ExampleFeature/UCs/EditExampleStringUC.js.map +1 -0
  86. package/dist/cjs/ExampleFeature/UCs/ToggleExampleBooleanUC.js +79 -0
  87. package/dist/cjs/ExampleFeature/UCs/ToggleExampleBooleanUC.js.map +1 -0
  88. package/dist/cjs/ExampleFeature/UCs/index.js +19 -0
  89. package/dist/cjs/ExampleFeature/UCs/index.js.map +1 -0
  90. package/dist/cjs/ExampleFeature/index.js +24 -0
  91. package/dist/cjs/ExampleFeature/index.js.map +1 -0
  92. package/dist/cjs/Types/PmAdapter.js.map +1 -1
  93. package/dist/cjs/Types/SingletonPmAdapter.js.map +1 -1
  94. package/dist/cjs/ValueObjects/Angle.js +1 -1
  95. package/dist/cjs/ValueObjects/Angle.js.map +1 -1
  96. package/dist/cjs/ValueObjects/LineSegment2D.js +6 -6
  97. package/dist/cjs/ValueObjects/LineSegment2D.js.map +1 -1
  98. package/dist/cjs/ValueObjects/Matrix.js +6 -6
  99. package/dist/cjs/ValueObjects/Matrix.js.map +1 -1
  100. package/dist/cjs/ValueObjects/Quaternion.js +17 -17
  101. package/dist/cjs/ValueObjects/Quaternion.js.map +1 -1
  102. package/dist/cjs/ValueObjects/Vector2.js +15 -8
  103. package/dist/cjs/ValueObjects/Vector2.js.map +1 -1
  104. package/dist/cjs/index.js +1 -0
  105. package/dist/cjs/index.js.map +1 -1
  106. package/dist/esm/AppObject/AppObject.js +53 -0
  107. package/dist/esm/AppObject/AppObject.js.map +1 -1
  108. package/dist/esm/AppObject/AppObjectComponent.js +78 -0
  109. package/dist/esm/AppObject/AppObjectComponent.js.map +1 -1
  110. package/dist/esm/AppObject/AppObjectController.js +22 -0
  111. package/dist/esm/AppObject/AppObjectController.js.map +1 -1
  112. package/dist/esm/AppObject/AppObjectEntity.js +52 -0
  113. package/dist/esm/AppObject/AppObjectEntity.js.map +1 -1
  114. package/dist/esm/AppObject/AppObjectEntityRepo.js +75 -1
  115. package/dist/esm/AppObject/AppObjectEntityRepo.js.map +1 -1
  116. package/dist/esm/AppObject/AppObjectPM.js +46 -0
  117. package/dist/esm/AppObject/AppObjectPM.js.map +1 -1
  118. package/dist/esm/AppObject/AppObjectRepo.js +20 -0
  119. package/dist/esm/AppObject/AppObjectRepo.js.map +1 -1
  120. package/dist/esm/AppObject/AppObjectUC.js +24 -1
  121. package/dist/esm/AppObject/AppObjectUC.js.map +1 -1
  122. package/dist/esm/AppObject/AppObjectView.js +23 -1
  123. package/dist/esm/AppObject/AppObjectView.js.map +1 -1
  124. package/dist/esm/AppObject/getSingletonComponent.js +19 -0
  125. package/dist/esm/AppObject/getSingletonComponent.js.map +1 -1
  126. package/dist/esm/Entities/MemoizedAngle.js +21 -0
  127. package/dist/esm/Entities/MemoizedAngle.js.map +1 -1
  128. package/dist/esm/Entities/MemoizedBoolean.js +21 -0
  129. package/dist/esm/Entities/MemoizedBoolean.js.map +1 -1
  130. package/dist/esm/Entities/MemoizedColor.js +21 -0
  131. package/dist/esm/Entities/MemoizedColor.js.map +1 -1
  132. package/dist/esm/Entities/MemoizedNumber.js +21 -0
  133. package/dist/esm/Entities/MemoizedNumber.js.map +1 -1
  134. package/dist/esm/Entities/MemoizedQuaternion.js +21 -0
  135. package/dist/esm/Entities/MemoizedQuaternion.js.map +1 -1
  136. package/dist/esm/Entities/MemoizedString.js +21 -0
  137. package/dist/esm/Entities/MemoizedString.js.map +1 -1
  138. package/dist/esm/Entities/MemoizedVector2.js +21 -0
  139. package/dist/esm/Entities/MemoizedVector2.js.map +1 -1
  140. package/dist/esm/Entities/MemoizedVector3.js +21 -0
  141. package/dist/esm/Entities/MemoizedVector3.js.map +1 -1
  142. package/dist/esm/Entities/ObservableEntity.js +17 -0
  143. package/dist/esm/Entities/ObservableEntity.js.map +1 -1
  144. package/dist/esm/Entities/ObserverList.js +21 -0
  145. package/dist/esm/Entities/ObserverList.js.map +1 -1
  146. package/dist/esm/Entities/RangedNumber.js +29 -0
  147. package/dist/esm/Entities/RangedNumber.js.map +1 -1
  148. package/dist/esm/ExampleFeature/Adapters/examplePmAdapter.js +61 -0
  149. package/dist/esm/ExampleFeature/Adapters/examplePmAdapter.js.map +1 -0
  150. package/dist/esm/ExampleFeature/Adapters/exampleSingletonPmAdapter.js +57 -0
  151. package/dist/esm/ExampleFeature/Adapters/exampleSingletonPmAdapter.js.map +1 -0
  152. package/dist/esm/ExampleFeature/Adapters/index.js +3 -0
  153. package/dist/esm/ExampleFeature/Adapters/index.js.map +1 -0
  154. package/dist/esm/ExampleFeature/Controllers/index.js +3 -0
  155. package/dist/esm/ExampleFeature/Controllers/index.js.map +1 -0
  156. package/dist/esm/ExampleFeature/Controllers/setExampleText.js +45 -0
  157. package/dist/esm/ExampleFeature/Controllers/setExampleText.js.map +1 -0
  158. package/dist/esm/ExampleFeature/Controllers/toggleExampleBoolean.js +44 -0
  159. package/dist/esm/ExampleFeature/Controllers/toggleExampleBoolean.js.map +1 -0
  160. package/dist/esm/ExampleFeature/Entities/ExampleEntity.js +85 -0
  161. package/dist/esm/ExampleFeature/Entities/ExampleEntity.js.map +1 -0
  162. package/dist/esm/ExampleFeature/Entities/ExampleRepo.js +108 -0
  163. package/dist/esm/ExampleFeature/Entities/ExampleRepo.js.map +1 -0
  164. package/dist/esm/ExampleFeature/Entities/ExampleSingletonEntity.js +64 -0
  165. package/dist/esm/ExampleFeature/Entities/ExampleSingletonEntity.js.map +1 -0
  166. package/dist/esm/ExampleFeature/Entities/index.js +4 -0
  167. package/dist/esm/ExampleFeature/Entities/index.js.map +1 -0
  168. package/dist/esm/ExampleFeature/Factory/index.js +2 -0
  169. package/dist/esm/ExampleFeature/Factory/index.js.map +1 -0
  170. package/dist/esm/ExampleFeature/Factory/setupExampleFeature.js +26 -0
  171. package/dist/esm/ExampleFeature/Factory/setupExampleFeature.js.map +1 -0
  172. package/dist/esm/ExampleFeature/Mocks/MockEditExampleStringUC.js +43 -0
  173. package/dist/esm/ExampleFeature/Mocks/MockEditExampleStringUC.js.map +1 -0
  174. package/dist/esm/ExampleFeature/Mocks/MockExamplePM.js +44 -0
  175. package/dist/esm/ExampleFeature/Mocks/MockExamplePM.js.map +1 -0
  176. package/dist/esm/ExampleFeature/Mocks/MockExampleSingletonPM.js +54 -0
  177. package/dist/esm/ExampleFeature/Mocks/MockExampleSingletonPM.js.map +1 -0
  178. package/dist/esm/ExampleFeature/Mocks/MockToggleExampleBooleanUC.js +52 -0
  179. package/dist/esm/ExampleFeature/Mocks/MockToggleExampleBooleanUC.js.map +1 -0
  180. package/dist/esm/ExampleFeature/Mocks/index.js +5 -0
  181. package/dist/esm/ExampleFeature/Mocks/index.js.map +1 -0
  182. package/dist/esm/ExampleFeature/PMs/ExamplePM.js +92 -0
  183. package/dist/esm/ExampleFeature/PMs/ExamplePM.js.map +1 -0
  184. package/dist/esm/ExampleFeature/PMs/ExampleSingletonPM.js +97 -0
  185. package/dist/esm/ExampleFeature/PMs/ExampleSingletonPM.js.map +1 -0
  186. package/dist/esm/ExampleFeature/PMs/index.js +3 -0
  187. package/dist/esm/ExampleFeature/PMs/index.js.map +1 -0
  188. package/dist/esm/ExampleFeature/UCs/EditExampleStringUC.js +82 -0
  189. package/dist/esm/ExampleFeature/UCs/EditExampleStringUC.js.map +1 -0
  190. package/dist/esm/ExampleFeature/UCs/ToggleExampleBooleanUC.js +74 -0
  191. package/dist/esm/ExampleFeature/UCs/ToggleExampleBooleanUC.js.map +1 -0
  192. package/dist/esm/ExampleFeature/UCs/index.js +3 -0
  193. package/dist/esm/ExampleFeature/UCs/index.js.map +1 -0
  194. package/dist/esm/ExampleFeature/index.js +8 -0
  195. package/dist/esm/ExampleFeature/index.js.map +1 -0
  196. package/dist/esm/Types/PmAdapter.js.map +1 -1
  197. package/dist/esm/Types/SingletonPmAdapter.js.map +1 -1
  198. package/dist/esm/ValueObjects/Angle.js +1 -1
  199. package/dist/esm/ValueObjects/Angle.js.map +1 -1
  200. package/dist/esm/ValueObjects/LineSegment2D.js +6 -6
  201. package/dist/esm/ValueObjects/LineSegment2D.js.map +1 -1
  202. package/dist/esm/ValueObjects/Matrix.js +6 -6
  203. package/dist/esm/ValueObjects/Matrix.js.map +1 -1
  204. package/dist/esm/ValueObjects/Quaternion.js +17 -17
  205. package/dist/esm/ValueObjects/Quaternion.js.map +1 -1
  206. package/dist/esm/ValueObjects/Vector2.js +15 -8
  207. package/dist/esm/ValueObjects/Vector2.js.map +1 -1
  208. package/dist/esm/index.js +1 -0
  209. package/dist/esm/index.js.map +1 -1
  210. package/dist/types/AppObject/AppObject.d.ts +42 -0
  211. package/dist/types/AppObject/AppObject.d.ts.map +1 -1
  212. package/dist/types/AppObject/AppObjectComponent.d.ts +80 -0
  213. package/dist/types/AppObject/AppObjectComponent.d.ts.map +1 -1
  214. package/dist/types/AppObject/AppObjectController.d.ts +22 -0
  215. package/dist/types/AppObject/AppObjectController.d.ts.map +1 -1
  216. package/dist/types/AppObject/AppObjectEntity.d.ts +55 -0
  217. package/dist/types/AppObject/AppObjectEntity.d.ts.map +1 -1
  218. package/dist/types/AppObject/AppObjectEntityRepo.d.ts +75 -0
  219. package/dist/types/AppObject/AppObjectEntityRepo.d.ts.map +1 -1
  220. package/dist/types/AppObject/AppObjectPM.d.ts +53 -0
  221. package/dist/types/AppObject/AppObjectPM.d.ts.map +1 -1
  222. package/dist/types/AppObject/AppObjectRepo.d.ts +124 -0
  223. package/dist/types/AppObject/AppObjectRepo.d.ts.map +1 -1
  224. package/dist/types/AppObject/AppObjectUC.d.ts +23 -0
  225. package/dist/types/AppObject/AppObjectUC.d.ts.map +1 -1
  226. package/dist/types/AppObject/AppObjectView.d.ts +22 -0
  227. package/dist/types/AppObject/AppObjectView.d.ts.map +1 -1
  228. package/dist/types/AppObject/getSingletonComponent.d.ts +19 -0
  229. package/dist/types/AppObject/getSingletonComponent.d.ts.map +1 -1
  230. package/dist/types/Entities/MemoizedAngle.d.ts +21 -0
  231. package/dist/types/Entities/MemoizedAngle.d.ts.map +1 -1
  232. package/dist/types/Entities/MemoizedBoolean.d.ts +21 -0
  233. package/dist/types/Entities/MemoizedBoolean.d.ts.map +1 -1
  234. package/dist/types/Entities/MemoizedColor.d.ts +21 -0
  235. package/dist/types/Entities/MemoizedColor.d.ts.map +1 -1
  236. package/dist/types/Entities/MemoizedNumber.d.ts +21 -0
  237. package/dist/types/Entities/MemoizedNumber.d.ts.map +1 -1
  238. package/dist/types/Entities/MemoizedQuaternion.d.ts +21 -0
  239. package/dist/types/Entities/MemoizedQuaternion.d.ts.map +1 -1
  240. package/dist/types/Entities/MemoizedString.d.ts +21 -0
  241. package/dist/types/Entities/MemoizedString.d.ts.map +1 -1
  242. package/dist/types/Entities/MemoizedVector2.d.ts +21 -0
  243. package/dist/types/Entities/MemoizedVector2.d.ts.map +1 -1
  244. package/dist/types/Entities/MemoizedVector3.d.ts +21 -0
  245. package/dist/types/Entities/MemoizedVector3.d.ts.map +1 -1
  246. package/dist/types/Entities/ObservableEntity.d.ts +20 -0
  247. package/dist/types/Entities/ObservableEntity.d.ts.map +1 -1
  248. package/dist/types/Entities/ObserverList.d.ts +21 -0
  249. package/dist/types/Entities/ObserverList.d.ts.map +1 -1
  250. package/dist/types/Entities/RangedNumber.d.ts +37 -0
  251. package/dist/types/Entities/RangedNumber.d.ts.map +1 -1
  252. package/dist/types/ExampleFeature/Adapters/examplePmAdapter.d.ts +29 -0
  253. package/dist/types/ExampleFeature/Adapters/examplePmAdapter.d.ts.map +1 -0
  254. package/dist/types/ExampleFeature/Adapters/exampleSingletonPmAdapter.d.ts +31 -0
  255. package/dist/types/ExampleFeature/Adapters/exampleSingletonPmAdapter.d.ts.map +1 -0
  256. package/dist/types/ExampleFeature/Adapters/index.d.ts +3 -0
  257. package/dist/types/ExampleFeature/Adapters/index.d.ts.map +1 -0
  258. package/dist/types/ExampleFeature/Controllers/index.d.ts +3 -0
  259. package/dist/types/ExampleFeature/Controllers/index.d.ts.map +1 -0
  260. package/dist/types/ExampleFeature/Controllers/setExampleText.d.ts +35 -0
  261. package/dist/types/ExampleFeature/Controllers/setExampleText.d.ts.map +1 -0
  262. package/dist/types/ExampleFeature/Controllers/toggleExampleBoolean.d.ts +34 -0
  263. package/dist/types/ExampleFeature/Controllers/toggleExampleBoolean.d.ts.map +1 -0
  264. package/dist/types/ExampleFeature/Entities/ExampleEntity.d.ts +55 -0
  265. package/dist/types/ExampleFeature/Entities/ExampleEntity.d.ts.map +1 -0
  266. package/dist/types/ExampleFeature/Entities/ExampleRepo.d.ts +62 -0
  267. package/dist/types/ExampleFeature/Entities/ExampleRepo.d.ts.map +1 -0
  268. package/dist/types/ExampleFeature/Entities/ExampleSingletonEntity.d.ts +43 -0
  269. package/dist/types/ExampleFeature/Entities/ExampleSingletonEntity.d.ts.map +1 -0
  270. package/dist/types/ExampleFeature/Entities/index.d.ts +4 -0
  271. package/dist/types/ExampleFeature/Entities/index.d.ts.map +1 -0
  272. package/dist/types/ExampleFeature/Factory/index.d.ts +2 -0
  273. package/dist/types/ExampleFeature/Factory/index.d.ts.map +1 -0
  274. package/dist/types/ExampleFeature/Factory/setupExampleFeature.d.ts +17 -0
  275. package/dist/types/ExampleFeature/Factory/setupExampleFeature.d.ts.map +1 -0
  276. package/dist/types/ExampleFeature/Mocks/MockEditExampleStringUC.d.ts +42 -0
  277. package/dist/types/ExampleFeature/Mocks/MockEditExampleStringUC.d.ts.map +1 -0
  278. package/dist/types/ExampleFeature/Mocks/MockExamplePM.d.ts +41 -0
  279. package/dist/types/ExampleFeature/Mocks/MockExamplePM.d.ts.map +1 -0
  280. package/dist/types/ExampleFeature/Mocks/MockExampleSingletonPM.d.ts +49 -0
  281. package/dist/types/ExampleFeature/Mocks/MockExampleSingletonPM.d.ts.map +1 -0
  282. package/dist/types/ExampleFeature/Mocks/MockToggleExampleBooleanUC.d.ts +47 -0
  283. package/dist/types/ExampleFeature/Mocks/MockToggleExampleBooleanUC.d.ts.map +1 -0
  284. package/dist/types/ExampleFeature/Mocks/index.d.ts +5 -0
  285. package/dist/types/ExampleFeature/Mocks/index.d.ts.map +1 -0
  286. package/dist/types/ExampleFeature/PMs/ExamplePM.d.ts +42 -0
  287. package/dist/types/ExampleFeature/PMs/ExamplePM.d.ts.map +1 -0
  288. package/dist/types/ExampleFeature/PMs/ExampleSingletonPM.d.ts +52 -0
  289. package/dist/types/ExampleFeature/PMs/ExampleSingletonPM.d.ts.map +1 -0
  290. package/dist/types/ExampleFeature/PMs/index.d.ts +3 -0
  291. package/dist/types/ExampleFeature/PMs/index.d.ts.map +1 -0
  292. package/dist/types/ExampleFeature/UCs/EditExampleStringUC.d.ts +52 -0
  293. package/dist/types/ExampleFeature/UCs/EditExampleStringUC.d.ts.map +1 -0
  294. package/dist/types/ExampleFeature/UCs/ToggleExampleBooleanUC.d.ts +44 -0
  295. package/dist/types/ExampleFeature/UCs/ToggleExampleBooleanUC.d.ts.map +1 -0
  296. package/dist/types/ExampleFeature/UCs/index.d.ts +3 -0
  297. package/dist/types/ExampleFeature/UCs/index.d.ts.map +1 -0
  298. package/dist/types/ExampleFeature/index.d.ts +8 -0
  299. package/dist/types/ExampleFeature/index.d.ts.map +1 -0
  300. package/dist/types/Types/PmAdapter.d.ts +60 -0
  301. package/dist/types/Types/PmAdapter.d.ts.map +1 -1
  302. package/dist/types/Types/SingletonPmAdapter.d.ts +55 -0
  303. package/dist/types/Types/SingletonPmAdapter.d.ts.map +1 -1
  304. package/dist/types/ValueObjects/Angle.d.ts +1 -1
  305. package/dist/types/ValueObjects/Matrix.d.ts +5 -5
  306. package/dist/types/ValueObjects/Matrix.d.ts.map +1 -1
  307. package/dist/types/ValueObjects/Quaternion.d.ts +17 -17
  308. package/dist/types/ValueObjects/Vector2.d.ts +8 -3
  309. package/dist/types/ValueObjects/Vector2.d.ts.map +1 -1
  310. package/dist/types/index.d.ts +1 -0
  311. package/dist/types/index.d.ts.map +1 -1
  312. package/package.json +6 -4
  313. package/dist/cjs/AppObject/AppObject.test.js +0 -113
  314. package/dist/cjs/AppObject/AppObject.test.js.map +0 -1
  315. package/dist/cjs/AppObject/AppObjectComponent.test.js +0 -132
  316. package/dist/cjs/AppObject/AppObjectComponent.test.js.map +0 -1
  317. package/dist/cjs/AppObject/AppObjectEntity.test.js +0 -108
  318. package/dist/cjs/AppObject/AppObjectEntity.test.js.map +0 -1
  319. package/dist/cjs/AppObject/AppObjectEntityRepo.test.js +0 -149
  320. package/dist/cjs/AppObject/AppObjectEntityRepo.test.js.map +0 -1
  321. package/dist/cjs/AppObject/AppObjectPM.test.js +0 -103
  322. package/dist/cjs/AppObject/AppObjectPM.test.js.map +0 -1
  323. package/dist/cjs/AppObject/AppObjectRepo.test.js +0 -213
  324. package/dist/cjs/AppObject/AppObjectRepo.test.js.map +0 -1
  325. package/dist/cjs/AppObject/getSingletonComponent.test.js +0 -13
  326. package/dist/cjs/AppObject/getSingletonComponent.test.js.map +0 -1
  327. package/dist/cjs/Entities/MemoizedAngle.test.js +0 -30
  328. package/dist/cjs/Entities/MemoizedAngle.test.js.map +0 -1
  329. package/dist/cjs/Entities/MemoizedBoolean.test.js +0 -34
  330. package/dist/cjs/Entities/MemoizedBoolean.test.js.map +0 -1
  331. package/dist/cjs/Entities/MemoizedColor.test.js +0 -32
  332. package/dist/cjs/Entities/MemoizedColor.test.js.map +0 -1
  333. package/dist/cjs/Entities/MemoizedNumber.test.js +0 -29
  334. package/dist/cjs/Entities/MemoizedNumber.test.js.map +0 -1
  335. package/dist/cjs/Entities/MemoizedQuaternion.test.js +0 -32
  336. package/dist/cjs/Entities/MemoizedQuaternion.test.js.map +0 -1
  337. package/dist/cjs/Entities/MemoizedString.test.js +0 -29
  338. package/dist/cjs/Entities/MemoizedString.test.js.map +0 -1
  339. package/dist/cjs/Entities/MemoizedVector2.test.js +0 -32
  340. package/dist/cjs/Entities/MemoizedVector2.test.js.map +0 -1
  341. package/dist/cjs/Entities/MemoizedVector3.test.js +0 -32
  342. package/dist/cjs/Entities/MemoizedVector3.test.js.map +0 -1
  343. package/dist/cjs/Entities/ObservableEntity.test.js +0 -25
  344. package/dist/cjs/Entities/ObservableEntity.test.js.map +0 -1
  345. package/dist/cjs/Entities/ObserverList.test.js +0 -44
  346. package/dist/cjs/Entities/ObserverList.test.js.map +0 -1
  347. package/dist/cjs/Entities/RangedNumber.test.js +0 -96
  348. package/dist/cjs/Entities/RangedNumber.test.js.map +0 -1
  349. package/dist/cjs/Utilities/LengthConverters.test.js +0 -24
  350. package/dist/cjs/Utilities/LengthConverters.test.js.map +0 -1
  351. package/dist/cjs/Utilities/LerpNumber.test.js +0 -90
  352. package/dist/cjs/Utilities/LerpNumber.test.js.map +0 -1
  353. package/dist/cjs/Utilities/addAlphaToHex.test.js +0 -34
  354. package/dist/cjs/Utilities/addAlphaToHex.test.js.map +0 -1
  355. package/dist/cjs/Utilities/alphaToHex.test.js +0 -75
  356. package/dist/cjs/Utilities/alphaToHex.test.js.map +0 -1
  357. package/dist/cjs/Utilities/degreesToRadians.test.js +0 -9
  358. package/dist/cjs/Utilities/degreesToRadians.test.js.map +0 -1
  359. package/dist/cjs/Utilities/easeFunctions.test.js +0 -209
  360. package/dist/cjs/Utilities/easeFunctions.test.js.map +0 -1
  361. package/dist/cjs/Utilities/interpolateNumber.test.js +0 -26
  362. package/dist/cjs/Utilities/interpolateNumber.test.js.map +0 -1
  363. package/dist/cjs/ValueObjects/Angle.test.js +0 -28
  364. package/dist/cjs/ValueObjects/Angle.test.js.map +0 -1
  365. package/dist/cjs/ValueObjects/Color.test.js +0 -147
  366. package/dist/cjs/ValueObjects/Color.test.js.map +0 -1
  367. package/dist/cjs/ValueObjects/LineSegment2D.test.js +0 -102
  368. package/dist/cjs/ValueObjects/LineSegment2D.test.js.map +0 -1
  369. package/dist/cjs/ValueObjects/Matrix.test.js +0 -385
  370. package/dist/cjs/ValueObjects/Matrix.test.js.map +0 -1
  371. package/dist/cjs/ValueObjects/ParametricLine.test.js +0 -126
  372. package/dist/cjs/ValueObjects/ParametricLine.test.js.map +0 -1
  373. package/dist/cjs/ValueObjects/ParametricPlane.test.js +0 -101
  374. package/dist/cjs/ValueObjects/ParametricPlane.test.js.map +0 -1
  375. package/dist/cjs/ValueObjects/Quaternion.test.js +0 -240
  376. package/dist/cjs/ValueObjects/Quaternion.test.js.map +0 -1
  377. package/dist/cjs/ValueObjects/Rectangle.test.js +0 -32
  378. package/dist/cjs/ValueObjects/Rectangle.test.js.map +0 -1
  379. package/dist/cjs/ValueObjects/Vector2.test.js +0 -136
  380. package/dist/cjs/ValueObjects/Vector2.test.js.map +0 -1
  381. package/dist/cjs/ValueObjects/Vector3.test.js +0 -188
  382. package/dist/cjs/ValueObjects/Vector3.test.js.map +0 -1
  383. package/dist/cjs/ValueObjects/Version.test.js +0 -310
  384. package/dist/cjs/ValueObjects/Version.test.js.map +0 -1
  385. package/dist/esm/AppObject/AppObject.test.js +0 -110
  386. package/dist/esm/AppObject/AppObject.test.js.map +0 -1
  387. package/dist/esm/AppObject/AppObjectComponent.test.js +0 -130
  388. package/dist/esm/AppObject/AppObjectComponent.test.js.map +0 -1
  389. package/dist/esm/AppObject/AppObjectEntity.test.js +0 -106
  390. package/dist/esm/AppObject/AppObjectEntity.test.js.map +0 -1
  391. package/dist/esm/AppObject/AppObjectEntityRepo.test.js +0 -147
  392. package/dist/esm/AppObject/AppObjectEntityRepo.test.js.map +0 -1
  393. package/dist/esm/AppObject/AppObjectPM.test.js +0 -101
  394. package/dist/esm/AppObject/AppObjectPM.test.js.map +0 -1
  395. package/dist/esm/AppObject/AppObjectRepo.test.js +0 -211
  396. package/dist/esm/AppObject/AppObjectRepo.test.js.map +0 -1
  397. package/dist/esm/AppObject/getSingletonComponent.test.js +0 -11
  398. package/dist/esm/AppObject/getSingletonComponent.test.js.map +0 -1
  399. package/dist/esm/Entities/MemoizedAngle.test.js +0 -28
  400. package/dist/esm/Entities/MemoizedAngle.test.js.map +0 -1
  401. package/dist/esm/Entities/MemoizedBoolean.test.js +0 -32
  402. package/dist/esm/Entities/MemoizedBoolean.test.js.map +0 -1
  403. package/dist/esm/Entities/MemoizedColor.test.js +0 -30
  404. package/dist/esm/Entities/MemoizedColor.test.js.map +0 -1
  405. package/dist/esm/Entities/MemoizedNumber.test.js +0 -27
  406. package/dist/esm/Entities/MemoizedNumber.test.js.map +0 -1
  407. package/dist/esm/Entities/MemoizedQuaternion.test.js +0 -30
  408. package/dist/esm/Entities/MemoizedQuaternion.test.js.map +0 -1
  409. package/dist/esm/Entities/MemoizedString.test.js +0 -27
  410. package/dist/esm/Entities/MemoizedString.test.js.map +0 -1
  411. package/dist/esm/Entities/MemoizedVector2.test.js +0 -30
  412. package/dist/esm/Entities/MemoizedVector2.test.js.map +0 -1
  413. package/dist/esm/Entities/MemoizedVector3.test.js +0 -30
  414. package/dist/esm/Entities/MemoizedVector3.test.js.map +0 -1
  415. package/dist/esm/Entities/ObservableEntity.test.js +0 -23
  416. package/dist/esm/Entities/ObservableEntity.test.js.map +0 -1
  417. package/dist/esm/Entities/ObserverList.test.js +0 -42
  418. package/dist/esm/Entities/ObserverList.test.js.map +0 -1
  419. package/dist/esm/Entities/RangedNumber.test.js +0 -94
  420. package/dist/esm/Entities/RangedNumber.test.js.map +0 -1
  421. package/dist/esm/Utilities/LengthConverters.test.js +0 -22
  422. package/dist/esm/Utilities/LengthConverters.test.js.map +0 -1
  423. package/dist/esm/Utilities/LerpNumber.test.js +0 -88
  424. package/dist/esm/Utilities/LerpNumber.test.js.map +0 -1
  425. package/dist/esm/Utilities/addAlphaToHex.test.js +0 -32
  426. package/dist/esm/Utilities/addAlphaToHex.test.js.map +0 -1
  427. package/dist/esm/Utilities/alphaToHex.test.js +0 -73
  428. package/dist/esm/Utilities/alphaToHex.test.js.map +0 -1
  429. package/dist/esm/Utilities/degreesToRadians.test.js +0 -7
  430. package/dist/esm/Utilities/degreesToRadians.test.js.map +0 -1
  431. package/dist/esm/Utilities/easeFunctions.test.js +0 -207
  432. package/dist/esm/Utilities/easeFunctions.test.js.map +0 -1
  433. package/dist/esm/Utilities/interpolateNumber.test.js +0 -24
  434. package/dist/esm/Utilities/interpolateNumber.test.js.map +0 -1
  435. package/dist/esm/ValueObjects/Angle.test.js +0 -26
  436. package/dist/esm/ValueObjects/Angle.test.js.map +0 -1
  437. package/dist/esm/ValueObjects/Color.test.js +0 -145
  438. package/dist/esm/ValueObjects/Color.test.js.map +0 -1
  439. package/dist/esm/ValueObjects/LineSegment2D.test.js +0 -100
  440. package/dist/esm/ValueObjects/LineSegment2D.test.js.map +0 -1
  441. package/dist/esm/ValueObjects/Matrix.test.js +0 -383
  442. package/dist/esm/ValueObjects/Matrix.test.js.map +0 -1
  443. package/dist/esm/ValueObjects/ParametricLine.test.js +0 -124
  444. package/dist/esm/ValueObjects/ParametricLine.test.js.map +0 -1
  445. package/dist/esm/ValueObjects/ParametricPlane.test.js +0 -99
  446. package/dist/esm/ValueObjects/ParametricPlane.test.js.map +0 -1
  447. package/dist/esm/ValueObjects/Quaternion.test.js +0 -238
  448. package/dist/esm/ValueObjects/Quaternion.test.js.map +0 -1
  449. package/dist/esm/ValueObjects/Rectangle.test.js +0 -30
  450. package/dist/esm/ValueObjects/Rectangle.test.js.map +0 -1
  451. package/dist/esm/ValueObjects/Vector2.test.js +0 -134
  452. package/dist/esm/ValueObjects/Vector2.test.js.map +0 -1
  453. package/dist/esm/ValueObjects/Vector3.test.js +0 -186
  454. package/dist/esm/ValueObjects/Vector3.test.js.map +0 -1
  455. package/dist/esm/ValueObjects/Version.test.js +0 -308
  456. package/dist/esm/ValueObjects/Version.test.js.map +0 -1
  457. package/dist/types/AppObject/AppObject.test.d.ts +0 -7
  458. package/dist/types/AppObject/AppObject.test.d.ts.map +0 -1
  459. package/dist/types/AppObject/AppObjectComponent.test.d.ts +0 -2
  460. package/dist/types/AppObject/AppObjectComponent.test.d.ts.map +0 -1
  461. package/dist/types/AppObject/AppObjectEntity.test.d.ts +0 -2
  462. package/dist/types/AppObject/AppObjectEntity.test.d.ts.map +0 -1
  463. package/dist/types/AppObject/AppObjectEntityRepo.test.d.ts +0 -2
  464. package/dist/types/AppObject/AppObjectEntityRepo.test.d.ts.map +0 -1
  465. package/dist/types/AppObject/AppObjectPM.test.d.ts +0 -2
  466. package/dist/types/AppObject/AppObjectPM.test.d.ts.map +0 -1
  467. package/dist/types/AppObject/AppObjectRepo.test.d.ts +0 -2
  468. package/dist/types/AppObject/AppObjectRepo.test.d.ts.map +0 -1
  469. package/dist/types/AppObject/getSingletonComponent.test.d.ts +0 -2
  470. package/dist/types/AppObject/getSingletonComponent.test.d.ts.map +0 -1
  471. package/dist/types/Entities/MemoizedAngle.test.d.ts +0 -2
  472. package/dist/types/Entities/MemoizedAngle.test.d.ts.map +0 -1
  473. package/dist/types/Entities/MemoizedBoolean.test.d.ts +0 -2
  474. package/dist/types/Entities/MemoizedBoolean.test.d.ts.map +0 -1
  475. package/dist/types/Entities/MemoizedColor.test.d.ts +0 -2
  476. package/dist/types/Entities/MemoizedColor.test.d.ts.map +0 -1
  477. package/dist/types/Entities/MemoizedNumber.test.d.ts +0 -2
  478. package/dist/types/Entities/MemoizedNumber.test.d.ts.map +0 -1
  479. package/dist/types/Entities/MemoizedQuaternion.test.d.ts +0 -2
  480. package/dist/types/Entities/MemoizedQuaternion.test.d.ts.map +0 -1
  481. package/dist/types/Entities/MemoizedString.test.d.ts +0 -2
  482. package/dist/types/Entities/MemoizedString.test.d.ts.map +0 -1
  483. package/dist/types/Entities/MemoizedVector2.test.d.ts +0 -2
  484. package/dist/types/Entities/MemoizedVector2.test.d.ts.map +0 -1
  485. package/dist/types/Entities/MemoizedVector3.test.d.ts +0 -2
  486. package/dist/types/Entities/MemoizedVector3.test.d.ts.map +0 -1
  487. package/dist/types/Entities/ObservableEntity.test.d.ts +0 -2
  488. package/dist/types/Entities/ObservableEntity.test.d.ts.map +0 -1
  489. package/dist/types/Entities/ObserverList.test.d.ts +0 -2
  490. package/dist/types/Entities/ObserverList.test.d.ts.map +0 -1
  491. package/dist/types/Entities/RangedNumber.test.d.ts +0 -2
  492. package/dist/types/Entities/RangedNumber.test.d.ts.map +0 -1
  493. package/dist/types/Utilities/LengthConverters.test.d.ts +0 -2
  494. package/dist/types/Utilities/LengthConverters.test.d.ts.map +0 -1
  495. package/dist/types/Utilities/LerpNumber.test.d.ts +0 -2
  496. package/dist/types/Utilities/LerpNumber.test.d.ts.map +0 -1
  497. package/dist/types/Utilities/addAlphaToHex.test.d.ts +0 -2
  498. package/dist/types/Utilities/addAlphaToHex.test.d.ts.map +0 -1
  499. package/dist/types/Utilities/alphaToHex.test.d.ts +0 -2
  500. package/dist/types/Utilities/alphaToHex.test.d.ts.map +0 -1
  501. package/dist/types/Utilities/degreesToRadians.test.d.ts +0 -2
  502. package/dist/types/Utilities/degreesToRadians.test.d.ts.map +0 -1
  503. package/dist/types/Utilities/easeFunctions.test.d.ts +0 -2
  504. package/dist/types/Utilities/easeFunctions.test.d.ts.map +0 -1
  505. package/dist/types/Utilities/interpolateNumber.test.d.ts +0 -2
  506. package/dist/types/Utilities/interpolateNumber.test.d.ts.map +0 -1
  507. package/dist/types/ValueObjects/Angle.test.d.ts +0 -2
  508. package/dist/types/ValueObjects/Angle.test.d.ts.map +0 -1
  509. package/dist/types/ValueObjects/Color.test.d.ts +0 -2
  510. package/dist/types/ValueObjects/Color.test.d.ts.map +0 -1
  511. package/dist/types/ValueObjects/LineSegment2D.test.d.ts +0 -2
  512. package/dist/types/ValueObjects/LineSegment2D.test.d.ts.map +0 -1
  513. package/dist/types/ValueObjects/Matrix.test.d.ts +0 -2
  514. package/dist/types/ValueObjects/Matrix.test.d.ts.map +0 -1
  515. package/dist/types/ValueObjects/ParametricLine.test.d.ts +0 -2
  516. package/dist/types/ValueObjects/ParametricLine.test.d.ts.map +0 -1
  517. package/dist/types/ValueObjects/ParametricPlane.test.d.ts +0 -2
  518. package/dist/types/ValueObjects/ParametricPlane.test.d.ts.map +0 -1
  519. package/dist/types/ValueObjects/Quaternion.test.d.ts +0 -2
  520. package/dist/types/ValueObjects/Quaternion.test.d.ts.map +0 -1
  521. package/dist/types/ValueObjects/Rectangle.test.d.ts +0 -2
  522. package/dist/types/ValueObjects/Rectangle.test.d.ts.map +0 -1
  523. package/dist/types/ValueObjects/Vector2.test.d.ts +0 -2
  524. package/dist/types/ValueObjects/Vector2.test.d.ts.map +0 -1
  525. package/dist/types/ValueObjects/Vector3.test.d.ts +0 -2
  526. package/dist/types/ValueObjects/Vector3.test.d.ts.map +0 -1
  527. package/dist/types/ValueObjects/Version.test.d.ts +0 -2
  528. package/dist/types/ValueObjects/Version.test.d.ts.map +0 -1
@@ -1,26 +1,106 @@
1
1
  import { AppObject } from "./AppObject";
2
2
  import { AppObjectRepo } from "./AppObjectRepo";
3
+ /**
4
+ * Enumeration of the different types of components in the architecture.
5
+ * Each type serves a specific purpose in the application structure.
6
+ */
3
7
  export declare enum AppObjectComponentType {
8
+ /** Stores and manages application state */
4
9
  ENTITY = "Entity",
10
+ /** Transforms application state into view models */
5
11
  PM = "Presentation Manager",
12
+ /** Implements business logic and coordinates between layers */
6
13
  UC = "Use Case",
14
+ /** Handles user inputs and external events */
7
15
  CONTROLLER = "Controller",
16
+ /** Renders UI elements and interacts with the DOM/rendering system */
8
17
  VIEW = "View",
18
+ /** Default type for components that don't fit the standard categories */
9
19
  UNKNOWN = "Unknown"
10
20
  }
21
+ /**
22
+ * Base class for all components in the AppObject architecture.
23
+ *
24
+ * Components attach to AppObjects and provide specific functionality based on their type.
25
+ * The architecture follows a clean separation of concerns, with each component type
26
+ * having a well-defined responsibility in the application.
27
+ *
28
+ * Components can communicate with each other through various mechanisms:
29
+ * - Direct access via parent AppObject
30
+ * - Repository-level singleton access
31
+ * - Observer patterns for reactive updates
32
+ */
11
33
  export declare class AppObjectComponent {
34
+ /** The type category of this component */
12
35
  readonly componentType: AppObjectComponentType;
36
+ /** Unique type identifier for this specific component */
13
37
  readonly type: string;
38
+ /** The parent AppObject this component is attached to */
14
39
  readonly appObject: AppObject;
40
+ /**
41
+ * Convenience accessor for the repository containing all AppObjects
42
+ * @returns The application's AppObjectRepo
43
+ */
15
44
  get appObjects(): AppObjectRepo;
45
+ /** Cache for components to avoid repeated lookups */
16
46
  private cachedComponents;
47
+ /**
48
+ * Retrieves a singleton component of the specified type from the repository
49
+ * Results are cached for better performance in repeated calls
50
+ *
51
+ * @param type The component type identifier to look up
52
+ * @returns The singleton component cast to type T, or undefined if not found
53
+ */
17
54
  getCachedSingleton<T extends AppObjectComponent>(type: string): T | undefined;
55
+ /**
56
+ * Retrieves a component from the same AppObject as this component
57
+ * Results are cached for better performance in repeated calls
58
+ *
59
+ * @param type The component type identifier to look up
60
+ * @returns The component cast to type T, or undefined if not found
61
+ */
18
62
  getCachedLocalComponent<T extends AppObjectComponent>(type: string): T | undefined;
63
+ /**
64
+ * Retrieves a singleton component from the repository with customizable logging
65
+ * Unlike getCachedSingleton, results are not cached
66
+ *
67
+ * @param type The component type identifier to look up
68
+ * @param logType The severity level for logging if component isn't found
69
+ * @returns The singleton component cast to type T, or undefined if not found
70
+ */
19
71
  getSingleton<T extends AppObjectComponent>(type: string, logType?: "LOG" | "WARN" | "ERROR"): T | undefined;
72
+ /**
73
+ * Cleans up resources used by this component
74
+ * Removes itself from the parent AppObject if it's still attached
75
+ */
20
76
  dispose(): void;
77
+ /**
78
+ * Logs an informational message to the application's logging system
79
+ * Messages are prefixed with the AppObject ID and component type for easier debugging
80
+ *
81
+ * @param message The message to log
82
+ */
21
83
  log(message: string): void;
84
+ /**
85
+ * Logs a warning message to the application's logging system
86
+ * Messages are prefixed with the AppObject ID and component type for easier debugging
87
+ *
88
+ * @param message The warning message to log
89
+ */
22
90
  warn(message: string): void;
91
+ /**
92
+ * Logs an error message to the application's logging system
93
+ * Messages are prefixed with the AppObject ID and component type for easier debugging
94
+ *
95
+ * @param message The error message to log
96
+ */
23
97
  error(message: string): void;
98
+ /**
99
+ * Creates a new component and attaches it to the specified AppObject
100
+ *
101
+ * @param appObject The parent AppObject this component will be attached to
102
+ * @param type The unique type identifier for this component
103
+ */
24
104
  constructor(appObject: AppObject, type: string);
25
105
  }
26
106
  //# sourceMappingURL=AppObjectComponent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectComponent.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectComponent.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEhD,oBAAY,sBAAsB;IAChC,MAAM,WAAW;IACjB,EAAE,yBAAyB;IAC3B,EAAE,aAAa;IACf,UAAU,eAAe;IACzB,IAAI,SAAS;IACb,OAAO,YAAY;CACpB;AAED,qBAAa,kBAAkB;IAC7B,QAAQ,CAAC,aAAa,EAAE,sBAAsB,CAAkC;IAChF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,SAAS,EAAE,SAAS,CAAC;IAC9B,IAAI,UAAU,IAAI,aAAa,CAE9B;IAED,OAAO,CAAC,gBAAgB,CAAyC;IACjE,kBAAkB,CAAC,CAAC,SAAS,kBAAkB,EAC7C,IAAI,EAAE,MAAM,GACX,CAAC,GAAG,SAAS;IAahB,uBAAuB,CAAC,CAAC,SAAS,kBAAkB,EAClD,IAAI,EAAE,MAAM,GACX,CAAC,GAAG,SAAS;IAchB,YAAY,CAAC,CAAC,SAAS,kBAAkB,EACvC,IAAI,EAAE,MAAM,EACZ,OAAO,GAAE,KAAK,GAAG,MAAM,GAAG,OAAgB,GACzC,CAAC,GAAG,SAAS;IAqBhB,OAAO;IAMP,GAAG,CAAC,OAAO,EAAE,MAAM;IAInB,IAAI,CAAC,OAAO,EAAE,MAAM;IAIpB,KAAK,CAAC,OAAO,EAAE,MAAM;gBAIT,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM;CAK/C"}
1
+ {"version":3,"file":"AppObjectComponent.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObj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AAE,MAAM;IAIrB;;;;;OAKG;gBACS,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM;CAK/C"}
@@ -1,5 +1,27 @@
1
1
  import { AppObjectComponent, AppObjectComponentType } from "./AppObjectComponent";
2
+ /**
3
+ * AppObjectController serves as a base controller class within the application framework.
4
+ *
5
+ * Controllers are components that handle logic-related operations for an AppObject,
6
+ * such as user input processing, state management, or business logic implementation.
7
+ * Extend this class to create specialized controllers for specific application features.
8
+ *
9
+ * @extends AppObjectComponent
10
+ * @example
11
+ * ```typescript
12
+ * class PlayerController extends AppObjectController {
13
+ * handleUserInput(input: UserInput) {
14
+ * // Process user input to control player object
15
+ * }
16
+ * }
17
+ * ```
18
+ */
2
19
  export declare class AppObjectController extends AppObjectComponent {
20
+ /**
21
+ * The component type identifier used to categorize this component as a controller
22
+ * This property helps the component system identify and manage controller components.
23
+ * @readonly
24
+ */
3
25
  readonly componentType = AppObjectComponentType.CONTROLLER;
4
26
  }
5
27
  //# sourceMappingURL=AppObjectController.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectController.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectController.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAE9B,qBAAa,mBAAoB,SAAQ,kBAAkB;IACzD,QAAQ,CAAC,aAAa,qCAAqC;CAC5D"}
1
+ {"version":3,"file":"AppObjectController.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectController.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,mBAAoB,SAAQ,kBAAkB;IACzD;;;;OAIG;IACH,QAAQ,CAAC,aAAa,qCAAqC;CAC5D"}
@@ -1,16 +1,71 @@
1
1
  import { AppObject } from "./AppObject";
2
2
  import { AppObjectComponent, AppObjectComponentType } from "./AppObjectComponent";
3
+ /**
4
+ * Observer function type for entity state changes or disposal
5
+ * No parameters are passed to the observer functions
6
+ */
3
7
  export type AppObjectEntityObserver = () => void;
8
+ /**
9
+ * Entity component that manages application state
10
+ *
11
+ * AppObjectEntity is responsible for storing and managing state data within the application.
12
+ * It uses the observer pattern to notify interested parties of changes to its state.
13
+ *
14
+ * In a typical application flow:
15
+ * 1. Controllers modify entity state in response to user actions
16
+ * 2. Entities notify observers (typically PMs) of state changes
17
+ * 3. PMs transform entity state into view models
18
+ * 4. Views render based on the view models
19
+ */
4
20
  export declare class AppObjectEntity extends AppObjectComponent {
21
+ /** Identifies this as an Entity component */
5
22
  readonly componentType = AppObjectComponentType.ENTITY;
23
+ /** List of observers to notify when this entity is disposed */
6
24
  private onDisposeObserverList;
25
+ /**
26
+ * Adds an observer to be notified when this entity is disposed
27
+ * @param observer Function to call on disposal
28
+ */
7
29
  addOnDisposeObserver: (observer: AppObjectEntityObserver) => void;
30
+ /**
31
+ * Removes a previously added dispose observer
32
+ * @param observer The observer function to remove
33
+ */
8
34
  removeOnDisposeObserver: (observer: AppObjectEntityObserver) => void;
35
+ /** List of observers to notify when this entity's state changes */
9
36
  private onChangeObserverList;
37
+ /**
38
+ * Adds an observer to be notified when this entity's state changes
39
+ * @param observer Function to call on state change
40
+ */
10
41
  addChangeObserver: (observer: AppObjectEntityObserver) => void;
42
+ /**
43
+ * Removes a previously added change observer
44
+ * @param observer The observer function to remove
45
+ */
11
46
  removeChangeObserver: (observer: AppObjectEntityObserver) => void;
47
+ /**
48
+ * Notifies all change observers that this entity's state has changed
49
+ * This should be called by derived classes when their state changes
50
+ */
12
51
  notifyOnChange: () => void;
52
+ /**
53
+ * Cleans up resources and notifies dispose observers
54
+ *
55
+ * This method:
56
+ * 1. Removes the change observer from the parent AppObject
57
+ * 2. Notifies all dispose observers
58
+ * 3. Clears all observer lists
59
+ * 4. Calls the parent class dispose method
60
+ */
13
61
  dispose(): void;
62
+ /**
63
+ * Creates a new entity component and attaches it to the specified AppObject
64
+ * Automatically adds the AppObject's notify method as a change observer
65
+ *
66
+ * @param appObject The parent AppObject this component will be attached to
67
+ * @param type The unique type identifier for this component
68
+ */
14
69
  constructor(appObject: AppObject, type: string);
15
70
  }
16
71
  //# sourceMappingURL=AppObjectEntity.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectEntity.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectEntity.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF,MAAM,MAAM,uBAAuB,GAAG,MAAM,IAAI,CAAC;AAEjD,qBAAa,eAAgB,SAAQ,kBAAkB;IACrD,QAAQ,CAAC,aAAa,iCAAiC;IAEvD,OAAO,CAAC,qBAAqB,CAA4B;IACzD,oBAAoB,GAAI,UAAU,uBAAuB,UAEvD;IACF,uBAAuB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAEjE;IAEF,OAAO,CAAC,oBAAoB,CAA4B;IACxD,iBAAiB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAE3D;IACF,oBAAoB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAE9D;IAEF,cAAc,aAEZ;IAEF,OAAO;gBAUK,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM;CAK/C"}
1
+ {"version":3,"file":"AppObjectEntity.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectEntity.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF;;;GAGG;AACH,MAAM,MAAM,uBAAuB,GAAG,MAAM,IAAI,CAAC;AAEjD;;;;;;;;;;;GAWG;AACH,qBAAa,eAAgB,SAAQ,kBAAkB;IACrD,6CAA6C;IAC7C,QAAQ,CAAC,aAAa,iCAAiC;IAEvD,+DAA+D;IAC/D,OAAO,CAAC,qBAAqB,CAA4B;IAEzD;;;OAGG;IACH,oBAAoB,GAAI,UAAU,uBAAuB,UAEvD;IAEF;;;OAGG;IACH,uBAAuB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAEjE;IAEF,mEAAmE;IACnE,OAAO,CAAC,oBAAoB,CAA4B;IAExD;;;OAGG;IACH,iBAAiB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAE3D;IAEF;;;OAGG;IACH,oBAAoB,GAAI,UAAU,uBAAuB,KAAG,IAAI,CAE9D;IAEF;;;OAGG;IACH,cAAc,aAEZ;IAEF;;;;;;;;OAQG;IACH,OAAO;IAUP;;;;;;OAMG;gBACS,SAAS,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM;CAM/C"}
@@ -1,16 +1,91 @@
1
1
  import { AppObjectEntity } from "./AppObjectEntity";
2
+ /**
3
+ * A repository for managing collections of AppObjectEntity instances.
4
+ *
5
+ * This generic class provides a centralized way to store, retrieve, and manage
6
+ * entities that are associated with specific AppObjects. It implements the observer
7
+ * pattern to notify listeners when entities are added or removed.
8
+ *
9
+ * @template T - The type of entities managed by this repository, must extend AppObjectEntity
10
+ * @extends AppObjectEntity
11
+ *
12
+ * @example
13
+ * ```typescript
14
+ * // Create a repository for player entities
15
+ * const playerRepo = new AppObjectEntityRepo<PlayerEntity>();
16
+ *
17
+ * // Add a new player
18
+ * const player = new PlayerEntity(appObject);
19
+ * playerRepo.add(player);
20
+ *
21
+ * // Get a player by its AppObject ID
22
+ * const retrievedPlayer = playerRepo.getForAppObject("player1");
23
+ * ```
24
+ */
2
25
  export declare class AppObjectEntityRepo<T extends AppObjectEntity> extends AppObjectEntity {
3
26
  private entityLookup;
4
27
  private onEntityAddedObservers;
28
+ /**
29
+ * Registers an observer to be notified when an entity is added to the repository.
30
+ *
31
+ * @param {(addedEntity: T) => void} observer - The callback function to invoke when an entity is added
32
+ */
5
33
  addEntityAddedObserver: (observer: (addedEntity: T) => void) => void;
34
+ /**
35
+ * Removes an observer previously registered for entity addition notifications.
36
+ *
37
+ * @param {(addedEntity: T) => void} observer - The callback function to remove
38
+ */
6
39
  removeEntityAddedObserver: (observer: (addedEntity: T) => void) => void;
7
40
  private onEntityRemovedObservers;
41
+ /**
42
+ * Registers an observer to be notified when an entity is removed from the repository.
43
+ *
44
+ * @param {(removedEntity: T) => void} observer - The callback function to invoke when an entity is removed
45
+ */
8
46
  addEntityRemovedObserver: (observer: (removedEntity: T) => void) => void;
47
+ /**
48
+ * Removes an observer previously registered for entity removal notifications.
49
+ *
50
+ * @param {(removedEntity: T) => void} observer - The callback function to remove
51
+ */
9
52
  removeEntityRemovedObserver: (observer: (removedEntity: T) => void) => void;
53
+ /**
54
+ * Checks if an entity exists for the given AppObject ID.
55
+ *
56
+ * @param {string} appObjectID - The ID of the AppObject
57
+ * @returns {boolean} True if an entity exists for the given AppObject ID, false otherwise
58
+ */
10
59
  hasForAppObject: (appObjectID: string) => boolean;
60
+ /**
61
+ * Adds an entity to the repository.
62
+ *
63
+ * If an entity with the same AppObject ID already exists, it is replaced.
64
+ * Notifies all registered observers after the entity is added.
65
+ *
66
+ * @param {T} entity - The entity to add
67
+ */
11
68
  add(entity: T): void;
69
+ /**
70
+ * Removes the entity associated with the specified AppObject ID.
71
+ *
72
+ * Notifies all registered observers after the entity is removed.
73
+ *
74
+ * @param {string} id - The ID of the AppObject whose entity should be removed
75
+ */
12
76
  removeForAppObject: (id: string) => void;
77
+ /**
78
+ * Gets the entity associated with the specified AppObject ID.
79
+ *
80
+ * @param {string} appObjectID - The ID of the AppObject
81
+ * @returns {T | undefined} The entity if found, undefined otherwise
82
+ */
13
83
  getForAppObject: (appObjectID: string) => T | undefined;
84
+ /**
85
+ * Gets all entities in the repository.
86
+ *
87
+ * @returns {T[]} An array of all entities
88
+ */
14
89
  getAll: () => T[];
15
90
  }
16
91
  //# sourceMappingURL=AppObjectEntityRepo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectEntityRepo.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectEntityRepo.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,qBAAa,mBAAmB,CAC9B,CAAC,SAAS,eAAe,CACzB,SAAQ,eAAe;IAEvB,OAAO,CAAC,YAAY,CAAwB;IAE5C,OAAO,CAAC,sBAAsB,CAAyB;IACvD,sBAAsB,GAAI,UAAU,CAAC,WAAW,EAAE,CAAC,KAAK,IAAI,UAE1D;IACF,yBAAyB,GAAI,UAAU,CAAC,WAAW,EAAE,CAAC,KAAK,IAAI,KAAG,IAAI,CAEpE;IAEF,OAAO,CAAC,wBAAwB,CAAyB;IACzD,wBAAwB,GAAI,UAAU,CAAC,aAAa,EAAE,CAAC,KAAK,IAAI,UAE9D;IACF,2BAA2B,GACzB,UAAU,CAAC,aAAa,EAAE,CAAC,KAAK,IAAI,KACnC,IAAI,CAEL;IAEF,eAAe,GAAI,aAAa,MAAM,KAAG,OAAO,CAE9C;IAEF,GAAG,CAAC,MAAM,EAAE,CAAC;IAYb,kBAAkB,GAAI,IAAI,MAAM,UAQ9B;IAEF,eAAe,GAAI,aAAa,MAAM,KAAG,CAAC,GAAG,SAAS,CAEpD;IAEF,MAAM,QAAO,CAAC,EAAE,CAEd;CACH"}
1
+ {"version":3,"file":"AppObjectEntityRepo.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectEntityRepo.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,qBAAa,mBAAmB,CAC9B,CAAC,SAAS,eAAe,CACzB,SAAQ,eAAe;IACvB,OAAO,CAAC,YAAY,CAAwB;IAE5C,OAAO,CAAC,sBAAsB,CAAyB;IACvD;;;;OAIG;IACH,sBAAsB,GAAI,UAAU,CAAC,WAAW,EAAE,CAAC,KAAK,IAAI,UAE1D;IAEF;;;;OAIG;IACH,yBAAyB,GAAI,UAAU,CAAC,WAAW,EAAE,CAAC,KAAK,IAAI,KAAG,IAAI,CAEpE;IAEF,OAAO,CAAC,wBAAwB,CAAyB;IACzD;;;;OAIG;IACH,wBAAwB,GAAI,UAAU,CAAC,aAAa,EAAE,CAAC,KAAK,IAAI,UAE9D;IAEF;;;;OAIG;IACH,2BAA2B,GACzB,UAAU,CAAC,aAAa,EAAE,CAAC,KAAK,IAAI,KACnC,IAAI,CAEL;IAEF;;;;;OAKG;IACH,eAAe,GAAI,aAAa,MAAM,KAAG,OAAO,CAE9C;IAEF;;;;;;;OAOG;IACH,GAAG,CAAC,MAAM,EAAE,CAAC;IAYb;;;;;;OAMG;IACH,kBAAkB,GAAI,IAAI,MAAM,UAQ9B;IAEF;;;;;OAKG;IACH,eAAe,GAAI,aAAa,MAAM,KAAG,CAAC,GAAG,SAAS,CAEpD;IAEF;;;;OAIG;IACH,MAAM,QAAO,CAAC,EAAE,CAEd;CACH"}
@@ -1,13 +1,66 @@
1
1
  import { AppObjectComponent, AppObjectComponentType } from "./AppObjectComponent";
2
+ /**
3
+ * Presentation Manager (PM) component that transforms application state into view models
4
+ *
5
+ * AppObjectPM acts as a mediator between application state (entities) and views.
6
+ * It transforms raw application data into a format that's optimized for presentation,
7
+ * implementing the presentation model or MVVM pattern.
8
+ *
9
+ * A PM typically:
10
+ * 1. Observes entity changes
11
+ * 2. Transforms entity data into view models
12
+ * 3. Notifies attached views when view models change
13
+ * 4. Handles view model caching and optimization
14
+ *
15
+ * @typeparam T The view model type this PM produces
16
+ */
2
17
  export declare abstract class AppObjectPM<T> extends AppObjectComponent {
18
+ /** Identifies this as a Presentation Manager component */
3
19
  readonly componentType = AppObjectComponentType.PM;
20
+ /**
21
+ * Compares two view models to determine if they're equivalent
22
+ * Used to prevent unnecessary view updates when the view model hasn't changed
23
+ *
24
+ * @param a First view model to compare
25
+ * @param b Second view model to compare
26
+ * @returns True if the view models are considered equal, false otherwise
27
+ */
4
28
  abstract vmsAreEqual(a: T, b: T): boolean;
29
+ /** The most recently generated view model */
5
30
  private _lastVM?;
31
+ /**
32
+ * Gets the most recently generated view model
33
+ * @returns The last view model or undefined if none has been generated
34
+ */
6
35
  get lastVM(): T | undefined;
36
+ /** List of view update functions to notify when the view model changes */
7
37
  private observerList;
38
+ /**
39
+ * Registers a view update function to be called when the view model changes
40
+ * If a view model already exists, the provided function is called immediately with that model
41
+ *
42
+ * @param updateView Function to call with updated view models
43
+ */
8
44
  addView(updateView: (vm: T) => void): void;
45
+ /**
46
+ * Unregisters a previously added view update function
47
+ *
48
+ * @param updateView The view update function to remove
49
+ */
9
50
  removeView(updateView: (vm: T) => void): void;
51
+ /**
52
+ * Updates the view model and notifies all registered views if the model has changed
53
+ * This method should be called by derived classes when the view model needs to be updated
54
+ *
55
+ * The method performs equality checking to prevent unnecessary updates when
56
+ * the new view model is equivalent to the previous one
57
+ *
58
+ * @param vm The new view model
59
+ */
10
60
  doUpdateView(vm: T): void;
61
+ /**
62
+ * Cleans up resources and detaches this PM from its parent AppObject
63
+ */
11
64
  dispose(): void;
12
65
  }
13
66
  //# sourceMappingURL=AppObjectPM.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectPM.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectPM.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF,8BAAsB,WAAW,CAAC,CAAC,CAAE,SAAQ,kBAAkB;IAC7D,QAAQ,CAAC,aAAa,6BAA6B;IACnD,QAAQ,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,OAAO;IAEzC,OAAO,CAAC,OAAO,CAAC,CAAI;IACpB,IAAI,MAAM,IAAI,CAAC,GAAG,SAAS,CAE1B;IAED,OAAO,CAAC,YAAY,CAAyB;IAE7C,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE,CAAC,KAAK,IAAI,GAAG,IAAI;IAQ1C,UAAU,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE,CAAC,KAAK,IAAI,GAAG,IAAI;IAI7C,YAAY,CAAC,EAAE,EAAE,CAAC;IASlB,OAAO;CAOR"}
1
+ {"version":3,"file":"AppObjectPM.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectPM.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF;;;;;;;;;;;;;;GAcG;AACH,8BAAsB,WAAW,CAAC,CAAC,CAAE,SAAQ,kBAAkB;IAC7D,0DAA0D;IAC1D,QAAQ,CAAC,aAAa,6BAA6B;IAEnD;;;;;;;OAOG;IACH,QAAQ,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,GAAG,OAAO;IAEzC,6CAA6C;IAC7C,OAAO,CAAC,OAAO,CAAC,CAAI;IAEpB;;;OAGG;IACH,IAAI,MAAM,IAAI,CAAC,GAAG,SAAS,CAE1B;IAED,0EAA0E;IAC1E,OAAO,CAAC,YAAY,CAAyB;IAE7C;;;;;OAKG;IACH,OAAO,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE,CAAC,KAAK,IAAI,GAAG,IAAI;IAS1C;;;;OAIG;IACH,UAAU,CAAC,UAAU,EAAE,CAAC,EAAE,EAAE,CAAC,KAAK,IAAI,GAAG,IAAI;IAI7C;;;;;;;;OAQG;IACH,YAAY,CAAC,EAAE,EAAE,CAAC;IAUlB;;OAEG;IACH,OAAO;CAOR"}
@@ -1,26 +1,150 @@
1
1
  import { ObservableEntity } from "../Entities";
2
2
  import { AppObject } from "./AppObject";
3
3
  import { AppObjectComponent } from "./AppObjectComponent";
4
+ /**
5
+ * Abstract repository class for managing AppObjects and their components.
6
+ *
7
+ * This class provides the interface for storing, retrieving, and managing application
8
+ * objects, their components, and singletons. It also includes logging functionality
9
+ * and observer pattern implementation for tracking changes to the repository.
10
+ *
11
+ * @extends ObservableEntity
12
+ */
4
13
  export declare abstract class AppObjectRepo extends ObservableEntity {
14
+ /**
15
+ * Checks if an AppObject with the specified ID exists in the repository.
16
+ *
17
+ * @param {string} appObjectID - The ID of the AppObject to check
18
+ * @returns {boolean} True if the AppObject exists, false otherwise
19
+ */
5
20
  abstract has(appObjectID: string): boolean;
21
+ /**
22
+ * Adds an AppObject to the repository.
23
+ *
24
+ * @param {AppObject} appObject - The AppObject to add
25
+ */
6
26
  abstract add(appObject: AppObject): void;
27
+ /**
28
+ * Removes an AppObject with the specified ID from the repository.
29
+ *
30
+ * @param {string} appObjectID - The ID of the AppObject to remove
31
+ */
7
32
  abstract remove(appObjectID: string): void;
33
+ /**
34
+ * Gets an AppObject by its ID.
35
+ *
36
+ * @param {string} appObjectID - The ID of the AppObject to retrieve
37
+ * @returns {AppObject | undefined} The AppObject if found, undefined otherwise
38
+ */
8
39
  abstract get(appObjectID: string): AppObject | undefined;
40
+ /**
41
+ * Gets an AppObject by its ID, or creates a new one if it doesn't exist.
42
+ *
43
+ * @param {string} appObjectID - The ID of the AppObject to retrieve or create
44
+ * @returns {AppObject} The existing or newly created AppObject
45
+ */
9
46
  abstract getOrCreate(appObjectID: string): AppObject;
47
+ /**
48
+ * Gets all AppObjects in the repository.
49
+ *
50
+ * @returns {AppObject[]} An array of all AppObjects
51
+ */
10
52
  abstract getAll(): AppObject[];
53
+ /**
54
+ * Logs an informational message.
55
+ *
56
+ * @param {string} sender - The identifier of the message sender
57
+ * @param {string} message - The message to log
58
+ */
11
59
  abstract submitLog(sender: string, message: string): void;
60
+ /**
61
+ * Logs a warning message.
62
+ *
63
+ * @param {string} sender - The identifier of the message sender
64
+ * @param {string} message - The warning message to log
65
+ */
12
66
  abstract submitWarning(sender: string, message: string): void;
67
+ /**
68
+ * Logs an error message.
69
+ *
70
+ * @param {string} sender - The identifier of the message sender
71
+ * @param {string} message - The error message to log
72
+ */
13
73
  abstract submitError(sender: string, message: string): void;
74
+ /**
75
+ * Logs a fatal error message.
76
+ *
77
+ * @param {string} sender - The identifier of the message sender
78
+ * @param {string} message - The fatal error message to log
79
+ */
14
80
  abstract submitFatal(sender: string, message: string): void;
81
+ /**
82
+ * Registers a component as a singleton in the repository.
83
+ *
84
+ * @param {AppObjectComponent} component - The component to register as a singleton
85
+ */
15
86
  abstract registerSingleton(component: AppObjectComponent): void;
87
+ /**
88
+ * Gets a singleton component of the specified type.
89
+ *
90
+ * @template T - Type of the component to retrieve, must extend AppObjectComponent
91
+ * @param {string} type - The type of the singleton to retrieve
92
+ * @returns {T | undefined} The singleton component if found, undefined otherwise
93
+ */
16
94
  abstract getSingleton<T extends AppObjectComponent>(type: string): T | undefined;
95
+ /**
96
+ * Gets a component of the specified type from an AppObject.
97
+ *
98
+ * @template T - Type of the component to retrieve, must extend AppObjectComponent
99
+ * @param {string} appObjectID - The ID of the AppObject containing the component
100
+ * @param {string} type - The type of the component to retrieve
101
+ * @returns {T | undefined} The component if found, undefined otherwise
102
+ */
17
103
  abstract getAppObjectComponent<T extends AppObjectComponent>(appObjectID: string, type: string): T | undefined;
104
+ /**
105
+ * Gets all AppObjects that have a component of the specified type.
106
+ *
107
+ * @param {string} componentType - The component type to filter by
108
+ * @returns {AppObject[]} An array of AppObjects having the specified component type
109
+ */
18
110
  abstract getAllAppObjectsWithComponent(componentType: string): AppObject[];
111
+ /**
112
+ * Gets all components of the specified type across all AppObjects.
113
+ *
114
+ * @template T - Type of the components to retrieve, must extend AppObjectComponent
115
+ * @param {string} type - The type of components to retrieve
116
+ * @returns {T[]} An array of all components of the specified type
117
+ */
19
118
  abstract getAllComponents<T extends AppObjectComponent>(type: string): T[];
119
+ /**
120
+ * Adds an observer to be notified when an AppObject is added to the repository.
121
+ *
122
+ * @param {(addedEntity: AppObject) => void} observer - The observer function
123
+ */
20
124
  abstract addAppObjectAddedObserver: (observer: (addedEntity: AppObject) => void) => void;
125
+ /**
126
+ * Removes an observer previously registered for AppObject addition notifications.
127
+ *
128
+ * @param {(addedEntity: AppObject) => void} observer - The observer function to remove
129
+ */
21
130
  abstract removeAppObjectAddedObserver: (observer: (addedEntity: AppObject) => void) => void;
131
+ /**
132
+ * Adds an observer to be notified when an AppObject is removed from the repository.
133
+ *
134
+ * @param {(addedEntity: AppObject) => void} observer - The observer function
135
+ */
22
136
  abstract addAppObjectRemovedObserver: (observer: (addedEntity: AppObject) => void) => void;
137
+ /**
138
+ * Removes an observer previously registered for AppObject removal notifications.
139
+ *
140
+ * @param {(addedEntity: AppObject) => void} observer - The observer function to remove
141
+ */
23
142
  abstract removedAppObjectRemovedObserver: (observer: (addedEntity: AppObject) => void) => void;
24
143
  }
144
+ /**
145
+ * Creates and returns a new AppObjectRepo instance.
146
+ *
147
+ * @returns {AppObjectRepo} A new AppObjectRepo instance
148
+ */
25
149
  export declare function makeAppObjectRepo(): AppObjectRepo;
26
150
  //# sourceMappingURL=AppObjectRepo.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectRepo.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectRepo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAgB,MAAM,aAAa,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAiB,MAAM,aAAa,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,8BAAsB,aAAc,SAAQ,gBAAgB;IAC1D,QAAQ,CAAC,GAAG,CAAC,WAAW,EAAE,MAAM,GAAG,OAAO;IAC1C,QAAQ,CAAC,GAAG,CAAC,SAAS,EAAE,SAAS,GAAG,IAAI;IACxC,QAAQ,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,GAAG,IAAI;IAC1C,QAAQ,CAAC,GAAG,CAAC,WAAW,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS;IACxD,QAAQ,CAAC,WAAW,C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3
+ * AppObjectUC (Use Case) serves as a base use case class within the application framework.
4
+ *
5
+ * Use Cases are components that represent specific application operations or workflows.
6
+ * They encapsulate business rules and coordinate interactions between different parts
7
+ * of the application. Extend this class to implement specific use case scenarios.
8
+ *
9
+ * @extends AppObjectComponent
10
+ * @example
11
+ * ```typescript
12
+ * class PurchaseItemUC extends AppObjectUC {
13
+ * execute(itemId: string, quantity: number): boolean {
14
+ * // Implement the purchase item use case
15
+ * return true; // if successful
16
+ * }
17
+ * }
18
+ * ```
19
+ */
2
20
  export declare class AppObjectUC extends AppObjectComponent {
21
+ /**
22
+ * The component type identifier used to categorize this component as a use case
23
+ * This property helps the component system identify and manage use case components.
24
+ * @readonly
25
+ */
3
26
  readonly componentType = AppObjectComponentType.UC;
4
27
  }
5
28
  //# sourceMappingURL=AppObjectUC.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectUC.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectUC.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF,qBAAa,WAAY,SAAQ,kBAAkB;IAClD,QAAQ,CAAC,aAAa,6BAA6B;CACnD"}
1
+ {"version":3,"file":"AppObjectUC.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectUC.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;;GAiBG;AACH,qBAAa,WAAY,SAAQ,kBAAkB;IACjD;;;;OAIG;IACH,QAAQ,CAAC,aAAa,6BAA6B;CACpD"}
@@ -1,5 +1,27 @@
1
1
  import { AppObjectComponent, AppObjectComponentType } from "./AppObjectComponent";
2
+ /**
3
+ * AppObjectView serves as a base view class within the application framework.
4
+ *
5
+ * Views are components that handle the visual representation of an AppObject,
6
+ * such as rendering, animations, or user interface elements. Extend this class
7
+ * to create custom visual representations for specific application objects.
8
+ *
9
+ * @extends AppObjectComponent
10
+ * @example
11
+ * ```typescript
12
+ * class PlayerView extends AppObjectView {
13
+ * render(renderContext: RenderContext) {
14
+ * // Render the player character on screen
15
+ * }
16
+ * }
17
+ * ```
18
+ */
2
19
  export declare class AppObjectView extends AppObjectComponent {
20
+ /**
21
+ * The component type identifier used to categorize this component as a view
22
+ * This property helps the component system identify and manage view components.
23
+ * @readonly
24
+ */
3
25
  readonly componentType = AppObjectComponentType.VIEW;
4
26
  }
5
27
  //# sourceMappingURL=AppObjectView.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AppObjectView.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectView.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,sBAAsB,CAAC;AAElF,qBAAa,aAAc,SAAQ,kBAAkB;IACpD,QAAQ,CAAC,aAAa,+BAA+B;CACrD"}
1
+ {"version":3,"file":"AppObjectView.d.ts","sourceRoot":"","sources":["../../../src/AppObject/AppObjectView.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,kBAAkB,EAClB,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,aAAc,SAAQ,kBAAkB;IACnD;;;;OAIG;IACH,QAAQ,CAAC,aAAa,+BAA+B;CACtD"}
@@ -1,4 +1,23 @@
1
1
  import { AppObjectComponent } from "./AppObjectComponent";
2
2
  import { AppObjectRepo } from "./AppObjectRepo";
3
+ /**
4
+ * Retrieves a singleton component of the specified type from the application objects repository.
5
+ *
6
+ * This utility function provides a convenient way to access singleton components that should
7
+ * have only one instance across the entire application.
8
+ *
9
+ * @template T - Type of the component to retrieve, must extend AppObjectComponent
10
+ * @param {string} type - The type identifier of the component to retrieve
11
+ * @param {AppObjectRepo} appObjects - The repository containing all application objects
12
+ * @returns {T | undefined} The singleton component instance if found, otherwise undefined
13
+ *
14
+ * @example
15
+ * ```typescript
16
+ * const cameraController = getSingletonComponent<CameraController>(CameraController.type, appObjectRepo);
17
+ * if (cameraController) {
18
+ * cameraController.focusOn(targetObject);
19
+ * }
20
+ * ```
21
+ */
3
22
  export declare function getSingletonComponent<T extends AppObjectComponent>(type: string, appObjects: AppObjectRepo): T | undefined;
4
23
  //# sourceMappingURL=getSingletonComponent.d.ts.map