@fluidframework/tree 2.10.0-307399 → 2.11.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (472) hide show
  1. package/CHANGELOG.md +103 -0
  2. package/api-report/tree.alpha.api.md +47 -16
  3. package/api-report/tree.beta.api.md +5 -14
  4. package/api-report/tree.legacy.alpha.api.md +5 -14
  5. package/api-report/tree.legacy.public.api.md +5 -14
  6. package/api-report/tree.public.api.md +5 -14
  7. package/dist/alpha.d.ts +9 -0
  8. package/dist/core/forest/forest.d.ts +10 -2
  9. package/dist/core/forest/forest.d.ts.map +1 -1
  10. package/dist/core/forest/forest.js.map +1 -1
  11. package/dist/core/index.d.ts +2 -2
  12. package/dist/core/index.d.ts.map +1 -1
  13. package/dist/core/index.js +3 -2
  14. package/dist/core/index.js.map +1 -1
  15. package/dist/core/rebase/utils.d.ts +1 -1
  16. package/dist/core/rebase/utils.d.ts.map +1 -1
  17. package/dist/core/rebase/utils.js +11 -8
  18. package/dist/core/rebase/utils.js.map +1 -1
  19. package/dist/core/revertible.d.ts +30 -1
  20. package/dist/core/revertible.d.ts.map +1 -1
  21. package/dist/core/revertible.js.map +1 -1
  22. package/dist/core/schema-stored/storedSchemaRepository.d.ts +2 -2
  23. package/dist/core/schema-stored/storedSchemaRepository.d.ts.map +1 -1
  24. package/dist/core/schema-stored/storedSchemaRepository.js +5 -5
  25. package/dist/core/schema-stored/storedSchemaRepository.js.map +1 -1
  26. package/dist/core/tree/anchorSet.d.ts +2 -2
  27. package/dist/core/tree/anchorSet.d.ts.map +1 -1
  28. package/dist/core/tree/anchorSet.js +21 -21
  29. package/dist/core/tree/anchorSet.js.map +1 -1
  30. package/dist/core/tree/detachedFieldIndexCodec.d.ts.map +1 -1
  31. package/dist/core/tree/detachedFieldIndexCodec.js +3 -2
  32. package/dist/core/tree/detachedFieldIndexCodec.js.map +1 -1
  33. package/dist/core/tree/index.d.ts +1 -1
  34. package/dist/core/tree/index.d.ts.map +1 -1
  35. package/dist/core/tree/index.js +2 -1
  36. package/dist/core/tree/index.js.map +1 -1
  37. package/dist/core/tree/visitorUtils.d.ts +25 -1
  38. package/dist/core/tree/visitorUtils.d.ts.map +1 -1
  39. package/dist/core/tree/visitorUtils.js +29 -1
  40. package/dist/core/tree/visitorUtils.js.map +1 -1
  41. package/dist/feature-libraries/chunked-forest/chunkedForest.d.ts +5 -2
  42. package/dist/feature-libraries/chunked-forest/chunkedForest.d.ts.map +1 -1
  43. package/dist/feature-libraries/chunked-forest/chunkedForest.js +24 -14
  44. package/dist/feature-libraries/chunked-forest/chunkedForest.js.map +1 -1
  45. package/dist/feature-libraries/chunked-forest/uniformChunk.d.ts.map +1 -1
  46. package/dist/feature-libraries/chunked-forest/uniformChunk.js +2 -2
  47. package/dist/feature-libraries/chunked-forest/uniformChunk.js.map +1 -1
  48. package/dist/feature-libraries/flex-tree/context.d.ts +1 -1
  49. package/dist/feature-libraries/flex-tree/context.d.ts.map +1 -1
  50. package/dist/feature-libraries/flex-tree/context.js.map +1 -1
  51. package/dist/feature-libraries/index.d.ts +1 -0
  52. package/dist/feature-libraries/index.d.ts.map +1 -1
  53. package/dist/feature-libraries/index.js +4 -1
  54. package/dist/feature-libraries/index.js.map +1 -1
  55. package/dist/feature-libraries/indexing/anchorTreeIndex.d.ts +132 -0
  56. package/dist/feature-libraries/indexing/anchorTreeIndex.d.ts.map +1 -0
  57. package/dist/feature-libraries/indexing/anchorTreeIndex.js +361 -0
  58. package/dist/feature-libraries/indexing/anchorTreeIndex.js.map +1 -0
  59. package/dist/feature-libraries/indexing/index.d.ts +7 -0
  60. package/dist/feature-libraries/indexing/index.d.ts.map +1 -0
  61. package/dist/feature-libraries/indexing/index.js +11 -0
  62. package/dist/feature-libraries/indexing/index.js.map +1 -0
  63. package/dist/feature-libraries/indexing/types.d.ts +32 -0
  64. package/dist/feature-libraries/indexing/types.d.ts.map +1 -0
  65. package/dist/{events/interop.js → feature-libraries/indexing/types.js} +1 -1
  66. package/dist/feature-libraries/indexing/types.js.map +1 -0
  67. package/dist/feature-libraries/modular-schema/discrepancies.js +1 -1
  68. package/dist/feature-libraries/modular-schema/discrepancies.js.map +1 -1
  69. package/dist/feature-libraries/object-forest/objectForest.d.ts +5 -2
  70. package/dist/feature-libraries/object-forest/objectForest.d.ts.map +1 -1
  71. package/dist/feature-libraries/object-forest/objectForest.js +21 -11
  72. package/dist/feature-libraries/object-forest/objectForest.js.map +1 -1
  73. package/dist/feature-libraries/sequence-field/invert.d.ts.map +1 -1
  74. package/dist/feature-libraries/sequence-field/invert.js +2 -2
  75. package/dist/feature-libraries/sequence-field/invert.js.map +1 -1
  76. package/dist/feature-libraries/sequence-field/sequenceFieldToDelta.js +3 -2
  77. package/dist/feature-libraries/sequence-field/sequenceFieldToDelta.js.map +1 -1
  78. package/dist/index.d.ts +4 -4
  79. package/dist/index.d.ts.map +1 -1
  80. package/dist/index.js +4 -1
  81. package/dist/index.js.map +1 -1
  82. package/dist/packageVersion.d.ts +1 -1
  83. package/dist/packageVersion.d.ts.map +1 -1
  84. package/dist/packageVersion.js +1 -1
  85. package/dist/packageVersion.js.map +1 -1
  86. package/dist/shared-tree/index.d.ts +1 -1
  87. package/dist/shared-tree/index.d.ts.map +1 -1
  88. package/dist/shared-tree/index.js +1 -2
  89. package/dist/shared-tree/index.js.map +1 -1
  90. package/dist/shared-tree/schematizingTreeView.d.ts +7 -1
  91. package/dist/shared-tree/schematizingTreeView.d.ts.map +1 -1
  92. package/dist/shared-tree/schematizingTreeView.js +31 -30
  93. package/dist/shared-tree/schematizingTreeView.js.map +1 -1
  94. package/dist/shared-tree/sharedTree.d.ts +3 -0
  95. package/dist/shared-tree/sharedTree.d.ts.map +1 -1
  96. package/dist/shared-tree/sharedTree.js +56 -20
  97. package/dist/shared-tree/sharedTree.js.map +1 -1
  98. package/dist/shared-tree/sharedTreeChangeFamily.d.ts.map +1 -1
  99. package/dist/shared-tree/sharedTreeChangeFamily.js +3 -3
  100. package/dist/shared-tree/sharedTreeChangeFamily.js.map +1 -1
  101. package/dist/shared-tree/treeCheckout.d.ts +32 -64
  102. package/dist/shared-tree/treeCheckout.d.ts.map +1 -1
  103. package/dist/shared-tree/treeCheckout.js +161 -125
  104. package/dist/shared-tree/treeCheckout.js.map +1 -1
  105. package/dist/shared-tree-core/branch.d.ts +25 -81
  106. package/dist/shared-tree-core/branch.d.ts.map +1 -1
  107. package/dist/shared-tree-core/branch.js +72 -151
  108. package/dist/shared-tree-core/branch.js.map +1 -1
  109. package/dist/shared-tree-core/branchCommitEnricher.d.ts +19 -33
  110. package/dist/shared-tree-core/branchCommitEnricher.d.ts.map +1 -1
  111. package/dist/shared-tree-core/branchCommitEnricher.js +73 -54
  112. package/dist/shared-tree-core/branchCommitEnricher.js.map +1 -1
  113. package/dist/shared-tree-core/defaultResubmitMachine.d.ts.map +1 -1
  114. package/dist/shared-tree-core/defaultResubmitMachine.js +2 -1
  115. package/dist/shared-tree-core/defaultResubmitMachine.js.map +1 -1
  116. package/dist/shared-tree-core/editManager.d.ts.map +1 -1
  117. package/dist/shared-tree-core/editManager.js +2 -2
  118. package/dist/shared-tree-core/editManager.js.map +1 -1
  119. package/dist/shared-tree-core/index.d.ts +1 -1
  120. package/dist/shared-tree-core/index.d.ts.map +1 -1
  121. package/dist/shared-tree-core/index.js +4 -3
  122. package/dist/shared-tree-core/index.js.map +1 -1
  123. package/dist/shared-tree-core/sharedTreeCore.d.ts +2 -2
  124. package/dist/shared-tree-core/sharedTreeCore.d.ts.map +1 -1
  125. package/dist/shared-tree-core/sharedTreeCore.js +11 -52
  126. package/dist/shared-tree-core/sharedTreeCore.js.map +1 -1
  127. package/dist/shared-tree-core/transaction.d.ts +108 -0
  128. package/dist/shared-tree-core/transaction.d.ts.map +1 -0
  129. package/dist/shared-tree-core/transaction.js +99 -0
  130. package/dist/shared-tree-core/transaction.js.map +1 -0
  131. package/dist/shared-tree-core/transactionEnricher.d.ts +8 -13
  132. package/dist/shared-tree-core/transactionEnricher.d.ts.map +1 -1
  133. package/dist/shared-tree-core/transactionEnricher.js +41 -21
  134. package/dist/shared-tree-core/transactionEnricher.js.map +1 -1
  135. package/dist/simple-tree/api/identifierIndex.d.ts +21 -0
  136. package/dist/simple-tree/api/identifierIndex.d.ts.map +1 -0
  137. package/dist/simple-tree/api/identifierIndex.js +45 -0
  138. package/dist/simple-tree/api/identifierIndex.js.map +1 -0
  139. package/dist/simple-tree/api/index.d.ts +2 -0
  140. package/dist/simple-tree/api/index.d.ts.map +1 -1
  141. package/dist/simple-tree/api/index.js +5 -1
  142. package/dist/simple-tree/api/index.js.map +1 -1
  143. package/dist/simple-tree/api/simpleSchemaToJsonSchema.js +9 -7
  144. package/dist/simple-tree/api/simpleSchemaToJsonSchema.js.map +1 -1
  145. package/dist/simple-tree/api/simpleTreeIndex.d.ts +65 -0
  146. package/dist/simple-tree/api/simpleTreeIndex.d.ts.map +1 -0
  147. package/dist/simple-tree/api/simpleTreeIndex.js +91 -0
  148. package/dist/simple-tree/api/simpleTreeIndex.js.map +1 -0
  149. package/dist/simple-tree/api/tree.d.ts +4 -5
  150. package/dist/simple-tree/api/tree.d.ts.map +1 -1
  151. package/dist/simple-tree/api/tree.js.map +1 -1
  152. package/dist/simple-tree/api/treeNodeApi.js.map +1 -1
  153. package/dist/simple-tree/core/index.d.ts +1 -1
  154. package/dist/simple-tree/core/index.d.ts.map +1 -1
  155. package/dist/simple-tree/core/index.js +2 -1
  156. package/dist/simple-tree/core/index.js.map +1 -1
  157. package/dist/simple-tree/core/treeNodeKernel.d.ts +6 -2
  158. package/dist/simple-tree/core/treeNodeKernel.d.ts.map +1 -1
  159. package/dist/simple-tree/core/treeNodeKernel.js +53 -22
  160. package/dist/simple-tree/core/treeNodeKernel.js.map +1 -1
  161. package/dist/simple-tree/core/unhydratedFlexTree.d.ts +1 -1
  162. package/dist/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  163. package/dist/simple-tree/core/unhydratedFlexTree.js +2 -2
  164. package/dist/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  165. package/dist/simple-tree/index.d.ts +1 -1
  166. package/dist/simple-tree/index.d.ts.map +1 -1
  167. package/dist/simple-tree/index.js +4 -2
  168. package/dist/simple-tree/index.js.map +1 -1
  169. package/dist/simple-tree/objectNode.d.ts +7 -2
  170. package/dist/simple-tree/objectNode.d.ts.map +1 -1
  171. package/dist/simple-tree/objectNode.js.map +1 -1
  172. package/dist/simple-tree/toMapTree.js +3 -3
  173. package/dist/simple-tree/toMapTree.js.map +1 -1
  174. package/dist/util/index.d.ts +1 -2
  175. package/dist/util/index.d.ts.map +1 -1
  176. package/dist/util/index.js +5 -4
  177. package/dist/util/index.js.map +1 -1
  178. package/dist/util/typeCheck.d.ts +6 -1
  179. package/dist/util/typeCheck.d.ts.map +1 -1
  180. package/dist/util/typeCheck.js.map +1 -1
  181. package/dist/util/typeCheckTests.d.ts +14 -2
  182. package/dist/util/typeCheckTests.d.ts.map +1 -1
  183. package/dist/util/typeCheckTests.js.map +1 -1
  184. package/dist/util/utils.d.ts +29 -0
  185. package/dist/util/utils.d.ts.map +1 -1
  186. package/dist/util/utils.js +13 -1
  187. package/dist/util/utils.js.map +1 -1
  188. package/lib/alpha.d.ts +9 -0
  189. package/lib/core/forest/forest.d.ts +10 -2
  190. package/lib/core/forest/forest.d.ts.map +1 -1
  191. package/lib/core/forest/forest.js.map +1 -1
  192. package/lib/core/index.d.ts +2 -2
  193. package/lib/core/index.d.ts.map +1 -1
  194. package/lib/core/index.js +2 -2
  195. package/lib/core/index.js.map +1 -1
  196. package/lib/core/rebase/utils.d.ts +1 -1
  197. package/lib/core/rebase/utils.d.ts.map +1 -1
  198. package/lib/core/rebase/utils.js +11 -8
  199. package/lib/core/rebase/utils.js.map +1 -1
  200. package/lib/core/revertible.d.ts +30 -1
  201. package/lib/core/revertible.d.ts.map +1 -1
  202. package/lib/core/revertible.js.map +1 -1
  203. package/lib/core/schema-stored/storedSchemaRepository.d.ts +2 -2
  204. package/lib/core/schema-stored/storedSchemaRepository.d.ts.map +1 -1
  205. package/lib/core/schema-stored/storedSchemaRepository.js +1 -1
  206. package/lib/core/schema-stored/storedSchemaRepository.js.map +1 -1
  207. package/lib/core/tree/anchorSet.d.ts +2 -2
  208. package/lib/core/tree/anchorSet.d.ts.map +1 -1
  209. package/lib/core/tree/anchorSet.js +1 -1
  210. package/lib/core/tree/anchorSet.js.map +1 -1
  211. package/lib/core/tree/detachedFieldIndexCodec.d.ts.map +1 -1
  212. package/lib/core/tree/detachedFieldIndexCodec.js +4 -3
  213. package/lib/core/tree/detachedFieldIndexCodec.js.map +1 -1
  214. package/lib/core/tree/index.d.ts +1 -1
  215. package/lib/core/tree/index.d.ts.map +1 -1
  216. package/lib/core/tree/index.js +1 -1
  217. package/lib/core/tree/index.js.map +1 -1
  218. package/lib/core/tree/visitorUtils.d.ts +25 -1
  219. package/lib/core/tree/visitorUtils.d.ts.map +1 -1
  220. package/lib/core/tree/visitorUtils.js +27 -0
  221. package/lib/core/tree/visitorUtils.js.map +1 -1
  222. package/lib/feature-libraries/chunked-forest/chunkedForest.d.ts +5 -2
  223. package/lib/feature-libraries/chunked-forest/chunkedForest.d.ts.map +1 -1
  224. package/lib/feature-libraries/chunked-forest/chunkedForest.js +18 -8
  225. package/lib/feature-libraries/chunked-forest/chunkedForest.js.map +1 -1
  226. package/lib/feature-libraries/chunked-forest/uniformChunk.d.ts.map +1 -1
  227. package/lib/feature-libraries/chunked-forest/uniformChunk.js +3 -3
  228. package/lib/feature-libraries/chunked-forest/uniformChunk.js.map +1 -1
  229. package/lib/feature-libraries/flex-tree/context.d.ts +1 -1
  230. package/lib/feature-libraries/flex-tree/context.d.ts.map +1 -1
  231. package/lib/feature-libraries/flex-tree/context.js.map +1 -1
  232. package/lib/feature-libraries/index.d.ts +1 -0
  233. package/lib/feature-libraries/index.d.ts.map +1 -1
  234. package/lib/feature-libraries/index.js +1 -0
  235. package/lib/feature-libraries/index.js.map +1 -1
  236. package/lib/feature-libraries/indexing/anchorTreeIndex.d.ts +132 -0
  237. package/lib/feature-libraries/indexing/anchorTreeIndex.d.ts.map +1 -0
  238. package/lib/feature-libraries/indexing/anchorTreeIndex.js +356 -0
  239. package/lib/feature-libraries/indexing/anchorTreeIndex.js.map +1 -0
  240. package/lib/feature-libraries/indexing/index.d.ts +7 -0
  241. package/lib/feature-libraries/indexing/index.d.ts.map +1 -0
  242. package/lib/{events → feature-libraries/indexing}/index.js +1 -1
  243. package/lib/feature-libraries/indexing/index.js.map +1 -0
  244. package/lib/feature-libraries/indexing/types.d.ts +32 -0
  245. package/lib/feature-libraries/indexing/types.d.ts.map +1 -0
  246. package/lib/{events/interop.js → feature-libraries/indexing/types.js} +1 -1
  247. package/lib/feature-libraries/indexing/types.js.map +1 -0
  248. package/lib/feature-libraries/modular-schema/discrepancies.js +1 -1
  249. package/lib/feature-libraries/modular-schema/discrepancies.js.map +1 -1
  250. package/lib/feature-libraries/object-forest/objectForest.d.ts +5 -2
  251. package/lib/feature-libraries/object-forest/objectForest.d.ts.map +1 -1
  252. package/lib/feature-libraries/object-forest/objectForest.js +15 -5
  253. package/lib/feature-libraries/object-forest/objectForest.js.map +1 -1
  254. package/lib/feature-libraries/sequence-field/invert.d.ts.map +1 -1
  255. package/lib/feature-libraries/sequence-field/invert.js +4 -4
  256. package/lib/feature-libraries/sequence-field/invert.js.map +1 -1
  257. package/lib/feature-libraries/sequence-field/sequenceFieldToDelta.js +4 -3
  258. package/lib/feature-libraries/sequence-field/sequenceFieldToDelta.js.map +1 -1
  259. package/lib/index.d.ts +4 -4
  260. package/lib/index.d.ts.map +1 -1
  261. package/lib/index.js +1 -1
  262. package/lib/index.js.map +1 -1
  263. package/lib/packageVersion.d.ts +1 -1
  264. package/lib/packageVersion.d.ts.map +1 -1
  265. package/lib/packageVersion.js +1 -1
  266. package/lib/packageVersion.js.map +1 -1
  267. package/lib/shared-tree/index.d.ts +1 -1
  268. package/lib/shared-tree/index.d.ts.map +1 -1
  269. package/lib/shared-tree/index.js +1 -1
  270. package/lib/shared-tree/index.js.map +1 -1
  271. package/lib/shared-tree/schematizingTreeView.d.ts +7 -1
  272. package/lib/shared-tree/schematizingTreeView.d.ts.map +1 -1
  273. package/lib/shared-tree/schematizingTreeView.js +2 -2
  274. package/lib/shared-tree/schematizingTreeView.js.map +1 -1
  275. package/lib/shared-tree/sharedTree.d.ts +3 -0
  276. package/lib/shared-tree/sharedTree.d.ts.map +1 -1
  277. package/lib/shared-tree/sharedTree.js +37 -1
  278. package/lib/shared-tree/sharedTree.js.map +1 -1
  279. package/lib/shared-tree/sharedTreeChangeFamily.d.ts.map +1 -1
  280. package/lib/shared-tree/sharedTreeChangeFamily.js +5 -5
  281. package/lib/shared-tree/sharedTreeChangeFamily.js.map +1 -1
  282. package/lib/shared-tree/treeCheckout.d.ts +32 -64
  283. package/lib/shared-tree/treeCheckout.d.ts.map +1 -1
  284. package/lib/shared-tree/treeCheckout.js +149 -112
  285. package/lib/shared-tree/treeCheckout.js.map +1 -1
  286. package/lib/shared-tree-core/branch.d.ts +25 -81
  287. package/lib/shared-tree-core/branch.d.ts.map +1 -1
  288. package/lib/shared-tree-core/branch.js +72 -151
  289. package/lib/shared-tree-core/branch.js.map +1 -1
  290. package/lib/shared-tree-core/branchCommitEnricher.d.ts +19 -33
  291. package/lib/shared-tree-core/branchCommitEnricher.d.ts.map +1 -1
  292. package/lib/shared-tree-core/branchCommitEnricher.js +74 -55
  293. package/lib/shared-tree-core/branchCommitEnricher.js.map +1 -1
  294. package/lib/shared-tree-core/defaultResubmitMachine.d.ts.map +1 -1
  295. package/lib/shared-tree-core/defaultResubmitMachine.js +3 -2
  296. package/lib/shared-tree-core/defaultResubmitMachine.js.map +1 -1
  297. package/lib/shared-tree-core/editManager.d.ts.map +1 -1
  298. package/lib/shared-tree-core/editManager.js +1 -1
  299. package/lib/shared-tree-core/editManager.js.map +1 -1
  300. package/lib/shared-tree-core/index.d.ts +1 -1
  301. package/lib/shared-tree-core/index.d.ts.map +1 -1
  302. package/lib/shared-tree-core/index.js +1 -1
  303. package/lib/shared-tree-core/index.js.map +1 -1
  304. package/lib/shared-tree-core/sharedTreeCore.d.ts +2 -2
  305. package/lib/shared-tree-core/sharedTreeCore.d.ts.map +1 -1
  306. package/lib/shared-tree-core/sharedTreeCore.js +12 -53
  307. package/lib/shared-tree-core/sharedTreeCore.js.map +1 -1
  308. package/lib/shared-tree-core/transaction.d.ts +108 -0
  309. package/lib/shared-tree-core/transaction.d.ts.map +1 -0
  310. package/lib/shared-tree-core/transaction.js +95 -0
  311. package/lib/shared-tree-core/transaction.js.map +1 -0
  312. package/lib/shared-tree-core/transactionEnricher.d.ts +8 -13
  313. package/lib/shared-tree-core/transactionEnricher.d.ts.map +1 -1
  314. package/lib/shared-tree-core/transactionEnricher.js +41 -21
  315. package/lib/shared-tree-core/transactionEnricher.js.map +1 -1
  316. package/lib/simple-tree/api/identifierIndex.d.ts +21 -0
  317. package/lib/simple-tree/api/identifierIndex.d.ts.map +1 -0
  318. package/lib/simple-tree/api/identifierIndex.js +41 -0
  319. package/lib/simple-tree/api/identifierIndex.js.map +1 -0
  320. package/lib/simple-tree/api/index.d.ts +2 -0
  321. package/lib/simple-tree/api/index.d.ts.map +1 -1
  322. package/lib/simple-tree/api/index.js +2 -0
  323. package/lib/simple-tree/api/index.js.map +1 -1
  324. package/lib/simple-tree/api/simpleSchemaToJsonSchema.js +11 -9
  325. package/lib/simple-tree/api/simpleSchemaToJsonSchema.js.map +1 -1
  326. package/lib/simple-tree/api/simpleTreeIndex.d.ts +65 -0
  327. package/lib/simple-tree/api/simpleTreeIndex.d.ts.map +1 -0
  328. package/lib/simple-tree/api/simpleTreeIndex.js +87 -0
  329. package/lib/simple-tree/api/simpleTreeIndex.js.map +1 -0
  330. package/lib/simple-tree/api/tree.d.ts +4 -5
  331. package/lib/simple-tree/api/tree.d.ts.map +1 -1
  332. package/lib/simple-tree/api/tree.js.map +1 -1
  333. package/lib/simple-tree/api/treeNodeApi.js.map +1 -1
  334. package/lib/simple-tree/core/index.d.ts +1 -1
  335. package/lib/simple-tree/core/index.d.ts.map +1 -1
  336. package/lib/simple-tree/core/index.js +1 -1
  337. package/lib/simple-tree/core/index.js.map +1 -1
  338. package/lib/simple-tree/core/treeNodeKernel.d.ts +6 -2
  339. package/lib/simple-tree/core/treeNodeKernel.d.ts.map +1 -1
  340. package/lib/simple-tree/core/treeNodeKernel.js +31 -1
  341. package/lib/simple-tree/core/treeNodeKernel.js.map +1 -1
  342. package/lib/simple-tree/core/unhydratedFlexTree.d.ts +1 -1
  343. package/lib/simple-tree/core/unhydratedFlexTree.d.ts.map +1 -1
  344. package/lib/simple-tree/core/unhydratedFlexTree.js +1 -1
  345. package/lib/simple-tree/core/unhydratedFlexTree.js.map +1 -1
  346. package/lib/simple-tree/index.d.ts +1 -1
  347. package/lib/simple-tree/index.d.ts.map +1 -1
  348. package/lib/simple-tree/index.js +1 -1
  349. package/lib/simple-tree/index.js.map +1 -1
  350. package/lib/simple-tree/objectNode.d.ts +7 -2
  351. package/lib/simple-tree/objectNode.d.ts.map +1 -1
  352. package/lib/simple-tree/objectNode.js.map +1 -1
  353. package/lib/simple-tree/toMapTree.js +5 -5
  354. package/lib/simple-tree/toMapTree.js.map +1 -1
  355. package/lib/util/index.d.ts +1 -2
  356. package/lib/util/index.d.ts.map +1 -1
  357. package/lib/util/index.js +1 -2
  358. package/lib/util/index.js.map +1 -1
  359. package/lib/util/typeCheck.d.ts +6 -1
  360. package/lib/util/typeCheck.d.ts.map +1 -1
  361. package/lib/util/typeCheck.js.map +1 -1
  362. package/lib/util/typeCheckTests.d.ts +14 -2
  363. package/lib/util/typeCheckTests.d.ts.map +1 -1
  364. package/lib/util/typeCheckTests.js.map +1 -1
  365. package/lib/util/utils.d.ts +29 -0
  366. package/lib/util/utils.d.ts.map +1 -1
  367. package/lib/util/utils.js +9 -0
  368. package/lib/util/utils.js.map +1 -1
  369. package/package.json +23 -23
  370. package/src/core/forest/forest.ts +12 -1
  371. package/src/core/index.ts +8 -1
  372. package/src/core/rebase/utils.ts +12 -10
  373. package/src/core/revertible.ts +35 -1
  374. package/src/core/schema-stored/storedSchemaRepository.ts +2 -1
  375. package/src/core/tree/anchorSet.ts +2 -1
  376. package/src/core/tree/detachedFieldIndexCodec.ts +4 -3
  377. package/src/core/tree/index.ts +1 -0
  378. package/src/core/tree/visitorUtils.ts +56 -1
  379. package/src/feature-libraries/chunked-forest/chunkedForest.ts +33 -7
  380. package/src/feature-libraries/chunked-forest/uniformChunk.ts +3 -3
  381. package/src/feature-libraries/flex-tree/context.ts +1 -1
  382. package/src/feature-libraries/index.ts +9 -0
  383. package/src/feature-libraries/indexing/anchorTreeIndex.ts +453 -0
  384. package/src/feature-libraries/indexing/index.ts +11 -0
  385. package/src/feature-libraries/indexing/types.ts +37 -0
  386. package/src/feature-libraries/modular-schema/discrepancies.ts +1 -1
  387. package/src/feature-libraries/object-forest/objectForest.ts +22 -4
  388. package/src/feature-libraries/sequence-field/invert.ts +4 -4
  389. package/src/feature-libraries/sequence-field/sequenceFieldToDelta.ts +4 -4
  390. package/src/index.ts +16 -6
  391. package/src/packageVersion.ts +1 -1
  392. package/src/shared-tree/index.ts +0 -2
  393. package/src/shared-tree/schematizingTreeView.ts +7 -7
  394. package/src/shared-tree/sharedTree.ts +60 -6
  395. package/src/shared-tree/sharedTreeChangeFamily.ts +5 -4
  396. package/src/shared-tree/treeCheckout.ts +201 -189
  397. package/src/shared-tree-core/branch.ts +93 -220
  398. package/src/shared-tree-core/branchCommitEnricher.ts +69 -64
  399. package/src/shared-tree-core/defaultResubmitMachine.ts +3 -2
  400. package/src/shared-tree-core/editManager.ts +1 -1
  401. package/src/shared-tree-core/index.ts +9 -2
  402. package/src/shared-tree-core/sharedTreeCore.ts +17 -62
  403. package/src/shared-tree-core/transaction.ts +165 -0
  404. package/src/shared-tree-core/transactionEnricher.ts +30 -24
  405. package/src/simple-tree/api/identifierIndex.ts +64 -0
  406. package/src/simple-tree/api/index.ts +5 -0
  407. package/src/simple-tree/api/simpleSchemaToJsonSchema.ts +17 -18
  408. package/src/simple-tree/api/simpleTreeIndex.ts +231 -0
  409. package/src/simple-tree/api/tree.ts +8 -5
  410. package/src/simple-tree/api/treeNodeApi.ts +1 -1
  411. package/src/simple-tree/core/index.ts +1 -0
  412. package/src/simple-tree/core/treeNodeKernel.ts +37 -2
  413. package/src/simple-tree/core/unhydratedFlexTree.ts +2 -1
  414. package/src/simple-tree/index.ts +4 -0
  415. package/src/simple-tree/objectNode.ts +19 -12
  416. package/src/simple-tree/toMapTree.ts +5 -5
  417. package/src/util/index.ts +3 -1
  418. package/src/util/typeCheck.ts +6 -1
  419. package/src/util/typeCheckTests.ts +11 -1
  420. package/src/util/utils.ts +38 -0
  421. package/dist/events/emitter.d.ts +0 -139
  422. package/dist/events/emitter.d.ts.map +0 -1
  423. package/dist/events/emitter.js +0 -165
  424. package/dist/events/emitter.js.map +0 -1
  425. package/dist/events/index.d.ts +0 -7
  426. package/dist/events/index.d.ts.map +0 -1
  427. package/dist/events/index.js +0 -11
  428. package/dist/events/index.js.map +0 -1
  429. package/dist/events/interop.d.ts +0 -30
  430. package/dist/events/interop.d.ts.map +0 -1
  431. package/dist/events/interop.js.map +0 -1
  432. package/dist/events/listeners.d.ts +0 -76
  433. package/dist/events/listeners.d.ts.map +0 -1
  434. package/dist/events/listeners.js +0 -7
  435. package/dist/events/listeners.js.map +0 -1
  436. package/dist/shared-tree-core/transactionStack.d.ts +0 -29
  437. package/dist/shared-tree-core/transactionStack.d.ts.map +0 -1
  438. package/dist/shared-tree-core/transactionStack.js +0 -41
  439. package/dist/shared-tree-core/transactionStack.js.map +0 -1
  440. package/dist/util/transactionResult.d.ts +0 -19
  441. package/dist/util/transactionResult.d.ts.map +0 -1
  442. package/dist/util/transactionResult.js +0 -23
  443. package/dist/util/transactionResult.js.map +0 -1
  444. package/lib/events/emitter.d.ts +0 -139
  445. package/lib/events/emitter.d.ts.map +0 -1
  446. package/lib/events/emitter.js +0 -160
  447. package/lib/events/emitter.js.map +0 -1
  448. package/lib/events/index.d.ts +0 -7
  449. package/lib/events/index.d.ts.map +0 -1
  450. package/lib/events/index.js.map +0 -1
  451. package/lib/events/interop.d.ts +0 -30
  452. package/lib/events/interop.d.ts.map +0 -1
  453. package/lib/events/interop.js.map +0 -1
  454. package/lib/events/listeners.d.ts +0 -76
  455. package/lib/events/listeners.d.ts.map +0 -1
  456. package/lib/events/listeners.js +0 -6
  457. package/lib/events/listeners.js.map +0 -1
  458. package/lib/shared-tree-core/transactionStack.d.ts +0 -29
  459. package/lib/shared-tree-core/transactionStack.d.ts.map +0 -1
  460. package/lib/shared-tree-core/transactionStack.js +0 -37
  461. package/lib/shared-tree-core/transactionStack.js.map +0 -1
  462. package/lib/util/transactionResult.d.ts +0 -19
  463. package/lib/util/transactionResult.d.ts.map +0 -1
  464. package/lib/util/transactionResult.js +0 -20
  465. package/lib/util/transactionResult.js.map +0 -1
  466. package/src/events/README.md +0 -3
  467. package/src/events/emitter.ts +0 -256
  468. package/src/events/index.ts +0 -19
  469. package/src/events/interop.ts +0 -38
  470. package/src/events/listeners.ts +0 -80
  471. package/src/shared-tree-core/transactionStack.ts +0 -45
  472. package/src/util/transactionResult.ts +0 -19
package/CHANGELOG.md CHANGED
@@ -1,5 +1,108 @@
1
1
  # @fluidframework/tree
2
2
 
3
+ ## 2.11.0
4
+
5
+ ### Minor Changes
6
+
7
+ - Revertible objects can now be cloned using `RevertibleAlpha.clone()` ([#23044](https://github.com/microsoft/FluidFramework/pull/23044)) [5abfa015af](https://github.com/microsoft/FluidFramework/commit/5abfa015aff9d639d82830f3ad828324d5680bd7)
8
+
9
+ The `DisposableRevertible` interface has been replaced with `RevertibleAlpha`. The new `RevertibleAlpha` interface extends `Revertible` and includes a `clone(branch: TreeBranch)` method to facilitate cloning a Revertible to a specified target branch. The source branch where the `RevertibleAlpha` was created must share revision logs with the target branch where the `RevertibleAlpha` is being cloned. If this condition is not met, the operation will throw an error.
10
+
11
+ - Providing unused properties in object literals for building empty ObjectNodes no longer compiles ([#23162](https://github.com/microsoft/FluidFramework/pull/23162)) [dc3c30019e](https://github.com/microsoft/FluidFramework/commit/dc3c30019ef869b27b9468bff59f10434d3c5c68)
12
+
13
+ ObjectNodes with no fields will now emit a compiler error if constructed from an object literal with fields.
14
+ This matches the behavior of non-empty ObjectNodes which already gave errors when unexpected properties were provided.
15
+
16
+ ```typescript
17
+ class A extends schemaFactory.object("A", {}) {}
18
+ const a = new A({ thisDoesNotExist: 5 }); // This now errors.
19
+ ```
20
+
21
+ - The events library has been moved from the tree package ([#23141](https://github.com/microsoft/FluidFramework/pull/23141)) [cae07b5c8c](https://github.com/microsoft/FluidFramework/commit/cae07b5c8c7904184b5fbf8c677f302da19cc697)
22
+
23
+ In previous releases, the `@fluidframework/tree` package contained an internal events library. The events-related types and interfaces have been moved to
24
+ `@fluidframework/core-interfaces`, while the implementation has been relocated to `@fluid-internal/client-utils`. There are
25
+ no changes to how the events library is used; the relocation simply organizes the library into more appropriate
26
+ packages. This change should have no impact on developers using the Fluid Framework.
27
+
28
+ ## 2.10.0
29
+
30
+ ### Minor Changes
31
+
32
+ - Fix typing bug in `adaptEnum` and `enumFromStrings` ([#23077](https://github.com/microsoft/FluidFramework/pull/23077)) [cfb68388cb](https://github.com/microsoft/FluidFramework/commit/cfb68388cb6b88a0ef670633b3afa46a82c99972)
33
+
34
+ When using the return value from [`adaptEnum`](https://fluidframework.com/docs/api/v2/tree#adaptenum-function) as a function, passing in a value who's type is a union no longer produced an incorrectly typed return value. This has been fixed.
35
+
36
+ Additionally [`enumFromStrings`](https://fluidframework.com/docs/api/v2/tree#enumfromstrings-function) has improved the typing of its schema, ensuring the returned object's members have sufficiently specific types.
37
+ Part of this improvement was fixing the `.schema` property to be a tuple over each of the schema where it was previously a tuple of a single combined schema due to a bug.
38
+
39
+ One side-effect of these fixes is that narrowing of the `value` field of a node typed from the `.schema` behaves slightly different, such that the node type is now a union instead of it being a single type with a `.value` that is a union.
40
+ This means that narrowing based on `.value` property narrows which node type you have, not just the value property.
41
+ This mainly matters when matching all cases like the switch statement below:
42
+
43
+ ```typescript
44
+ const Mode = enumFromStrings(schema, ["Fun", "Bonus"]);
45
+ type Mode = TreeNodeFromImplicitAllowedTypes<typeof Mode.schema>;
46
+ const node = new Mode.Bonus() as Mode;
47
+
48
+ switch (node.value) {
49
+ case "Fun": {
50
+ assert.fail();
51
+ }
52
+ case "Bonus": {
53
+ // This one runs
54
+ break;
55
+ }
56
+ default:
57
+ // Before this change, "node.value" was never here, now "node" is never.
58
+ unreachableCase(node);
59
+ }
60
+ ```
61
+
62
+ - SharedTree event listeners that implement `Listenable` now allow deregistration of event listeners via an `off()` function. ([#23046](https://github.com/microsoft/FluidFramework/pull/23046)) [c59225db03](https://github.com/microsoft/FluidFramework/commit/c59225db033a516ee20e459ae31567d97ce8776c)
63
+
64
+ The ability to deregister events via a callback returned by `on()` remains the same.
65
+ Both strategies will remain supported and consumers of SharedTree events may choose which method of deregistration they prefer in a given instance.
66
+
67
+ ```typescript
68
+ // The new behavior
69
+ function deregisterViaOff(view: TreeView<MySchema>): {
70
+ const listener = () => { /* ... */ };
71
+ view.events.on("commitApplied", listener); // Register
72
+ view.events.off("commitApplied", listener); // Deregister
73
+ }
74
+
75
+ // The existing behavior (still supported)
76
+ function deregisterViaCallback(view: TreeView<MySchema>): {
77
+ const off = view.events.on("commitApplied", () => { /* ... */ }); // Register
78
+ off(); // Deregister
79
+ }
80
+ ```
81
+
82
+ - Allow constructing recursive maps from objects ([#23070](https://github.com/microsoft/FluidFramework/pull/23070)) [0185a08c6f](https://github.com/microsoft/FluidFramework/commit/0185a08c6f8bf6e922a6467f11da049503c4d215)
83
+
84
+ Previously only non-recursive maps could be constructed from objects.
85
+ Now all maps nodes can constructed from objects:
86
+
87
+ ```typescript
88
+ class MapRecursive extends sf.mapRecursive("Map", [() => MapRecursive]) {}
89
+ {
90
+ type _check = ValidateRecursiveSchema<typeof MapRecursive>;
91
+ }
92
+ // New:
93
+ const fromObject = new MapRecursive({ x: new MapRecursive() });
94
+ // Existing:
95
+ const fromIterator = new MapRecursive([["x", new MapRecursive()]]);
96
+ const fromMap = new MapRecursive(new Map([["x", new MapRecursive()]]));
97
+ const fromNothing = new MapRecursive();
98
+ const fromUndefined = new MapRecursive(undefined);
99
+ ```
100
+
101
+ - Provide more comprehensive replacement to the `commitApplied` event ([#22977](https://github.com/microsoft/FluidFramework/pull/22977)) [e51c94da32](https://github.com/microsoft/FluidFramework/commit/e51c94da3248868de3c0c7fdce568cc425204155)
102
+
103
+ Adds a new `changed` event to the (currently alpha) `TreeBranchEvents` that replaces the `commitApplied` event on `TreeViewEvents`.
104
+ This new event is fired for both local and remote changes and maintains the existing functionality of `commitApplied` that is used for obtaining `Revertibles`.
105
+
3
106
  ## 2.5.0
4
107
 
5
108
  ### Minor Changes
@@ -65,6 +65,21 @@ export type ConciseTree<THandle = IFluidHandle> = Exclude<TreeLeafValue, IFluidH
65
65
  [key: string]: ConciseTree<THandle>;
66
66
  };
67
67
 
68
+ // @alpha
69
+ export function createIdentifierIndex<TSchema extends ImplicitFieldSchema>(view: TreeView<TSchema>): IdentifierIndex;
70
+
71
+ // @alpha
72
+ export function createSimpleTreeIndex<TFieldSchema extends ImplicitFieldSchema, TKey extends TreeIndexKey, TValue>(view: TreeView<TFieldSchema>, indexer: (schema: TreeNodeSchema) => string | undefined, getValue: (nodes: TreeIndexNodes<TreeNode>) => TValue, isKeyValid: (key: TreeIndexKey) => key is TKey): SimpleTreeIndex<TKey, TValue>;
73
+
74
+ // @alpha
75
+ export function createSimpleTreeIndex<TFieldSchema extends ImplicitFieldSchema, TKey extends TreeIndexKey, TValue, TSchema extends TreeNodeSchema>(view: TreeView<TFieldSchema>, indexer: (schema: TSchema) => string | undefined, getValue: (nodes: TreeIndexNodes<NodeFromSchema<TSchema>>) => TValue, isKeyValid: (key: TreeIndexKey) => key is TKey, indexableSchema: readonly TSchema[]): SimpleTreeIndex<TKey, TValue>;
76
+
77
+ // @alpha
78
+ export function createSimpleTreeIndex<TFieldSchema extends ImplicitFieldSchema, TKey extends TreeIndexKey, TValue>(view: TreeView<TFieldSchema>, indexer: Map<TreeNodeSchema, string>, getValue: (nodes: TreeIndexNodes<TreeNode>) => TValue, isKeyValid: (key: TreeIndexKey) => key is TKey): SimpleTreeIndex<TKey, TValue>;
79
+
80
+ // @alpha
81
+ export function createSimpleTreeIndex<TFieldSchema extends ImplicitFieldSchema, TKey extends TreeIndexKey, TValue, TSchema extends TreeNodeSchema>(view: TreeView<TFieldSchema>, indexer: Map<TreeNodeSchema, string>, getValue: (nodes: TreeIndexNodes<NodeFromSchema<TSchema>>) => TValue, isKeyValid: (key: TreeIndexKey) => key is TKey, indexableSchema: readonly TSchema[]): SimpleTreeIndex<TKey, TValue>;
82
+
68
83
  // @public @sealed
69
84
  interface DefaultProvider extends ErasedType<"@fluidframework/tree.FieldProvider"> {
70
85
  }
@@ -192,6 +207,9 @@ export interface ICodecOptions {
192
207
  readonly jsonValidator: JsonValidator;
193
208
  }
194
209
 
210
+ // @alpha
211
+ export type IdentifierIndex = SimpleTreeIndex<string, TreeNode>;
212
+
195
213
  // @public
196
214
  export type ImplicitAllowedTypes = AllowedTypes | TreeNodeSchema;
197
215
 
@@ -224,7 +242,7 @@ TSchema
224
242
  ] extends [ImplicitFieldSchema] ? InsertableTreeFieldFromImplicitField<TSchema> : [TSchema] extends [UnsafeUnknownSchema] ? InsertableContent | undefined : never;
225
243
 
226
244
  // @public
227
- type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = FlattenKeys<{
245
+ type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = Record<string, never> extends T ? Record<string, never> : FlattenKeys<{
228
246
  readonly [Property in keyof T]?: InsertableTreeFieldFromImplicitField<T[Property & string]>;
229
247
  } & {
230
248
  readonly [Property in keyof T as FieldHasDefault<T[Property & string]> extends false ? Property : never]: InsertableTreeFieldFromImplicitField<T[Property & string]>;
@@ -311,8 +329,7 @@ declare namespace InternalTypes {
311
329
  }
312
330
  export { InternalTypes }
313
331
 
314
- // @public
315
- export type IsListener<TListener> = TListener extends (...args: any[]) => void ? true : false;
332
+ export { IsListener }
316
333
 
317
334
  // @alpha
318
335
  export type IsUnion<T, T2 = T> = T extends unknown ? [T2] extends [T] ? false : true : "error";
@@ -415,16 +432,9 @@ export interface JsonValidator {
415
432
  // @public
416
433
  export type LazyItem<Item = unknown> = Item | (() => Item);
417
434
 
418
- // @public @sealed
419
- export interface Listenable<TListeners extends object> {
420
- off<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): void;
421
- on<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): Off;
422
- }
435
+ export { Listenable }
423
436
 
424
- // @public
425
- export type Listeners<T extends object> = {
426
- [P in (string | symbol) & keyof T as IsListener<T[P]> extends true ? P : never]: T[P];
427
- };
437
+ export { Listeners }
428
438
 
429
439
  // @public @sealed
430
440
  export interface MakeNominal {
@@ -479,8 +489,7 @@ type ObjectFromSchemaRecordUnsafe<T extends Unenforced<RestrictiveStringRecord<I
479
489
  -readonly [Property in keyof T]: TreeFieldFromImplicitFieldUnsafe<T[Property]>;
480
490
  };
481
491
 
482
- // @public
483
- export type Off = () => void;
492
+ export { Off }
484
493
 
485
494
  // @alpha
486
495
  export interface ParseOptions<TCustom> {
@@ -539,6 +548,14 @@ export interface Revertible {
539
548
  readonly status: RevertibleStatus;
540
549
  }
541
550
 
551
+ // @alpha @sealed
552
+ export interface RevertibleAlpha extends Revertible {
553
+ clone: (branch: TreeBranch) => RevertibleAlpha;
554
+ }
555
+
556
+ // @alpha @sealed
557
+ export type RevertibleAlphaFactory = (onRevertibleDisposed?: (revertible: RevertibleAlpha) => void) => RevertibleAlpha;
558
+
542
559
  // @public @sealed
543
560
  export type RevertibleFactory = (onRevertibleDisposed?: (revertible: Revertible) => void) => Revertible;
544
561
 
@@ -637,6 +654,9 @@ export type SharedTreeFormatVersion = typeof SharedTreeFormatVersion;
637
654
  // @alpha
638
655
  export type SharedTreeOptions = Partial<ICodecOptions> & Partial<SharedTreeFormatOptions> & ForestOptions;
639
656
 
657
+ // @alpha
658
+ export type SimpleTreeIndex<TKey extends TreeIndexKey, TValue> = TreeIndex<TKey, TValue>;
659
+
640
660
  // @alpha
641
661
  export function singletonSchema<TScope extends string, TName extends string | number>(factory: SchemaFactory<TScope, TName>, name: TName): TreeNodeSchemaClass<ScopedSchemaName<TScope, TName>, NodeKind.Object, TreeNode & {
642
662
  readonly value: TName;
@@ -723,8 +743,8 @@ export interface TreeBranch extends IDisposable {
723
743
 
724
744
  // @alpha @sealed
725
745
  export interface TreeBranchEvents {
726
- changed(data: CommitMetadata, getRevertible?: RevertibleFactory): void;
727
- commitApplied(data: CommitMetadata, getRevertible?: RevertibleFactory): void;
746
+ changed(data: CommitMetadata, getRevertible?: RevertibleAlphaFactory): void;
747
+ commitApplied(data: CommitMetadata, getRevertible?: RevertibleAlphaFactory): void;
728
748
  schemaChanged(): void;
729
749
  }
730
750
 
@@ -756,6 +776,17 @@ export type TreeFieldFromImplicitField<TSchema extends ImplicitFieldSchema = Fie
756
776
  // @public
757
777
  type TreeFieldFromImplicitFieldUnsafe<TSchema extends Unenforced<ImplicitFieldSchema>> = TSchema extends FieldSchemaUnsafe<infer Kind, infer Types> ? ApplyKind<TreeNodeFromImplicitAllowedTypesUnsafe<Types>, Kind> : TSchema extends ImplicitAllowedTypes ? TreeNodeFromImplicitAllowedTypesUnsafe<TSchema> : unknown;
758
778
 
779
+ // @alpha
780
+ export interface TreeIndex<TKey extends TreeIndexKey, TValue> extends ReadonlyMap<TKey, TValue> {
781
+ dispose(): void;
782
+ }
783
+
784
+ // @alpha
785
+ export type TreeIndexKey = number | string | boolean | IFluidHandle | null;
786
+
787
+ // @alpha
788
+ export type TreeIndexNodes<TNode> = readonly [first: TNode, ...rest: TNode[]];
789
+
759
790
  // @public
760
791
  export type TreeLeafValue = number | string | boolean | IFluidHandle | null;
761
792
 
@@ -110,7 +110,7 @@ type _InlineTrick = 0;
110
110
  export type Input<T extends never> = T;
111
111
 
112
112
  // @public
113
- type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = FlattenKeys<{
113
+ type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = Record<string, never> extends T ? Record<string, never> : FlattenKeys<{
114
114
  readonly [Property in keyof T]?: InsertableTreeFieldFromImplicitField<T[Property & string]>;
115
115
  } & {
116
116
  readonly [Property in keyof T as FieldHasDefault<T[Property & string]> extends false ? Property : never]: InsertableTreeFieldFromImplicitField<T[Property & string]>;
@@ -197,8 +197,7 @@ declare namespace InternalTypes {
197
197
  }
198
198
  export { InternalTypes }
199
199
 
200
- // @public
201
- export type IsListener<TListener> = TListener extends (...args: any[]) => void ? true : false;
200
+ export { IsListener }
202
201
 
203
202
  // @public @sealed
204
203
  export class IterableTreeArrayContent<T> implements Iterable<T> {
@@ -223,16 +222,9 @@ export interface ITreeViewConfiguration<TSchema extends ImplicitFieldSchema = Im
223
222
  // @public
224
223
  export type LazyItem<Item = unknown> = Item | (() => Item);
225
224
 
226
- // @public @sealed
227
- export interface Listenable<TListeners extends object> {
228
- off<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): void;
229
- on<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): Off;
230
- }
225
+ export { Listenable }
231
226
 
232
- // @public
233
- export type Listeners<T extends object> = {
234
- [P in (string | symbol) & keyof T as IsListener<T[P]> extends true ? P : never]: T[P];
235
- };
227
+ export { Listeners }
236
228
 
237
229
  // @public @sealed
238
230
  export interface MakeNominal {
@@ -284,8 +276,7 @@ type ObjectFromSchemaRecordUnsafe<T extends Unenforced<RestrictiveStringRecord<I
284
276
  -readonly [Property in keyof T]: TreeFieldFromImplicitFieldUnsafe<T[Property]>;
285
277
  };
286
278
 
287
- // @public
288
- export type Off = () => void;
279
+ export { Off }
289
280
 
290
281
  // @public @sealed
291
282
  export interface ReadonlyArrayNode<out T = TreeNode | TreeLeafValue> extends ReadonlyArray<T>, Awaited<TreeNode & WithType<string, NodeKind.Array>> {
@@ -110,7 +110,7 @@ type _InlineTrick = 0;
110
110
  export type Input<T extends never> = T;
111
111
 
112
112
  // @public
113
- type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = FlattenKeys<{
113
+ type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = Record<string, never> extends T ? Record<string, never> : FlattenKeys<{
114
114
  readonly [Property in keyof T]?: InsertableTreeFieldFromImplicitField<T[Property & string]>;
115
115
  } & {
116
116
  readonly [Property in keyof T as FieldHasDefault<T[Property & string]> extends false ? Property : never]: InsertableTreeFieldFromImplicitField<T[Property & string]>;
@@ -197,8 +197,7 @@ declare namespace InternalTypes {
197
197
  }
198
198
  export { InternalTypes }
199
199
 
200
- // @public
201
- export type IsListener<TListener> = TListener extends (...args: any[]) => void ? true : false;
200
+ export { IsListener }
202
201
 
203
202
  // @public @sealed
204
203
  export class IterableTreeArrayContent<T> implements Iterable<T> {
@@ -223,16 +222,9 @@ export interface ITreeViewConfiguration<TSchema extends ImplicitFieldSchema = Im
223
222
  // @public
224
223
  export type LazyItem<Item = unknown> = Item | (() => Item);
225
224
 
226
- // @public @sealed
227
- export interface Listenable<TListeners extends object> {
228
- off<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): void;
229
- on<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): Off;
230
- }
225
+ export { Listenable }
231
226
 
232
- // @public
233
- export type Listeners<T extends object> = {
234
- [P in (string | symbol) & keyof T as IsListener<T[P]> extends true ? P : never]: T[P];
235
- };
227
+ export { Listeners }
236
228
 
237
229
  // @public @sealed
238
230
  export interface MakeNominal {
@@ -279,8 +271,7 @@ type ObjectFromSchemaRecordUnsafe<T extends Unenforced<RestrictiveStringRecord<I
279
271
  -readonly [Property in keyof T]: TreeFieldFromImplicitFieldUnsafe<T[Property]>;
280
272
  };
281
273
 
282
- // @public
283
- export type Off = () => void;
274
+ export { Off }
284
275
 
285
276
  // @public @sealed
286
277
  export interface ReadonlyArrayNode<out T = TreeNode | TreeLeafValue> extends ReadonlyArray<T>, Awaited<TreeNode & WithType<string, NodeKind.Array>> {
@@ -110,7 +110,7 @@ type _InlineTrick = 0;
110
110
  export type Input<T extends never> = T;
111
111
 
112
112
  // @public
113
- type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = FlattenKeys<{
113
+ type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = Record<string, never> extends T ? Record<string, never> : FlattenKeys<{
114
114
  readonly [Property in keyof T]?: InsertableTreeFieldFromImplicitField<T[Property & string]>;
115
115
  } & {
116
116
  readonly [Property in keyof T as FieldHasDefault<T[Property & string]> extends false ? Property : never]: InsertableTreeFieldFromImplicitField<T[Property & string]>;
@@ -197,8 +197,7 @@ declare namespace InternalTypes {
197
197
  }
198
198
  export { InternalTypes }
199
199
 
200
- // @public
201
- export type IsListener<TListener> = TListener extends (...args: any[]) => void ? true : false;
200
+ export { IsListener }
202
201
 
203
202
  // @public @sealed
204
203
  export class IterableTreeArrayContent<T> implements Iterable<T> {
@@ -223,16 +222,9 @@ export interface ITreeViewConfiguration<TSchema extends ImplicitFieldSchema = Im
223
222
  // @public
224
223
  export type LazyItem<Item = unknown> = Item | (() => Item);
225
224
 
226
- // @public @sealed
227
- export interface Listenable<TListeners extends object> {
228
- off<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): void;
229
- on<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): Off;
230
- }
225
+ export { Listenable }
231
226
 
232
- // @public
233
- export type Listeners<T extends object> = {
234
- [P in (string | symbol) & keyof T as IsListener<T[P]> extends true ? P : never]: T[P];
235
- };
227
+ export { Listeners }
236
228
 
237
229
  // @public @sealed
238
230
  export interface MakeNominal {
@@ -279,8 +271,7 @@ type ObjectFromSchemaRecordUnsafe<T extends Unenforced<RestrictiveStringRecord<I
279
271
  -readonly [Property in keyof T]: TreeFieldFromImplicitFieldUnsafe<T[Property]>;
280
272
  };
281
273
 
282
- // @public
283
- export type Off = () => void;
274
+ export { Off }
284
275
 
285
276
  // @public @sealed
286
277
  export interface ReadonlyArrayNode<out T = TreeNode | TreeLeafValue> extends ReadonlyArray<T>, Awaited<TreeNode & WithType<string, NodeKind.Array>> {
@@ -110,7 +110,7 @@ type _InlineTrick = 0;
110
110
  export type Input<T extends never> = T;
111
111
 
112
112
  // @public
113
- type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = FlattenKeys<{
113
+ type InsertableObjectFromSchemaRecord<T extends RestrictiveStringRecord<ImplicitFieldSchema>> = Record<string, never> extends T ? Record<string, never> : FlattenKeys<{
114
114
  readonly [Property in keyof T]?: InsertableTreeFieldFromImplicitField<T[Property & string]>;
115
115
  } & {
116
116
  readonly [Property in keyof T as FieldHasDefault<T[Property & string]> extends false ? Property : never]: InsertableTreeFieldFromImplicitField<T[Property & string]>;
@@ -197,8 +197,7 @@ declare namespace InternalTypes {
197
197
  }
198
198
  export { InternalTypes }
199
199
 
200
- // @public
201
- export type IsListener<TListener> = TListener extends (...args: any[]) => void ? true : false;
200
+ export { IsListener }
202
201
 
203
202
  // @public @sealed
204
203
  export class IterableTreeArrayContent<T> implements Iterable<T> {
@@ -223,16 +222,9 @@ export interface ITreeViewConfiguration<TSchema extends ImplicitFieldSchema = Im
223
222
  // @public
224
223
  export type LazyItem<Item = unknown> = Item | (() => Item);
225
224
 
226
- // @public @sealed
227
- export interface Listenable<TListeners extends object> {
228
- off<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): void;
229
- on<K extends keyof Listeners<TListeners>>(eventName: K, listener: TListeners[K]): Off;
230
- }
225
+ export { Listenable }
231
226
 
232
- // @public
233
- export type Listeners<T extends object> = {
234
- [P in (string | symbol) & keyof T as IsListener<T[P]> extends true ? P : never]: T[P];
235
- };
227
+ export { Listeners }
236
228
 
237
229
  // @public @sealed
238
230
  export interface MakeNominal {
@@ -279,8 +271,7 @@ type ObjectFromSchemaRecordUnsafe<T extends Unenforced<RestrictiveStringRecord<I
279
271
  -readonly [Property in keyof T]: TreeFieldFromImplicitFieldUnsafe<T[Property]>;
280
272
  };
281
273
 
282
- // @public
283
- export type Off = () => void;
274
+ export { Off }
284
275
 
285
276
  // @public @sealed
286
277
  export interface ReadonlyArrayNode<out T = TreeNode | TreeLeafValue> extends ReadonlyArray<T>, Awaited<TreeNode & WithType<string, NodeKind.Array>> {
package/dist/alpha.d.ts CHANGED
@@ -104,6 +104,7 @@ export {
104
104
  ForestOptions,
105
105
  ForestType,
106
106
  ICodecOptions,
107
+ IdentifierIndex,
107
108
  Insertable,
108
109
  InsertableContent,
109
110
  InsertableField,
@@ -128,15 +129,21 @@ export {
128
129
  PopUnion,
129
130
  ReadSchema,
130
131
  ReadableField,
132
+ RevertibleAlpha,
133
+ RevertibleAlphaFactory,
131
134
  SchemaValidationFunction,
132
135
  SharedTreeFormatOptions,
133
136
  SharedTreeFormatVersion,
134
137
  SharedTreeOptions,
138
+ SimpleTreeIndex,
135
139
  TreeAlpha,
136
140
  TreeBranch,
137
141
  TreeBranchEvents,
138
142
  TreeBranchFork,
139
143
  TreeCompressionStrategy,
144
+ TreeIndex,
145
+ TreeIndexKey,
146
+ TreeIndexNodes,
140
147
  TreeViewAlpha,
141
148
  UnionToTuple,
142
149
  UnsafeUnknownSchema,
@@ -146,6 +153,8 @@ export {
146
153
  adaptEnum,
147
154
  asTreeViewAlpha,
148
155
  comparePersistedSchema,
156
+ createIdentifierIndex,
157
+ createSimpleTreeIndex,
149
158
  enumFromStrings,
150
159
  extractPersistedSchema,
151
160
  getBranch,
@@ -2,9 +2,9 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- import type { Listenable } from "../../events/index.js";
5
+ import type { Listenable } from "@fluidframework/core-interfaces/internal";
6
6
  import type { FieldKey, TreeStoredSchemaSubscription } from "../schema-stored/index.js";
7
- import { type Anchor, type AnchorSet, type DetachedField, type ITreeCursor, type ITreeCursorSynchronous, type UpPath } from "../tree/index.js";
7
+ import { type Anchor, type AnchorSet, type AnnouncedVisitor, type DetachedField, type ITreeCursor, type ITreeCursorSynchronous, type UpPath } from "../tree/index.js";
8
8
  import type { IEditableForest } from "./editableForest.js";
9
9
  /**
10
10
  * APIs for forest designed so the implementation can be copy on write,
@@ -101,6 +101,14 @@ export interface IForestSubscription {
101
101
  * This means no nodes under any detached field, not just the special document root one.
102
102
  */
103
103
  readonly isEmpty: boolean;
104
+ /**
105
+ * Obtains and registers an {@link AnnouncedVisitor} that responds to changes on the forest.
106
+ */
107
+ registerAnnouncedVisitor(visitor: () => AnnouncedVisitor): void;
108
+ /**
109
+ * Deregister the given visitor so that it stops responding to updates
110
+ */
111
+ deregisterAnnouncedVisitor(visitor: () => AnnouncedVisitor): void;
104
112
  }
105
113
  /**
106
114
  * @param field - defaults to {@link rootField}.
@@ -1 +1 @@
1
- {"version":3,"file":"forest.d.ts","sourceRoot":"","sources":["../../../src/core/forest/forest.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,KAAK,EAAE,QAAQ,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AACxF,OAAO,EACN,KAAK,MAAM,EACX,KAAK,SAAS,EACd,KAAK,aAAa,EAClB,KAAK,WAAW,EAChB,KAAK,sBAAsB,EAC3B,KAAK,MAAM,EAGX,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D;;;;;;;GAOG;AAEH;;;;GAIG;AACH,MAAM,WAAW,YAAY;IAC5B;;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,EAAE,SAAS;QACjB,QAAQ,EAAE,IAAA,6BAAkB,EAAC,KAAK,CAAC;KACnC,CAAC;AACH,CAAC;AALD,gCAKC;AAED;;;GAGG;AACH,SAAgB,mBAAmB,CAClC,MAA2B,EAC3B,YAAqC,EACrC,QAAuB,oBAAS;IAEhC,MAAM,MAAM,GAAG,MAAM,CAAC,oBAAoB,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,YAAY,CAAC,CAAC;IAC5E,IAAA,iBAAM,EACL,MAAM,oCAA4B,EAClC,KAAK,CAAC,qDAAqD,CAC3D,CAAC;AACH,CAAC;AAVD,kDAUC;AAkED;GACG;AACH,IAAY,4BAaX;AAbD,WAAY,4BAA4B;IACvC;;OAEG;IACH,qFAAO,CAAA;IACP;;OAEG;IACH,qFAAO,CAAA;IACP;;OAEG;IACH,iFAAK,CAAA;AACN,CAAC,EAbW,4BAA4B,4CAA5B,4BAA4B,QAavC;AAED;GACG;AACH,IAAkB,oBAejB;AAfD,WAAkB,oBAAoB;IACrC;;OAEG;IACH,wEAAa,CAAA;IAEb;;OAEG;IACH,qEAAW,CAAA;IAEX;;OAEG;IACH,2DAAM,CAAA;AACP,CAAC,EAfiB,oBAAoB,oCAApB,oBAAoB,QAerC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { assert } from \"@fluidframework/core-utils/internal\";\n\nimport type { Listenable } from \"../../events/index.js\";\nimport type { FieldKey, TreeStoredSchemaSubscription } from \"../schema-stored/index.js\";\nimport {\n\ttype Anchor,\n\ttype AnchorSet,\n\ttype DetachedField,\n\ttype ITreeCursor,\n\ttype ITreeCursorSynchronous,\n\ttype UpPath,\n\tdetachedFieldAsKey,\n\trootField,\n} from \"../tree/index.js\";\n\nimport type { IEditableForest } from \"./editableForest.js\";\n\n/**\n * APIs for forest designed so the implementation can be copy on write,\n * or mutate in place, and we can ensure no references are dangling into the forest to allow this.\n *\n * This results in rather manual memory management,\n * but makes it practical to provide highly optimized implementations,\n * for example WASM powered binary formats that can track reference counts and only copy when needed.\n */\n\n/**\n * Events for {@link IForestSubscription}.\n *\n * TODO: consider having before and after events per subtree instead while applying anchor (and this just shows what happens at the root).\n */\nexport interface ForestEvents {\n\t/**\n\t * A new root field was just created in this forest.\n\t */\n\tafterRootFieldCreated(key: FieldKey): void;\n\n\t/**\n\t * The forest is about to be changed.\n\t * Emitted before each change in a batch of changes.\n\t * @remarks\n\t * This is the last chance for users of the forest to remove cursors from the forest before the edit.\n\t * Removing these cursors is important since they are not allowed to live across edits and\n\t * not clearing them can lead to corruption of in memory structures.\n\t */\n\tbeforeChange(): void;\n}\n\n/**\n * Invalidates whenever the tree content changes.\n * For now (might change later) downloading new parts of the forest counts as a change.\n * Not invalidated when schema changes.\n *\n * When invalidating, all outstanding cursors must be freed or cleared.\n */\nexport interface IForestSubscription {\n\t/**\n\t * Events for this forest.\n\t */\n\treadonly events: Listenable<ForestEvents>;\n\n\t/**\n\t * Set of anchors this forest is tracking.\n\t *\n\t * To keep these anchors usable, this AnchorSet must be updated / rebased for any changes made to the forest.\n\t * It is the responsibility of the caller of the forest-editing methods to do this, not the forest itself.\n\t * The caller performs these updates because it has more semantic knowledge about the edits, which can be needed to\n\t * update the anchors in a semantically optimal way.\n\t */\n\treadonly anchors: AnchorSet;\n\n\t/**\n\t * Create an independent copy of this forest, that uses the provided schema and anchors.\n\t *\n\t * The new copy will not invalidate observers (dependents) of the old one.\n\t */\n\tclone(schema: TreeStoredSchemaSubscription, anchors: AnchorSet): IEditableForest;\n\n\t/**\n\t * Allocates a cursor in the \"cleared\" state.\n\t * @param source - optional string identifying the source of the cursor for debugging purposes when cursors are not properly cleaned up.\n\t */\n\tallocateCursor(source?: string): ITreeSubscriptionCursor;\n\n\t/**\n\t * Frees an Anchor, stopping tracking its position across edits.\n\t */\n\tforgetAnchor(anchor: Anchor): void;\n\n\t/**\n\t * It is an error not to free `cursorToMove` before the next edit.\n\t * Must provide a `cursorToMove` from this subscription (acquired via `allocateCursor`).\n\t */\n\ttryMoveCursorToNode(\n\t\tdestination: Anchor,\n\t\tcursorToMove: ITreeSubscriptionCursor,\n\t): TreeNavigationResult;\n\n\t/**\n\t * It is an error not to free `cursorToMove` before the next edit.\n\t * Must provide a `cursorToMove` from this subscription (acquired via `allocateCursor`).\n\t */\n\ttryMoveCursorToField(\n\t\tdestination: FieldAnchor,\n\t\tcursorToMove: ITreeSubscriptionCursor,\n\t): TreeNavigationResult;\n\n\t/**\n\t * Set `cursorToMove` to location described by path.\n\t * This is NOT a relative move: current position is discarded.\n\t * Path must point to existing node.\n\t */\n\tmoveCursorToPath(destination: UpPath, cursorToMove: ITreeSubscriptionCursor): void;\n\n\t/**\n\t * The cursor is moved to a special dummy node above the detached fields.\n\t * This dummy node can be used to read the detached fields,\n\t * but other operations (such as inspecting the dummy node's type or path) should not be relied upon.\n\t * While this method does not return an {@link ITreeSubscriptionCursor}, similar restrictions apply to its use:\n\t * the returned cursor must not used after any edits are made to the forest.\n\t */\n\tgetCursorAboveDetachedFields(): ITreeCursorSynchronous;\n\n\t/**\n\t * True if there are no nodes in the forest at all.\n\t *\n\t * @remarks\n\t * This means no nodes under any detached field, not just the special document root one.\n\t */\n\treadonly isEmpty: boolean;\n}\n\n/**\n * @param field - defaults to {@link rootField}.\n * @returns anchor to `field`.\n */\nexport function rootAnchor(field: DetachedField = rootField): FieldAnchor {\n\treturn {\n\t\tparent: undefined,\n\t\tfieldKey: detachedFieldAsKey(field),\n\t};\n}\n\n/**\n * @param field - defaults to {@link rootField}.\n * @returns anchor to `field`.\n */\nexport function moveToDetachedField(\n\tforest: IForestSubscription,\n\tcursorToMove: ITreeSubscriptionCursor,\n\tfield: DetachedField = rootField,\n): void {\n\tconst result = forest.tryMoveCursorToField(rootAnchor(field), cursorToMove);\n\tassert(\n\t\tresult === TreeNavigationResult.Ok,\n\t\t0x42d /* Navigation to detached fields should never fail */,\n\t);\n}\n\n/**\n * Anchor to a field.\n * This is structurally based on the parent, so it will move only as the parent moves.\n */\nexport interface FieldAnchor {\n\t/**\n\t * Node above this field.\n\t * If `undefined`, field is a detached field.\n\t */\n\tparent: Anchor | undefined;\n\tfieldKey: FieldKey;\n}\n\n/**\n * ITreeCursor supporting IForestSubscription and its changes over time.\n */\nexport interface ITreeSubscriptionCursor extends ITreeCursor {\n\t/**\n\t * @param source - optional string identifying the source of the cursor for debugging purposes when cursors are not properly cleaned up.\n\t * @returns an independent copy of this cursor at the same location in the tree.\n\t */\n\tfork(source?: string): ITreeSubscriptionCursor;\n\n\t/**\n\t * Release any resources this cursor is holding onto.\n\t * After doing this, further use of this object other than reading `state` is forbidden (undefined behavior).\n\t */\n\tfree(): void;\n\n\t/**\n\t * Release any resources this cursor is holding onto.\n\t * After doing this, further use of this object other than reading `state` or passing to `tryGet`\n\t * or calling `free` is forbidden (undefined behavior).\n\t */\n\tclear(): void;\n\n\t/**\n\t * Construct an `Anchor` which the IForestSubscription will keep rebased to `current`.\n\t * Note that maintaining an Anchor has cost: free them to stop incurring that cost.\n\t *\n\t * Only valid when `mode` is `Nodes`.\n\t */\n\tbuildAnchor(): Anchor;\n\n\t/**\n\t * Construct a `FieldAnchor` which the IForestSubscription will keep rebased to `current`.\n\t * Note that maintaining an Anchor has cost: free them to stop incurring that cost.\n\t *\n\t * Only valid when `mode` is `Fields`.\n\t */\n\tbuildFieldAnchor(): FieldAnchor;\n\n\t/**\n\t * Current state.\n\t */\n\treadonly state: ITreeSubscriptionCursorState;\n\n\t/**\n\t * @returns location within parent field or range.\n\t */\n\t// TODO: maybe support this.\n\t// getParentInfo(id: NodeId): TreeLocation;\n}\n\n/**\n */\nexport enum ITreeSubscriptionCursorState {\n\t/**\n\t * On the current revision of the forest.\n\t */\n\tCurrent,\n\t/**\n\t * Empty, but can be reused.\n\t */\n\tCleared,\n\t/**\n\t * Freed and must not be used.\n\t */\n\tFreed,\n}\n\n/**\n */\nexport const enum TreeNavigationResult {\n\t/**\n\t * Attempt to navigate cursor to a key or index that is outside the client's view.\n\t */\n\tNotFound = -1,\n\n\t/**\n\t * Attempt to navigate cursor to a portion of the tree that has not yet been loaded.\n\t */\n\tPending = 0,\n\n\t/**\n\t * ITreeReader successfully navigated to the desired node.\n\t */\n\tOk = 1,\n}\n\n/**\n * TreeNavigationResult, but never \"Pending\".\n * Can be used when data is never pending.\n */\nexport type SynchronousNavigationResult =\n\t| TreeNavigationResult.Ok\n\t| TreeNavigationResult.NotFound;\n"]}
1
+ {"version":3,"file":"forest.js","sourceRoot":"","sources":["../../../src/core/forest/forest.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,kEAA6D;AAI7D,+CAU0B;AAiI1B;;;GAGG;AACH,SAAgB,UAAU,CAAC,QAAuB,oBAAS;IAC1D,OAAO;QACN,MAAM,EAAE,SAAS;QACjB,QAAQ,EAAE,IAAA,6BAAkB,EAAC,KAAK,CAAC;KACnC,CAAC;AACH,CAAC;AALD,gCAKC;AAED;;;GAGG;AACH,SAAgB,mBAAmB,CAClC,MAA2B,EAC3B,YAAqC,EACrC,QAAuB,oBAAS;IAEhC,MAAM,MAAM,GAAG,MAAM,CAAC,oBAAoB,CAAC,UAAU,CAAC,KAAK,CAAC,EAAE,YAAY,CAAC,CAAC;IAC5E,IAAA,iBAAM,EACL,MAAM,oCAA4B,EAClC,KAAK,CAAC,qDAAqD,CAC3D,CAAC;AACH,CAAC;AAVD,kDAUC;AAkED;GACG;AACH,IAAY,4BAaX;AAbD,WAAY,4BAA4B;IACvC;;OAEG;IACH,qFAAO,CAAA;IACP;;OAEG;IACH,qFAAO,CAAA;IACP;;OAEG;IACH,iFAAK,CAAA;AACN,CAAC,EAbW,4BAA4B,4CAA5B,4BAA4B,QAavC;AAED;GACG;AACH,IAAkB,oBAejB;AAfD,WAAkB,oBAAoB;IACrC;;OAEG;IACH,wEAAa,CAAA;IAEb;;OAEG;IACH,qEAAW,CAAA;IAEX;;OAEG;IACH,2DAAM,CAAA;AACP,CAAC,EAfiB,oBAAoB,oCAApB,oBAAoB,QAerC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { assert } from \"@fluidframework/core-utils/internal\";\n\nimport type { Listenable } from \"@fluidframework/core-interfaces/internal\";\nimport type { FieldKey, TreeStoredSchemaSubscription } from \"../schema-stored/index.js\";\nimport {\n\ttype Anchor,\n\ttype AnchorSet,\n\ttype AnnouncedVisitor,\n\ttype DetachedField,\n\ttype ITreeCursor,\n\ttype ITreeCursorSynchronous,\n\ttype UpPath,\n\tdetachedFieldAsKey,\n\trootField,\n} from \"../tree/index.js\";\n\nimport type { IEditableForest } from \"./editableForest.js\";\n\n/**\n * APIs for forest designed so the implementation can be copy on write,\n * or mutate in place, and we can ensure no references are dangling into the forest to allow this.\n *\n * This results in rather manual memory management,\n * but makes it practical to provide highly optimized implementations,\n * for example WASM powered binary formats that can track reference counts and only copy when needed.\n */\n\n/**\n * Events for {@link IForestSubscription}.\n *\n * TODO: consider having before and after events per subtree instead while applying anchor (and this just shows what happens at the root).\n */\nexport interface ForestEvents {\n\t/**\n\t * A new root field was just created in this forest.\n\t */\n\tafterRootFieldCreated(key: FieldKey): void;\n\n\t/**\n\t * The forest is about to be changed.\n\t * Emitted before each change in a batch of changes.\n\t * @remarks\n\t * This is the last chance for users of the forest to remove cursors from the forest before the edit.\n\t * Removing these cursors is important since they are not allowed to live across edits and\n\t * not clearing them can lead to corruption of in memory structures.\n\t */\n\tbeforeChange(): void;\n}\n\n/**\n * Invalidates whenever the tree content changes.\n * For now (might change later) downloading new parts of the forest counts as a change.\n * Not invalidated when schema changes.\n *\n * When invalidating, all outstanding cursors must be freed or cleared.\n */\nexport interface IForestSubscription {\n\t/**\n\t * Events for this forest.\n\t */\n\treadonly events: Listenable<ForestEvents>;\n\n\t/**\n\t * Set of anchors this forest is tracking.\n\t *\n\t * To keep these anchors usable, this AnchorSet must be updated / rebased for any changes made to the forest.\n\t * It is the responsibility of the caller of the forest-editing methods to do this, not the forest itself.\n\t * The caller performs these updates because it has more semantic knowledge about the edits, which can be needed to\n\t * update the anchors in a semantically optimal way.\n\t */\n\treadonly anchors: AnchorSet;\n\n\t/**\n\t * Create an independent copy of this forest, that uses the provided schema and anchors.\n\t *\n\t * The new copy will not invalidate observers (dependents) of the old one.\n\t */\n\tclone(schema: TreeStoredSchemaSubscription, anchors: AnchorSet): IEditableForest;\n\n\t/**\n\t * Allocates a cursor in the \"cleared\" state.\n\t * @param source - optional string identifying the source of the cursor for debugging purposes when cursors are not properly cleaned up.\n\t */\n\tallocateCursor(source?: string): ITreeSubscriptionCursor;\n\n\t/**\n\t * Frees an Anchor, stopping tracking its position across edits.\n\t */\n\tforgetAnchor(anchor: Anchor): void;\n\n\t/**\n\t * It is an error not to free `cursorToMove` before the next edit.\n\t * Must provide a `cursorToMove` from this subscription (acquired via `allocateCursor`).\n\t */\n\ttryMoveCursorToNode(\n\t\tdestination: Anchor,\n\t\tcursorToMove: ITreeSubscriptionCursor,\n\t): TreeNavigationResult;\n\n\t/**\n\t * It is an error not to free `cursorToMove` before the next edit.\n\t * Must provide a `cursorToMove` from this subscription (acquired via `allocateCursor`).\n\t */\n\ttryMoveCursorToField(\n\t\tdestination: FieldAnchor,\n\t\tcursorToMove: ITreeSubscriptionCursor,\n\t): TreeNavigationResult;\n\n\t/**\n\t * Set `cursorToMove` to location described by path.\n\t * This is NOT a relative move: current position is discarded.\n\t * Path must point to existing node.\n\t */\n\tmoveCursorToPath(destination: UpPath, cursorToMove: ITreeSubscriptionCursor): void;\n\n\t/**\n\t * The cursor is moved to a special dummy node above the detached fields.\n\t * This dummy node can be used to read the detached fields,\n\t * but other operations (such as inspecting the dummy node's type or path) should not be relied upon.\n\t * While this method does not return an {@link ITreeSubscriptionCursor}, similar restrictions apply to its use:\n\t * the returned cursor must not used after any edits are made to the forest.\n\t */\n\tgetCursorAboveDetachedFields(): ITreeCursorSynchronous;\n\n\t/**\n\t * True if there are no nodes in the forest at all.\n\t *\n\t * @remarks\n\t * This means no nodes under any detached field, not just the special document root one.\n\t */\n\treadonly isEmpty: boolean;\n\n\t/**\n\t * Obtains and registers an {@link AnnouncedVisitor} that responds to changes on the forest.\n\t */\n\tregisterAnnouncedVisitor(visitor: () => AnnouncedVisitor): void;\n\n\t/**\n\t * Deregister the given visitor so that it stops responding to updates\n\t */\n\tderegisterAnnouncedVisitor(visitor: () => AnnouncedVisitor): void;\n}\n\n/**\n * @param field - defaults to {@link rootField}.\n * @returns anchor to `field`.\n */\nexport function rootAnchor(field: DetachedField = rootField): FieldAnchor {\n\treturn {\n\t\tparent: undefined,\n\t\tfieldKey: detachedFieldAsKey(field),\n\t};\n}\n\n/**\n * @param field - defaults to {@link rootField}.\n * @returns anchor to `field`.\n */\nexport function moveToDetachedField(\n\tforest: IForestSubscription,\n\tcursorToMove: ITreeSubscriptionCursor,\n\tfield: DetachedField = rootField,\n): void {\n\tconst result = forest.tryMoveCursorToField(rootAnchor(field), cursorToMove);\n\tassert(\n\t\tresult === TreeNavigationResult.Ok,\n\t\t0x42d /* Navigation to detached fields should never fail */,\n\t);\n}\n\n/**\n * Anchor to a field.\n * This is structurally based on the parent, so it will move only as the parent moves.\n */\nexport interface FieldAnchor {\n\t/**\n\t * Node above this field.\n\t * If `undefined`, field is a detached field.\n\t */\n\tparent: Anchor | undefined;\n\tfieldKey: FieldKey;\n}\n\n/**\n * ITreeCursor supporting IForestSubscription and its changes over time.\n */\nexport interface ITreeSubscriptionCursor extends ITreeCursor {\n\t/**\n\t * @param source - optional string identifying the source of the cursor for debugging purposes when cursors are not properly cleaned up.\n\t * @returns an independent copy of this cursor at the same location in the tree.\n\t */\n\tfork(source?: string): ITreeSubscriptionCursor;\n\n\t/**\n\t * Release any resources this cursor is holding onto.\n\t * After doing this, further use of this object other than reading `state` is forbidden (undefined behavior).\n\t */\n\tfree(): void;\n\n\t/**\n\t * Release any resources this cursor is holding onto.\n\t * After doing this, further use of this object other than reading `state` or passing to `tryGet`\n\t * or calling `free` is forbidden (undefined behavior).\n\t */\n\tclear(): void;\n\n\t/**\n\t * Construct an `Anchor` which the IForestSubscription will keep rebased to `current`.\n\t * Note that maintaining an Anchor has cost: free them to stop incurring that cost.\n\t *\n\t * Only valid when `mode` is `Nodes`.\n\t */\n\tbuildAnchor(): Anchor;\n\n\t/**\n\t * Construct a `FieldAnchor` which the IForestSubscription will keep rebased to `current`.\n\t * Note that maintaining an Anchor has cost: free them to stop incurring that cost.\n\t *\n\t * Only valid when `mode` is `Fields`.\n\t */\n\tbuildFieldAnchor(): FieldAnchor;\n\n\t/**\n\t * Current state.\n\t */\n\treadonly state: ITreeSubscriptionCursorState;\n\n\t/**\n\t * @returns location within parent field or range.\n\t */\n\t// TODO: maybe support this.\n\t// getParentInfo(id: NodeId): TreeLocation;\n}\n\n/**\n */\nexport enum ITreeSubscriptionCursorState {\n\t/**\n\t * On the current revision of the forest.\n\t */\n\tCurrent,\n\t/**\n\t * Empty, but can be reused.\n\t */\n\tCleared,\n\t/**\n\t * Freed and must not be used.\n\t */\n\tFreed,\n}\n\n/**\n */\nexport const enum TreeNavigationResult {\n\t/**\n\t * Attempt to navigate cursor to a key or index that is outside the client's view.\n\t */\n\tNotFound = -1,\n\n\t/**\n\t * Attempt to navigate cursor to a portion of the tree that has not yet been loaded.\n\t */\n\tPending = 0,\n\n\t/**\n\t * ITreeReader successfully navigated to the desired node.\n\t */\n\tOk = 1,\n}\n\n/**\n * TreeNavigationResult, but never \"Pending\".\n * Can be used when data is never pending.\n */\nexport type SynchronousNavigationResult =\n\t| TreeNavigationResult.Ok\n\t| TreeNavigationResult.NotFound;\n"]}
@@ -2,11 +2,11 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- export { EmptyKey, type TreeType, type Value, type TreeValue, AnchorSet, type DetachedField, type UpPath, type Range, type RangeUpPath, type PlaceUpPath, type PlaceIndex, type NodeIndex, type DetachedPlaceUpPath, type DetachedRangeUpPath, type FieldUpPath, type Anchor, type RootField, type ChildCollection, type ChildLocation, type FieldMapObject, type NodeData, type GenericTreeNode, type JsonableTree, EncodedJsonableTree, rootFieldKey, rootField, type ITreeCursor, CursorLocationType, type ITreeCursorSynchronous, castCursorToSynchronous, type GenericFieldsNode, type AnchorLocator, genericTreeKeys, getGenericTreeField, genericTreeDeleteIfEmpty, getDepth, mapCursorField, mapCursorFields, iterateCursorField, type MapTree, detachedFieldAsKey, keyAsDetachedField, visitDelta, combineVisitors, announceDelta, applyDelta, makeDetachedFieldIndex, setGenericTreeField, type DeltaVisitor, type AnnouncedVisitor, type PathVisitor, SparseNode, getDescendant, compareUpPaths, clonePath, topDownPath, compareFieldUpPaths, forEachNode, forEachNodeInSubtree, forEachField, type PathRootPrefix, deltaForRootInitialization, emptyFieldChanges, isEmptyFieldChanges, makeDetachedNodeId, offsetDetachId, emptyDelta, type AnchorSlot, type AnchorNode, anchorSlot, type UpPathDefault, inCursorField, inCursorNode, type AnchorEvents, type AnchorSetRootEvents, type ProtoNodes, CursorMarker, isCursor, DetachedFieldIndex, type ForestRootId, getDetachedFieldContainingPath, aboveRootPlaceholder, type DeltaRoot, type DeltaProtoNode, type DeltaMark, type DeltaDetachedNodeId, type DeltaFieldMap, type DeltaDetachedNodeChanges, type DeltaDetachedNodeBuild, type DeltaDetachedNodeDestruction, type DeltaDetachedNodeRename, type DeltaFieldChanges, type ExclusiveMapTree, deepCopyMapTree, } from "./tree/index.js";
5
+ export { EmptyKey, type TreeType, type Value, type TreeValue, AnchorSet, type DetachedField, type UpPath, type Range, type RangeUpPath, type PlaceUpPath, type PlaceIndex, type NodeIndex, type DetachedPlaceUpPath, type DetachedRangeUpPath, type FieldUpPath, type Anchor, type RootField, type ChildCollection, type ChildLocation, type FieldMapObject, type NodeData, type GenericTreeNode, type JsonableTree, EncodedJsonableTree, rootFieldKey, rootField, type ITreeCursor, CursorLocationType, type ITreeCursorSynchronous, castCursorToSynchronous, type GenericFieldsNode, type AnchorLocator, genericTreeKeys, getGenericTreeField, genericTreeDeleteIfEmpty, getDepth, mapCursorField, mapCursorFields, iterateCursorField, type MapTree, detachedFieldAsKey, keyAsDetachedField, visitDelta, createAnnouncedVisitor, combineVisitors, announceDelta, applyDelta, makeDetachedFieldIndex, setGenericTreeField, type DeltaVisitor, type AnnouncedVisitor, type PathVisitor, SparseNode, getDescendant, compareUpPaths, clonePath, topDownPath, compareFieldUpPaths, forEachNode, forEachNodeInSubtree, forEachField, type PathRootPrefix, deltaForRootInitialization, emptyFieldChanges, isEmptyFieldChanges, makeDetachedNodeId, offsetDetachId, emptyDelta, type AnchorSlot, type AnchorNode, anchorSlot, type UpPathDefault, inCursorField, inCursorNode, type AnchorEvents, type AnchorSetRootEvents, type ProtoNodes, CursorMarker, isCursor, DetachedFieldIndex, type ForestRootId, getDetachedFieldContainingPath, aboveRootPlaceholder, type DeltaRoot, type DeltaProtoNode, type DeltaMark, type DeltaDetachedNodeId, type DeltaFieldMap, type DeltaDetachedNodeChanges, type DeltaDetachedNodeBuild, type DeltaDetachedNodeDestruction, type DeltaDetachedNodeRename, type DeltaFieldChanges, type ExclusiveMapTree, deepCopyMapTree, } from "./tree/index.js";
6
6
  export { TreeNavigationResult, type IEditableForest, type IForestSubscription, type TreeLocation, type FieldLocation, type ForestLocation, type ITreeSubscriptionCursor, ITreeSubscriptionCursorState, initializeForest, type FieldAnchor, moveToDetachedField, type ForestEvents, } from "./forest/index.js";
7
7
  export { type FieldKey, type TreeNodeSchemaIdentifier, type TreeFieldStoredSchema, ValueSchema, TreeNodeStoredSchema, type TreeStoredSchemaSubscription, type MutableTreeStoredSchema, type FieldKindIdentifier, type FieldKindData, type TreeTypeSet, type TreeStoredSchema, TreeStoredSchemaRepository, schemaDataIsEmpty, type SchemaEvents, forbiddenFieldKindIdentifier, identifierFieldKindIdentifier, storedEmptyFieldSchema, type StoredSchemaCollection, schemaFormat, LeafNodeStoredSchema, ObjectNodeStoredSchema, MapNodeStoredSchema, toTreeNodeSchemaDataFormat, decodeFieldSchema, encodeFieldSchema, storedSchemaDecodeDispatcher, type ErasedTreeNodeSchemaDataFormat, type SchemaAndPolicy, Multiplicity, type SchemaPolicy, } from "./schema-stored/index.js";
8
8
  export { type ChangeFamily, type ChangeFamilyCodec, type ChangeEncodingContext, type ChangeFamilyEditor, EditBuilder, } from "./change-family/index.js";
9
9
  export { areEqualChangeAtomIds, areEqualChangeAtomIdOpts, makeChangeAtomId, asChangeAtomId, type ChangeRebaser, findAncestor, findCommonAncestor, type GraphCommit, CommitKind, type CommitMetadata, type RevisionTag, RevisionTagSchema, RevisionTagCodec, type ChangesetLocalId, type ChangeAtomId, type ChangeAtomIdMap, type TaggedChange, makeAnonChange, tagChange, mapTaggedChange, tagRollbackInverse, SessionIdSchema, mintCommit, rebaseBranch, type BranchRebaseResult, rebaseChange, rebaseChangeOverChanges, type RevisionMetadataSource, revisionMetadataSourceFromInfo, type RevisionInfo, type EncodedRevisionTag, type EncodedChangeAtomId, taggedAtomId, taggedOptAtomId, offsetChangeAtomId, replaceAtomRevisions, replaceChange, type RebaseStats, type RebaseStatsWithDuration, } from "./rebase/index.js";
10
10
  export { type Adapters, AdaptedViewSchema, Compatibility, type TreeAdapter, AllowedUpdateType, } from "./schema-view/index.js";
11
- export { type Revertible, RevertibleStatus, type RevertibleFactory } from "./revertible.js";
11
+ export { type Revertible, RevertibleStatus, type RevertibleFactory, type RevertibleAlphaFactory, type RevertibleAlpha, } from "./revertible.js";
12
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,KAAK,EACV,KAAK,SAAS,EACd,SAAS,EACT,KAAK,aAAa,EAClB,KAAK,MAAM,EACX,KAAK,KAAK,EACV,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,S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B,KAAK,eAAe,EACpB,KAAK,YAAY,EACjB,cAAc,EACd,SAAS,EACT,eAAe,EACf,kBAAkB,EAClB,eAAe,EACf,UAAU,EACV,YAAY,EACZ,KAAK,kBAAkB,EACvB,YAAY,EACZ,uBAAuB,EACvB,KAAK,sBAAsB,EAC3B,8BAA8B,EAC9B,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,mBAAmB,EACxB,YAAY,EACZ,eAAe,EACf,kBAAkB,EAClB,oBAAoB,EACpB,aAAa,EACb,KAAK,WAAW,EAChB,KAAK,uBAAuB,GAC5B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACN,KAAK,QAAQ,EACb,iBAAiB,EACjB,aAAa,EACb,KAAK,WAAW,EAChB,iBAAiB,GACjB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EAAE,KAAK,UAAU,EAAE,gBAAgB,EAAE,KAAK,iBAAiB,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,QAAQ,EACR,KAAK,QAAQ,EACb,KAAK,KAAK,EACV,KAAK,SAAS,EACd,SAAS,EACT,KAAK,aAAa,EAClB,KAAK,MAAM,EACX,KAAK,KAAK,EACV,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,SAAS,EACd,KAAK,mBAAmB,EACxB,KAAK,mBAAmB,EACxB,KAAK,WAAW,EAChB,KAAK,MAAM,EACX,KAAK,SAAS,EACd,KAAK,eAAe,EACpB,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,QAAQ,EACb,KAAK,eAAe,EACpB,KAAK,YAAY,EACjB,mBAAmB,EACnB,YAAY,EACZ,SAAS,EACT,KAAK,WAAW,EAChB,kBAAkB,EAClB,KAAK,sBAAsB,EAC3B,uBAAuB,EACvB,KAAK,iBAAiB,EACtB,KAAK,aAAa,EA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EAChB,KAAK,uBAAuB,GAC5B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACN,KAAK,QAAQ,EACb,iBAAiB,EACjB,aAAa,EACb,KAAK,WAAW,EAChB,iBAAiB,GACjB,MAAM,wBAAwB,CAAC;AAEhC,OAAO,EACN,KAAK,UAAU,EACf,gBAAgB,EAChB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,eAAe,GACpB,MAAM,iBAAiB,CAAC"}
@@ -4,8 +4,8 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.moveToDetachedField = exports.initializeForest = exports.ITreeSubscriptionCursorState = exports.TreeNavigationResult = exports.deepCopyMapTree = exports.aboveRootPlaceholder = exports.getDetachedFieldContainingPath = exports.DetachedFieldIndex = exports.isCursor = exports.CursorMarker = exports.inCursorNode = exports.inCursorField = exports.anchorSlot = exports.emptyDelta = exports.offsetDetachId = exports.makeDetachedNodeId = exports.isEmptyFieldChanges = exports.emptyFieldChanges = exports.deltaForRootInitialization = exports.forEachField = exports.forEachNodeInSubtree = exports.forEachNode = exports.compareFieldUpPaths = exports.topDownPath = exports.clonePath = exports.compareUpPaths = exports.getDescendant = exports.SparseNode = exports.setGenericTreeField = exports.makeDetachedFieldIndex = exports.applyDelta = exports.announceDelta = exports.combineVisitors = exports.visitDelta = exports.keyAsDetachedField = exports.detachedFieldAsKey = exports.iterateCursorField = exports.mapCursorFields = exports.mapCursorField = exports.getDepth = exports.genericTreeDeleteIfEmpty = exports.getGenericTreeField = exports.genericTreeKeys = exports.castCursorToSynchronous = exports.CursorLocationType = exports.rootField = exports.rootFieldKey = exports.EncodedJsonableTree = exports.AnchorSet = exports.EmptyKey = void 0;
8
- exports.RevertibleStatus = exports.AllowedUpdateType = exports.Compatibility = exports.AdaptedViewSchema = exports.replaceChange = exports.replaceAtomRevisions = exports.offsetChangeAtomId = exports.taggedOptAtomId = exports.taggedAtomId = exports.revisionMetadataSourceFromInfo = exports.rebaseChangeOverChanges = exports.rebaseChange = exports.rebaseBranch = exports.mintCommit = exports.SessionIdSchema = exports.tagRollbackInverse = exports.mapTaggedChange = exports.tagChange = exports.makeAnonChange = exports.RevisionTagCodec = exports.RevisionTagSchema = exports.CommitKind = exports.findCommonAncestor = exports.findAncestor = exports.asChangeAtomId = exports.makeChangeAtomId = exports.areEqualChangeAtomIdOpts = exports.areEqualChangeAtomIds = exports.EditBuilder = exports.Multiplicity = exports.storedSchemaDecodeDispatcher = exports.encodeFieldSchema = exports.decodeFieldSchema = exports.toTreeNodeSchemaDataFormat = exports.MapNodeStoredSchema = exports.ObjectNodeStoredSchema = exports.LeafNodeStoredSchema = exports.schemaFormat = exports.storedEmptyFieldSchema = exports.identifierFieldKindIdentifier = exports.forbiddenFieldKindIdentifier = exports.schemaDataIsEmpty = exports.TreeStoredSchemaRepository = exports.TreeNodeStoredSchema = exports.ValueSchema = void 0;
7
+ exports.initializeForest = exports.ITreeSubscriptionCursorState = exports.TreeNavigationResult = exports.deepCopyMapTree = exports.aboveRootPlaceholder = exports.getDetachedFieldContainingPath = exports.DetachedFieldIndex = exports.isCursor = exports.CursorMarker = exports.inCursorNode = exports.inCursorField = exports.anchorSlot = exports.emptyDelta = exports.offsetDetachId = exports.makeDetachedNodeId = exports.isEmptyFieldChanges = exports.emptyFieldChanges = exports.deltaForRootInitialization = exports.forEachField = exports.forEachNodeInSubtree = exports.forEachNode = exports.compareFieldUpPaths = exports.topDownPath = exports.clonePath = exports.compareUpPaths = exports.getDescendant = exports.SparseNode = exports.setGenericTreeField = exports.makeDetachedFieldIndex = exports.applyDelta = exports.announceDelta = exports.combineVisitors = exports.createAnnouncedVisitor = exports.visitDelta = exports.keyAsDetachedField = exports.detachedFieldAsKey = exports.iterateCursorField = exports.mapCursorFields = exports.mapCursorField = exports.getDepth = exports.genericTreeDeleteIfEmpty = exports.getGenericTreeField = exports.genericTreeKeys = exports.castCursorToSynchronous = exports.CursorLocationType = exports.rootField = exports.rootFieldKey = exports.EncodedJsonableTree = exports.AnchorSet = exports.EmptyKey = void 0;
8
+ exports.RevertibleStatus = exports.AllowedUpdateType = exports.Compatibility = exports.AdaptedViewSchema = exports.replaceChange = exports.replaceAtomRevisions = exports.offsetChangeAtomId = exports.taggedOptAtomId = exports.taggedAtomId = exports.revisionMetadataSourceFromInfo = exports.rebaseChangeOverChanges = exports.rebaseChange = exports.rebaseBranch = exports.mintCommit = exports.SessionIdSchema = exports.tagRollbackInverse = exports.mapTaggedChange = exports.tagChange = exports.makeAnonChange = exports.RevisionTagCodec = exports.RevisionTagSchema = exports.CommitKind = exports.findCommonAncestor = exports.findAncestor = exports.asChangeAtomId = exports.makeChangeAtomId = exports.areEqualChangeAtomIdOpts = exports.areEqualChangeAtomIds = exports.EditBuilder = exports.Multiplicity = exports.storedSchemaDecodeDispatcher = exports.encodeFieldSchema = exports.decodeFieldSchema = exports.toTreeNodeSchemaDataFormat = exports.MapNodeStoredSchema = exports.ObjectNodeStoredSchema = exports.LeafNodeStoredSchema = exports.schemaFormat = exports.storedEmptyFieldSchema = exports.identifierFieldKindIdentifier = exports.forbiddenFieldKindIdentifier = exports.schemaDataIsEmpty = exports.TreeStoredSchemaRepository = exports.TreeNodeStoredSchema = exports.ValueSchema = exports.moveToDetachedField = void 0;
9
9
  var index_js_1 = require("./tree/index.js");
10
10
  Object.defineProperty(exports, "EmptyKey", { enumerable: true, get: function () { return index_js_1.EmptyKey; } });
11
11
  Object.defineProperty(exports, "AnchorSet", { enumerable: true, get: function () { return index_js_1.AnchorSet; } });
@@ -24,6 +24,7 @@ Object.defineProperty(exports, "iterateCursorField", { enumerable: true, get: fu
24
24
  Object.defineProperty(exports, "detachedFieldAsKey", { enumerable: true, get: function () { return index_js_1.detachedFieldAsKey; } });
25
25
  Object.defineProperty(exports, "keyAsDetachedField", { enumerable: true, get: function () { return index_js_1.keyAsDetachedField; } });
26
26
  Object.defineProperty(exports, "visitDelta", { enumerable: true, get: function () { return index_js_1.visitDelta; } });
27
+ Object.defineProperty(exports, "createAnnouncedVisitor", { enumerable: true, get: function () { return index_js_1.createAnnouncedVisitor; } });
27
28
  Object.defineProperty(exports, "combineVisitors", { enumerable: true, get: function () { return index_js_1.combineVisitors; } });
28
29
  Object.defineProperty(exports, "announceDelta", { enumerable: true, get: function () { return index_js_1.announceDelta; } });
29
30
  Object.defineProperty(exports, "applyDelta", { enumerable: true, get: function () { return index_js_1.applyDelta; } });