@itwin/presentation-common 3.6.0-dev.8 → 4.0.0-dev.2

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 (368) hide show
  1. package/CHANGELOG.md +26 -1
  2. package/LICENSE.md +1 -1
  3. package/Ruleset.schema.json +236 -309
  4. package/lib/cjs/presentation-common/EC.d.ts +52 -17
  5. package/lib/cjs/presentation-common/EC.d.ts.map +1 -1
  6. package/lib/cjs/presentation-common/EC.js +74 -54
  7. package/lib/cjs/presentation-common/EC.js.map +1 -1
  8. package/lib/cjs/presentation-common/ElementProperties.d.ts +14 -14
  9. package/lib/cjs/presentation-common/ElementProperties.js.map +1 -1
  10. package/lib/cjs/presentation-common/InstanceFilterDefinition.d.ts +43 -9
  11. package/lib/cjs/presentation-common/InstanceFilterDefinition.d.ts.map +1 -1
  12. package/lib/cjs/presentation-common/InstanceFilterDefinition.js.map +1 -1
  13. package/lib/cjs/presentation-common/KeySet.d.ts.map +1 -1
  14. package/lib/cjs/presentation-common/KeySet.js +5 -0
  15. package/lib/cjs/presentation-common/KeySet.js.map +1 -1
  16. package/lib/cjs/presentation-common/LabelDefinition.d.ts +24 -16
  17. package/lib/cjs/presentation-common/LabelDefinition.d.ts.map +1 -1
  18. package/lib/cjs/presentation-common/LabelDefinition.js +26 -29
  19. package/lib/cjs/presentation-common/LabelDefinition.js.map +1 -1
  20. package/lib/cjs/presentation-common/PresentationIpcInterface.d.ts +7 -4
  21. package/lib/cjs/presentation-common/PresentationIpcInterface.d.ts.map +1 -1
  22. package/lib/cjs/presentation-common/PresentationIpcInterface.js.map +1 -1
  23. package/lib/cjs/presentation-common/PresentationManagerOptions.d.ts +30 -11
  24. package/lib/cjs/presentation-common/PresentationManagerOptions.d.ts.map +1 -1
  25. package/lib/cjs/presentation-common/PresentationManagerOptions.js +1 -1
  26. package/lib/cjs/presentation-common/PresentationManagerOptions.js.map +1 -1
  27. package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts +24 -19
  28. package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
  29. package/lib/cjs/presentation-common/PresentationRpcInterface.js +7 -5
  30. package/lib/cjs/presentation-common/PresentationRpcInterface.js.map +1 -1
  31. package/lib/cjs/presentation-common/RpcRequestsHandler.d.ts +9 -8
  32. package/lib/cjs/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
  33. package/lib/cjs/presentation-common/RpcRequestsHandler.js +17 -1
  34. package/lib/cjs/presentation-common/RpcRequestsHandler.js.map +1 -1
  35. package/lib/cjs/presentation-common/RulesetVariables.d.ts +5 -0
  36. package/lib/cjs/presentation-common/RulesetVariables.d.ts.map +1 -1
  37. package/lib/cjs/presentation-common/RulesetVariables.js.map +1 -1
  38. package/lib/cjs/presentation-common/Update.d.ts +23 -4
  39. package/lib/cjs/presentation-common/Update.d.ts.map +1 -1
  40. package/lib/cjs/presentation-common/Update.js +34 -4
  41. package/lib/cjs/presentation-common/Update.js.map +1 -1
  42. package/lib/cjs/presentation-common/content/Category.d.ts.map +1 -1
  43. package/lib/cjs/presentation-common/content/Category.js +1 -2
  44. package/lib/cjs/presentation-common/content/Category.js.map +1 -1
  45. package/lib/cjs/presentation-common/content/ContentTraverser.d.ts +194 -24
  46. package/lib/cjs/presentation-common/content/ContentTraverser.d.ts.map +1 -1
  47. package/lib/cjs/presentation-common/content/ContentTraverser.js +63 -44
  48. package/lib/cjs/presentation-common/content/ContentTraverser.js.map +1 -1
  49. package/lib/cjs/presentation-common/content/Descriptor.d.ts +76 -23
  50. package/lib/cjs/presentation-common/content/Descriptor.d.ts.map +1 -1
  51. package/lib/cjs/presentation-common/content/Descriptor.js +5 -7
  52. package/lib/cjs/presentation-common/content/Descriptor.js.map +1 -1
  53. package/lib/cjs/presentation-common/content/Fields.d.ts +24 -5
  54. package/lib/cjs/presentation-common/content/Fields.d.ts.map +1 -1
  55. package/lib/cjs/presentation-common/content/Fields.js +10 -7
  56. package/lib/cjs/presentation-common/content/Fields.js.map +1 -1
  57. package/lib/cjs/presentation-common/content/Item.d.ts +8 -10
  58. package/lib/cjs/presentation-common/content/Item.d.ts.map +1 -1
  59. package/lib/cjs/presentation-common/content/Item.js +6 -8
  60. package/lib/cjs/presentation-common/content/Item.js.map +1 -1
  61. package/lib/cjs/presentation-common/content/Property.d.ts +8 -2
  62. package/lib/cjs/presentation-common/content/Property.d.ts.map +1 -1
  63. package/lib/cjs/presentation-common/content/Property.js +12 -8
  64. package/lib/cjs/presentation-common/content/Property.js.map +1 -1
  65. package/lib/cjs/presentation-common/content/Value.d.ts +43 -11
  66. package/lib/cjs/presentation-common/content/Value.d.ts.map +1 -1
  67. package/lib/cjs/presentation-common/content/Value.js +72 -16
  68. package/lib/cjs/presentation-common/content/Value.js.map +1 -1
  69. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts +38 -0
  70. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -0
  71. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js +32 -0
  72. package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js.map +1 -0
  73. package/lib/cjs/presentation-common/hierarchy/Key.d.ts +75 -14
  74. package/lib/cjs/presentation-common/hierarchy/Key.d.ts.map +1 -1
  75. package/lib/cjs/presentation-common/hierarchy/Key.js +15 -6
  76. package/lib/cjs/presentation-common/hierarchy/Key.js.map +1 -1
  77. package/lib/cjs/presentation-common/hierarchy/Node.d.ts +32 -19
  78. package/lib/cjs/presentation-common/hierarchy/Node.d.ts.map +1 -1
  79. package/lib/cjs/presentation-common/hierarchy/Node.js +23 -14
  80. package/lib/cjs/presentation-common/hierarchy/Node.js.map +1 -1
  81. package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts +18 -7
  82. package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
  83. package/lib/cjs/presentation-common/hierarchy/NodePathElement.js +33 -9
  84. package/lib/cjs/presentation-common/hierarchy/NodePathElement.js.map +1 -1
  85. package/lib/cjs/presentation-common/rules/RelationshipPathSpecification.d.ts +5 -2
  86. package/lib/cjs/presentation-common/rules/RelationshipPathSpecification.d.ts.map +1 -1
  87. package/lib/cjs/presentation-common/rules/RelationshipPathSpecification.js.map +1 -1
  88. package/lib/cjs/presentation-common/rules/Rule.d.ts +6 -4
  89. package/lib/cjs/presentation-common/rules/Rule.d.ts.map +1 -1
  90. package/lib/cjs/presentation-common/rules/Rule.js.map +1 -1
  91. package/lib/cjs/presentation-common/rules/Ruleset.d.ts +0 -1
  92. package/lib/cjs/presentation-common/rules/Ruleset.d.ts.map +1 -1
  93. package/lib/cjs/presentation-common/rules/Ruleset.js.map +1 -1
  94. package/lib/cjs/presentation-common/rules/SchemasSpecification.d.ts +1 -1
  95. package/lib/cjs/presentation-common/rules/SchemasSpecification.js.map +1 -1
  96. package/lib/cjs/presentation-common/rules/Variables.d.ts +5 -2
  97. package/lib/cjs/presentation-common/rules/Variables.d.ts.map +1 -1
  98. package/lib/cjs/presentation-common/rules/Variables.js.map +1 -1
  99. package/lib/cjs/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.d.ts +3 -3
  100. package/lib/cjs/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.d.ts.map +1 -1
  101. package/lib/cjs/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.js.map +1 -1
  102. package/lib/cjs/presentation-common/rules/content/ContentRelatedInstancesSpecification.d.ts +2 -2
  103. package/lib/cjs/presentation-common/rules/content/ContentRelatedInstancesSpecification.d.ts.map +1 -1
  104. package/lib/cjs/presentation-common/rules/content/ContentRelatedInstancesSpecification.js.map +1 -1
  105. package/lib/cjs/presentation-common/rules/content/ContentRule.d.ts +2 -2
  106. package/lib/cjs/presentation-common/rules/content/ContentRule.d.ts.map +1 -1
  107. package/lib/cjs/presentation-common/rules/content/ContentRule.js.map +1 -1
  108. package/lib/cjs/presentation-common/rules/content/ContentSpecification.d.ts +6 -3
  109. package/lib/cjs/presentation-common/rules/content/ContentSpecification.d.ts.map +1 -1
  110. package/lib/cjs/presentation-common/rules/content/ContentSpecification.js.map +1 -1
  111. package/lib/cjs/presentation-common/rules/content/DefaultPropertyCategoryOverride.d.ts +2 -2
  112. package/lib/cjs/presentation-common/rules/content/DefaultPropertyCategoryOverride.d.ts.map +1 -1
  113. package/lib/cjs/presentation-common/rules/content/DefaultPropertyCategoryOverride.js.map +1 -1
  114. package/lib/cjs/presentation-common/rules/content/SelectedNodeInstancesSpecification.d.ts +2 -2
  115. package/lib/cjs/presentation-common/rules/content/SelectedNodeInstancesSpecification.d.ts.map +1 -1
  116. package/lib/cjs/presentation-common/rules/content/SelectedNodeInstancesSpecification.js.map +1 -1
  117. package/lib/cjs/presentation-common/rules/content/modifiers/ContentModifier.d.ts +2 -2
  118. package/lib/cjs/presentation-common/rules/content/modifiers/ContentModifier.d.ts.map +1 -1
  119. package/lib/cjs/presentation-common/rules/content/modifiers/ContentModifier.js.map +1 -1
  120. package/lib/cjs/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.d.ts +9 -6
  121. package/lib/cjs/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.d.ts.map +1 -1
  122. package/lib/cjs/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.js.map +1 -1
  123. package/lib/cjs/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.d.ts +6 -3
  124. package/lib/cjs/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.d.ts.map +1 -1
  125. package/lib/cjs/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.js.map +1 -1
  126. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.d.ts +3 -3
  127. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.d.ts.map +1 -1
  128. package/lib/cjs/presentation-common/rules/customization/CheckBoxRule.js.map +1 -1
  129. package/lib/cjs/presentation-common/rules/customization/ExtendedDataRule.d.ts +2 -2
  130. package/lib/cjs/presentation-common/rules/customization/ExtendedDataRule.d.ts.map +1 -1
  131. package/lib/cjs/presentation-common/rules/customization/ExtendedDataRule.js.map +1 -1
  132. package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts +20 -13
  133. package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
  134. package/lib/cjs/presentation-common/rules/customization/GroupingRule.js +1 -1
  135. package/lib/cjs/presentation-common/rules/customization/GroupingRule.js.map +1 -1
  136. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.d.ts +3 -3
  137. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.d.ts.map +1 -1
  138. package/lib/cjs/presentation-common/rules/customization/ImageIdOverride.js.map +1 -1
  139. package/lib/cjs/presentation-common/rules/customization/InstanceLabelOverride.d.ts +17 -15
  140. package/lib/cjs/presentation-common/rules/customization/InstanceLabelOverride.d.ts.map +1 -1
  141. package/lib/cjs/presentation-common/rules/customization/InstanceLabelOverride.js.map +1 -1
  142. package/lib/cjs/presentation-common/rules/customization/LabelOverride.d.ts +3 -3
  143. package/lib/cjs/presentation-common/rules/customization/LabelOverride.d.ts.map +1 -1
  144. package/lib/cjs/presentation-common/rules/customization/LabelOverride.js.map +1 -1
  145. package/lib/cjs/presentation-common/rules/customization/SortingRule.d.ts +3 -3
  146. package/lib/cjs/presentation-common/rules/customization/SortingRule.d.ts.map +1 -1
  147. package/lib/cjs/presentation-common/rules/customization/SortingRule.js.map +1 -1
  148. package/lib/cjs/presentation-common/rules/customization/StyleOverride.d.ts +3 -3
  149. package/lib/cjs/presentation-common/rules/customization/StyleOverride.d.ts.map +1 -1
  150. package/lib/cjs/presentation-common/rules/customization/StyleOverride.js.map +1 -1
  151. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.d.ts +1 -2
  152. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.d.ts.map +1 -1
  153. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.js.map +1 -1
  154. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts +5 -4
  155. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts.map +1 -1
  156. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.js +0 -1
  157. package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.js.map +1 -1
  158. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -2
  159. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
  160. package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
  161. package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts +9 -6
  162. package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts.map +1 -1
  163. package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js.map +1 -1
  164. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +3 -3
  165. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
  166. package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
  167. package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts +2 -2
  168. package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts.map +1 -1
  169. package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.js.map +1 -1
  170. package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts +2 -2
  171. package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts.map +1 -1
  172. package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js.map +1 -1
  173. package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.d.ts +1 -2
  174. package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.d.ts.map +1 -1
  175. package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.js.map +1 -1
  176. package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.d.ts +0 -1
  177. package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.d.ts.map +1 -1
  178. package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.js.map +1 -1
  179. package/lib/cjs/presentation-common/selection/SelectionScope.d.ts +17 -4
  180. package/lib/cjs/presentation-common/selection/SelectionScope.d.ts.map +1 -1
  181. package/lib/cjs/presentation-common/selection/SelectionScope.js.map +1 -1
  182. package/lib/cjs/presentation-common.d.ts +1 -0
  183. package/lib/cjs/presentation-common.d.ts.map +1 -1
  184. package/lib/cjs/presentation-common.js +1 -0
  185. package/lib/cjs/presentation-common.js.map +1 -1
  186. package/lib/esm/presentation-common/EC.d.ts +52 -17
  187. package/lib/esm/presentation-common/EC.d.ts.map +1 -1
  188. package/lib/esm/presentation-common/EC.js +75 -55
  189. package/lib/esm/presentation-common/EC.js.map +1 -1
  190. package/lib/esm/presentation-common/ElementProperties.d.ts +14 -14
  191. package/lib/esm/presentation-common/ElementProperties.js.map +1 -1
  192. package/lib/esm/presentation-common/InstanceFilterDefinition.d.ts +43 -9
  193. package/lib/esm/presentation-common/InstanceFilterDefinition.d.ts.map +1 -1
  194. package/lib/esm/presentation-common/InstanceFilterDefinition.js.map +1 -1
  195. package/lib/esm/presentation-common/KeySet.d.ts.map +1 -1
  196. package/lib/esm/presentation-common/KeySet.js +5 -0
  197. package/lib/esm/presentation-common/KeySet.js.map +1 -1
  198. package/lib/esm/presentation-common/LabelDefinition.d.ts +24 -16
  199. package/lib/esm/presentation-common/LabelDefinition.d.ts.map +1 -1
  200. package/lib/esm/presentation-common/LabelDefinition.js +26 -29
  201. package/lib/esm/presentation-common/LabelDefinition.js.map +1 -1
  202. package/lib/esm/presentation-common/PresentationIpcInterface.d.ts +7 -4
  203. package/lib/esm/presentation-common/PresentationIpcInterface.d.ts.map +1 -1
  204. package/lib/esm/presentation-common/PresentationIpcInterface.js.map +1 -1
  205. package/lib/esm/presentation-common/PresentationManagerOptions.d.ts +30 -11
  206. package/lib/esm/presentation-common/PresentationManagerOptions.d.ts.map +1 -1
  207. package/lib/esm/presentation-common/PresentationManagerOptions.js +1 -1
  208. package/lib/esm/presentation-common/PresentationManagerOptions.js.map +1 -1
  209. package/lib/esm/presentation-common/PresentationRpcInterface.d.ts +24 -19
  210. package/lib/esm/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
  211. package/lib/esm/presentation-common/PresentationRpcInterface.js +7 -5
  212. package/lib/esm/presentation-common/PresentationRpcInterface.js.map +1 -1
  213. package/lib/esm/presentation-common/RpcRequestsHandler.d.ts +9 -8
  214. package/lib/esm/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
  215. package/lib/esm/presentation-common/RpcRequestsHandler.js +17 -1
  216. package/lib/esm/presentation-common/RpcRequestsHandler.js.map +1 -1
  217. package/lib/esm/presentation-common/RulesetVariables.d.ts +5 -0
  218. package/lib/esm/presentation-common/RulesetVariables.d.ts.map +1 -1
  219. package/lib/esm/presentation-common/RulesetVariables.js.map +1 -1
  220. package/lib/esm/presentation-common/Update.d.ts +23 -4
  221. package/lib/esm/presentation-common/Update.d.ts.map +1 -1
  222. package/lib/esm/presentation-common/Update.js +34 -4
  223. package/lib/esm/presentation-common/Update.js.map +1 -1
  224. package/lib/esm/presentation-common/content/Category.d.ts.map +1 -1
  225. package/lib/esm/presentation-common/content/Category.js +1 -2
  226. package/lib/esm/presentation-common/content/Category.js.map +1 -1
  227. package/lib/esm/presentation-common/content/ContentTraverser.d.ts +194 -24
  228. package/lib/esm/presentation-common/content/ContentTraverser.d.ts.map +1 -1
  229. package/lib/esm/presentation-common/content/ContentTraverser.js +60 -42
  230. package/lib/esm/presentation-common/content/ContentTraverser.js.map +1 -1
  231. package/lib/esm/presentation-common/content/Descriptor.d.ts +76 -23
  232. package/lib/esm/presentation-common/content/Descriptor.d.ts.map +1 -1
  233. package/lib/esm/presentation-common/content/Descriptor.js +5 -7
  234. package/lib/esm/presentation-common/content/Descriptor.js.map +1 -1
  235. package/lib/esm/presentation-common/content/Fields.d.ts +24 -5
  236. package/lib/esm/presentation-common/content/Fields.d.ts.map +1 -1
  237. package/lib/esm/presentation-common/content/Fields.js +11 -8
  238. package/lib/esm/presentation-common/content/Fields.js.map +1 -1
  239. package/lib/esm/presentation-common/content/Item.d.ts +8 -10
  240. package/lib/esm/presentation-common/content/Item.d.ts.map +1 -1
  241. package/lib/esm/presentation-common/content/Item.js +6 -8
  242. package/lib/esm/presentation-common/content/Item.js.map +1 -1
  243. package/lib/esm/presentation-common/content/Property.d.ts +8 -2
  244. package/lib/esm/presentation-common/content/Property.d.ts.map +1 -1
  245. package/lib/esm/presentation-common/content/Property.js +12 -8
  246. package/lib/esm/presentation-common/content/Property.js.map +1 -1
  247. package/lib/esm/presentation-common/content/Value.d.ts +43 -11
  248. package/lib/esm/presentation-common/content/Value.d.ts.map +1 -1
  249. package/lib/esm/presentation-common/content/Value.js +72 -16
  250. package/lib/esm/presentation-common/content/Value.js.map +1 -1
  251. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts +38 -0
  252. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -0
  253. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js +29 -0
  254. package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js.map +1 -0
  255. package/lib/esm/presentation-common/hierarchy/Key.d.ts +75 -14
  256. package/lib/esm/presentation-common/hierarchy/Key.d.ts.map +1 -1
  257. package/lib/esm/presentation-common/hierarchy/Key.js +15 -6
  258. package/lib/esm/presentation-common/hierarchy/Key.js.map +1 -1
  259. package/lib/esm/presentation-common/hierarchy/Node.d.ts +32 -19
  260. package/lib/esm/presentation-common/hierarchy/Node.d.ts.map +1 -1
  261. package/lib/esm/presentation-common/hierarchy/Node.js +23 -14
  262. package/lib/esm/presentation-common/hierarchy/Node.js.map +1 -1
  263. package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts +18 -7
  264. package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
  265. package/lib/esm/presentation-common/hierarchy/NodePathElement.js +33 -9
  266. package/lib/esm/presentation-common/hierarchy/NodePathElement.js.map +1 -1
  267. package/lib/esm/presentation-common/rules/RelationshipPathSpecification.d.ts +5 -2
  268. package/lib/esm/presentation-common/rules/RelationshipPathSpecification.d.ts.map +1 -1
  269. package/lib/esm/presentation-common/rules/RelationshipPathSpecification.js.map +1 -1
  270. package/lib/esm/presentation-common/rules/Rule.d.ts +6 -4
  271. package/lib/esm/presentation-common/rules/Rule.d.ts.map +1 -1
  272. package/lib/esm/presentation-common/rules/Rule.js.map +1 -1
  273. package/lib/esm/presentation-common/rules/Ruleset.d.ts +0 -1
  274. package/lib/esm/presentation-common/rules/Ruleset.d.ts.map +1 -1
  275. package/lib/esm/presentation-common/rules/Ruleset.js.map +1 -1
  276. package/lib/esm/presentation-common/rules/SchemasSpecification.d.ts +1 -1
  277. package/lib/esm/presentation-common/rules/SchemasSpecification.js.map +1 -1
  278. package/lib/esm/presentation-common/rules/Variables.d.ts +5 -2
  279. package/lib/esm/presentation-common/rules/Variables.d.ts.map +1 -1
  280. package/lib/esm/presentation-common/rules/Variables.js.map +1 -1
  281. package/lib/esm/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.d.ts +3 -3
  282. package/lib/esm/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.d.ts.map +1 -1
  283. package/lib/esm/presentation-common/rules/content/ContentInstancesOfSpecificClassesSpecification.js.map +1 -1
  284. package/lib/esm/presentation-common/rules/content/ContentRelatedInstancesSpecification.d.ts +2 -2
  285. package/lib/esm/presentation-common/rules/content/ContentRelatedInstancesSpecification.d.ts.map +1 -1
  286. package/lib/esm/presentation-common/rules/content/ContentRelatedInstancesSpecification.js.map +1 -1
  287. package/lib/esm/presentation-common/rules/content/ContentRule.d.ts +2 -2
  288. package/lib/esm/presentation-common/rules/content/ContentRule.d.ts.map +1 -1
  289. package/lib/esm/presentation-common/rules/content/ContentRule.js.map +1 -1
  290. package/lib/esm/presentation-common/rules/content/ContentSpecification.d.ts +6 -3
  291. package/lib/esm/presentation-common/rules/content/ContentSpecification.d.ts.map +1 -1
  292. package/lib/esm/presentation-common/rules/content/ContentSpecification.js.map +1 -1
  293. package/lib/esm/presentation-common/rules/content/DefaultPropertyCategoryOverride.d.ts +2 -2
  294. package/lib/esm/presentation-common/rules/content/DefaultPropertyCategoryOverride.d.ts.map +1 -1
  295. package/lib/esm/presentation-common/rules/content/DefaultPropertyCategoryOverride.js.map +1 -1
  296. package/lib/esm/presentation-common/rules/content/SelectedNodeInstancesSpecification.d.ts +2 -2
  297. package/lib/esm/presentation-common/rules/content/SelectedNodeInstancesSpecification.d.ts.map +1 -1
  298. package/lib/esm/presentation-common/rules/content/SelectedNodeInstancesSpecification.js.map +1 -1
  299. package/lib/esm/presentation-common/rules/content/modifiers/ContentModifier.d.ts +2 -2
  300. package/lib/esm/presentation-common/rules/content/modifiers/ContentModifier.d.ts.map +1 -1
  301. package/lib/esm/presentation-common/rules/content/modifiers/ContentModifier.js.map +1 -1
  302. package/lib/esm/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.d.ts +9 -6
  303. package/lib/esm/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.d.ts.map +1 -1
  304. package/lib/esm/presentation-common/rules/content/modifiers/PropertyEditorsSpecification.js.map +1 -1
  305. package/lib/esm/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.d.ts +6 -3
  306. package/lib/esm/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.d.ts.map +1 -1
  307. package/lib/esm/presentation-common/rules/content/modifiers/RelatedPropertiesSpecification.js.map +1 -1
  308. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.d.ts +3 -3
  309. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.d.ts.map +1 -1
  310. package/lib/esm/presentation-common/rules/customization/CheckBoxRule.js.map +1 -1
  311. package/lib/esm/presentation-common/rules/customization/ExtendedDataRule.d.ts +2 -2
  312. package/lib/esm/presentation-common/rules/customization/ExtendedDataRule.d.ts.map +1 -1
  313. package/lib/esm/presentation-common/rules/customization/ExtendedDataRule.js.map +1 -1
  314. package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts +20 -13
  315. package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
  316. package/lib/esm/presentation-common/rules/customization/GroupingRule.js +1 -1
  317. package/lib/esm/presentation-common/rules/customization/GroupingRule.js.map +1 -1
  318. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.d.ts +3 -3
  319. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.d.ts.map +1 -1
  320. package/lib/esm/presentation-common/rules/customization/ImageIdOverride.js.map +1 -1
  321. package/lib/esm/presentation-common/rules/customization/InstanceLabelOverride.d.ts +17 -15
  322. package/lib/esm/presentation-common/rules/customization/InstanceLabelOverride.d.ts.map +1 -1
  323. package/lib/esm/presentation-common/rules/customization/InstanceLabelOverride.js.map +1 -1
  324. package/lib/esm/presentation-common/rules/customization/LabelOverride.d.ts +3 -3
  325. package/lib/esm/presentation-common/rules/customization/LabelOverride.d.ts.map +1 -1
  326. package/lib/esm/presentation-common/rules/customization/LabelOverride.js.map +1 -1
  327. package/lib/esm/presentation-common/rules/customization/SortingRule.d.ts +3 -3
  328. package/lib/esm/presentation-common/rules/customization/SortingRule.d.ts.map +1 -1
  329. package/lib/esm/presentation-common/rules/customization/SortingRule.js.map +1 -1
  330. package/lib/esm/presentation-common/rules/customization/StyleOverride.d.ts +3 -3
  331. package/lib/esm/presentation-common/rules/customization/StyleOverride.d.ts.map +1 -1
  332. package/lib/esm/presentation-common/rules/customization/StyleOverride.js.map +1 -1
  333. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.d.ts +1 -2
  334. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.d.ts.map +1 -1
  335. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.js.map +1 -1
  336. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts +5 -4
  337. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts.map +1 -1
  338. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.js +0 -1
  339. package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.js.map +1 -1
  340. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -2
  341. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
  342. package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
  343. package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts +9 -6
  344. package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts.map +1 -1
  345. package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js.map +1 -1
  346. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +3 -3
  347. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
  348. package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
  349. package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts +2 -2
  350. package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts.map +1 -1
  351. package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.js.map +1 -1
  352. package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts +2 -2
  353. package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts.map +1 -1
  354. package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js.map +1 -1
  355. package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.d.ts +1 -2
  356. package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.d.ts.map +1 -1
  357. package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.js.map +1 -1
  358. package/lib/esm/presentation-common/rules/hierarchy/SubCondition.d.ts +0 -1
  359. package/lib/esm/presentation-common/rules/hierarchy/SubCondition.d.ts.map +1 -1
  360. package/lib/esm/presentation-common/rules/hierarchy/SubCondition.js.map +1 -1
  361. package/lib/esm/presentation-common/selection/SelectionScope.d.ts +17 -4
  362. package/lib/esm/presentation-common/selection/SelectionScope.d.ts.map +1 -1
  363. package/lib/esm/presentation-common/selection/SelectionScope.js.map +1 -1
  364. package/lib/esm/presentation-common.d.ts +1 -0
  365. package/lib/esm/presentation-common.d.ts.map +1 -1
  366. package/lib/esm/presentation-common.js +1 -0
  367. package/lib/esm/presentation-common.js.map +1 -1
  368. package/package.json +10 -10
@@ -85,6 +85,7 @@ export class KeySet {
85
85
  get nodeKeys() {
86
86
  const set = new Set();
87
87
  for (const serialized of this._nodeKeys) {
88
+ // eslint-disable-next-line deprecation/deprecation
88
89
  const key = NodeKey.fromJSON(JSON.parse(serialized));
89
90
  set.add(key);
90
91
  }
@@ -117,6 +118,7 @@ export class KeySet {
117
118
  }
118
119
  addKeySet(keyset, pred) {
119
120
  for (const key of keyset._nodeKeys) {
121
+ // eslint-disable-next-line deprecation/deprecation
120
122
  if (!pred || pred(NodeKey.fromJSON(JSON.parse(key))))
121
123
  this._nodeKeys.add(key);
122
124
  }
@@ -345,6 +347,7 @@ export class KeySet {
345
347
  if (some(entry[1], (id) => callback({ className, id })))
346
348
  return true;
347
349
  }
350
+ // eslint-disable-next-line deprecation/deprecation
348
351
  return some(this._nodeKeys, (serializedKey) => callback(NodeKey.fromJSON(JSON.parse(serializedKey))));
349
352
  }
350
353
  /** Iterate over all keys in this keyset. */
@@ -355,6 +358,7 @@ export class KeySet {
355
358
  ids.forEach((id) => callback({ className: recentClassName, id }, index++));
356
359
  });
357
360
  this._nodeKeys.forEach((serializedKey) => {
361
+ // eslint-disable-next-line deprecation/deprecation
358
362
  callback(NodeKey.fromJSON(JSON.parse(serializedKey)), index++);
359
363
  });
360
364
  }
@@ -392,6 +396,7 @@ export class KeySet {
392
396
  instanceKeys.push([className, compressedIds.length > 0 ? compressedIds : Id64.invalid]);
393
397
  }
394
398
  }
399
+ // eslint-disable-next-line deprecation/deprecation
395
400
  const nodeKeys = [];
396
401
  for (const serializedKey of this._nodeKeys.values())
397
402
  nodeKeys.push(JSON.parse(serializedKey));
@@ -1 +1 @@
1
- {"version":3,"file":"KeySet.js","sourceRoot":"","sources":["../../../src/presentation-common/KeySet.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH,OAAO,EAAE,iBAAiB,EAAE,IAAI,EAAc,IAAI,EAAc,MAAM,qBAAqB,CAAC;AAG5F,OAAO,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAChE,OAAO,EAAE,OAAO,EAAe,MAAM,iBAAiB,CAAC;AAQvD,cAAc;AACd,MAAM,KAAW,GAAG,CAenB;AAfD,WAAiB,GAAG;IAClB,+CAA+C;IAC/C,SAAgB,SAAS,CAAC,GAAQ;QAChC,OAAO,CAAC,CAAE,GAAe,CAAC,IAAI,CAAC;IACjC,CAAC;IAFe,aAAS,YAExB,CAAA;IAED,oDAAoD;IACpD,SAAgB,aAAa,CAAC,GAAQ;QACpC,OAAO,CAAC,CAAE,GAAmB,CAAC,SAAS,IAAI,CAAC,CAAE,GAAmB,CAAC,EAAE,CAAC;IACvE,CAAC;IAFe,iBAAa,gBAE5B,CAAA;IAED,oDAAoD;IACpD,SAAgB,aAAa,CAAC,GAAQ;QACpC,OAAO,CAAC,CAAE,GAAmB,CAAC,aAAa,IAAI,CAAC,CAAE,GAAmB,CAAC,EAAE,CAAC;IAC3E,CAAC;IAFe,iBAAa,gBAE5B,CAAA;AACH,CAAC,EAfgB,GAAG,KAAH,GAAG,Q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AChB,CAAC;CACF;AAED,MAAM,IAAI,GAAG,CAAQ,GAAe,EAAE,EAA4B,EAAE,EAAE;IACpE,KAAK,MAAM,IAAI,IAAI,GAAG,EAAE;QACtB,IAAI,EAAE,CAAC,IAAI,CAAC;YACV,OAAO,IAAI,CAAC;KACf;IACD,OAAO,KAAK,CAAC;AACf,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Core\r\n */\r\n\r\nimport { CompressedId64Set, Guid, GuidString, Id64, Id64String } from \"@itwin/core-bentley\";\r\nimport { EntityProps } from \"@itwin/core-common\";\r\nimport { InstanceId, InstanceKey } from \"./EC\";\r\nimport { PresentationError, PresentationStatus } from \"./Error\";\r\nimport { NodeKey, NodeKeyJSON } from \"./hierarchy/Key\";\r\n\r\n/**\r\n * A single key that identifies something in an iTwin.js application\r\n * @public\r\n */\r\nexport type Key = Readonly<NodeKey> | Readonly<InstanceKey> | Readonly<EntityProps>;\r\n\r\n/** @public */\r\nexport namespace Key { // eslint-disable-line @typescript-eslint/no-redeclare\r\n /** Check if the supplied key is a `NodeKey` */\r\n export function isNodeKey(key: Key): key is NodeKey {\r\n return !!(key as NodeKey).type;\r\n }\r\n\r\n /** Check if the supplied key is an `InstanceKey` */\r\n export function isInstanceKey(key: Key): key is InstanceKey {\r\n return !!(key as InstanceKey).className && !!(key as InstanceKey).id;\r\n }\r\n\r\n /** Check if the supplied key is an `EntityProps` */\r\n export function isEntityProps(key: Key): key is EntityProps {\r\n return !!(key as EntityProps).classFullName && !!(key as EntityProps).id;\r\n }\r\n}\r\n\r\n/**\r\n * A type for multiple keys that identify something in iModel.js application\r\n * @public\r\n */\r\nexport type Keys = ReadonlyArray<Key> | Readonly<KeySet>;\r\n\r\n/**\r\n * A data structure of serialized [[KeySet]]\r\n * @public\r\n */\r\nexport interface KeySetJSON {\r\n /** JSON representation of a list of instance keys */\r\n instanceKeys: Array<[string, string]>;\r\n /** An array of serialized node keys */\r\n nodeKeys: NodeKeyJSON[];\r\n}\r\n\r\n/**\r\n * A class that holds multiple [[Key]] objects. It's basically\r\n * used as a container that holds multiple keys of different types.\r\n *\r\n * @public\r\n */\r\nexport class KeySet {\r\n // note: all keys are stored as strings because we need ability to find them by value\r\n private _instanceKeys: Map<string, Set<string>>; // lower case class name => instance ids\r\n private _lowerCaseMap: Map<string, string>; // lower case class name => most recent class name\r\n private _nodeKeys: Set<string>;\r\n private _guid!: GuidString;\r\n\r\n /**\r\n * Creates an instance of KeySet.\r\n * @param source Optional source to initialize from.\r\n */\r\n constructor(source?: Keys) {\r\n this._instanceKeys = new Map();\r\n this._lowerCaseMap = new Map();\r\n this._nodeKeys = new Set();\r\n this.recalculateGuid();\r\n if (source)\r\n this.add(source);\r\n }\r\n\r\n private recalculateGuid() {\r\n // empty keyset should have empty guid, otherwise use a random guid value\r\n this._guid = this.isEmpty ? Guid.empty : Guid.createValue();\r\n }\r\n\r\n /**\r\n * Get a GUID that identifies changes in this keyset. The value\r\n * does not uniquely identify contents of the keyset, but it can be\r\n * used to check whether keyset has changed.\r\n */\r\n public get guid(): GuidString { return this._guid; }\r\n\r\n /**\r\n * Get a map of instance keys stored in this KeySet\r\n *\r\n * **Warning**: getting instance keys might be expensive for\r\n * large KeySets.\r\n */\r\n public get instanceKeys(): Map<string, Set<InstanceId>> {\r\n const map = new Map<string, Set<InstanceId>>();\r\n for (const entry of this._instanceKeys)\r\n map.set(this._lowerCaseMap.get(entry[\"0\"])!, new Set([...entry[\"1\"]].map((key: string) => Id64.fromJSON(key))));\r\n return map;\r\n }\r\n\r\n /**\r\n * Get instance keys count\r\n */\r\n public get instanceKeysCount(): number {\r\n let count = 0;\r\n this._instanceKeys.forEach((set: Set<string>) => count += set.size);\r\n return count;\r\n }\r\n\r\n /**\r\n * Get a set of node keys stored in this KeySet\r\n *\r\n * **Warning**: getting node keys might be expensive for\r\n * large KeySets.\r\n */\r\n public get nodeKeys(): Set<NodeKey> {\r\n const set = new Set<NodeKey>();\r\n for (const serialized of this._nodeKeys) {\r\n const key = NodeKey.fromJSON(JSON.parse(serialized));\r\n set.add(key);\r\n }\r\n return set;\r\n }\r\n\r\n /**\r\n * Get node keys count\r\n */\r\n public get nodeKeysCount(): number {\r\n return this._nodeKeys.size;\r\n }\r\n\r\n private isKeySet(set: Keys | Key): set is Readonly<KeySet> {\r\n return !!(set as KeySet)._nodeKeys && !!(set as KeySet)._instanceKeys;\r\n }\r\n\r\n private isKeysArray(keys: Keys | Key): keys is ReadonlyArray<Key> {\r\n return Array.isArray(keys);\r\n }\r\n\r\n /**\r\n * Clear this KeySet.\r\n * @returns itself\r\n */\r\n public clear(): KeySet {\r\n if (this.isEmpty)\r\n return this;\r\n\r\n this._instanceKeys = new Map();\r\n this._lowerCaseMap = new Map();\r\n this._nodeKeys = new Set();\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n private addKeySet(keyset: Readonly<KeySet>, pred?: (key: Key) => boolean): void {\r\n for (const key of (keyset as any)._nodeKeys) {\r\n if (!pred || pred(NodeKey.fromJSON(JSON.parse(key))))\r\n this._nodeKeys.add(key);\r\n }\r\n for (const entry of (keyset as any)._instanceKeys) {\r\n let set = this._instanceKeys.get(entry[\"0\"]);\r\n const className = (keyset as KeySet)._lowerCaseMap.get(entry[\"0\"])!;\r\n if (!set) {\r\n set = new Set();\r\n this._instanceKeys.set(entry[\"0\"], set);\r\n this._lowerCaseMap.set(entry[\"0\"], className);\r\n }\r\n entry[\"1\"].forEach((id: Id64String) => {\r\n if (!pred || pred({ className, id }))\r\n set!.add(id);\r\n });\r\n }\r\n }\r\n\r\n private addKeySetJSON(keyset: Readonly<KeySetJSON>): void {\r\n for (const key of keyset.nodeKeys)\r\n this._nodeKeys.add(JSON.stringify(key));\r\n for (const entry of keyset.instanceKeys) {\r\n const lcClassName = entry[\"0\"].toLowerCase();\r\n const idsJson: string | Id64String[] = entry[\"1\"];\r\n const ids: Set<Id64String> =\r\n typeof idsJson === \"string\"\r\n ? idsJson === Id64.invalid\r\n ? new Set([Id64.invalid])\r\n : CompressedId64Set.decompressSet(idsJson)\r\n : new Set(idsJson);\r\n this._instanceKeys.set(lcClassName, ids);\r\n this._lowerCaseMap.set(lcClassName, entry[\"0\"]);\r\n }\r\n }\r\n\r\n /**\r\n * Add a key or keys to this KeySet.\r\n * @param value A key or keys to add.\r\n * @param pred An optional predicate function that indicates whether a key should be added\r\n * @returns itself\r\n */\r\n public add(value: Keys | Key, pred?: (key: Key) => boolean): KeySet {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n const sizeBefore = this.size;\r\n if (this.isKeySet(value)) {\r\n this.addKeySet(value, pred);\r\n } else if (this.isKeysArray(value)) {\r\n value.forEach((key) => this.add(key, pred));\r\n } else if (!pred || pred(value)) {\r\n if (Key.isEntityProps(value)) {\r\n this.add({ className: value.classFullName, id: Id64.fromJSON(value.id) } as InstanceKey);\r\n } else if (Key.isInstanceKey(value)) {\r\n const lcClassName = value.className.toLowerCase();\r\n if (!this._instanceKeys.has(lcClassName)) {\r\n this._instanceKeys.set(lcClassName, new Set());\r\n this._lowerCaseMap.set(lcClassName, value.className);\r\n }\r\n this._lowerCaseMap.set(lcClassName, value.className);\r\n this._instanceKeys.get(lcClassName)!.add(value.id);\r\n } else if (Key.isNodeKey(value)) {\r\n this._nodeKeys.add(JSON.stringify(value));\r\n } else {\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n }\r\n if (this.size !== sizeBefore)\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n private deleteKeySet(keyset: Readonly<KeySet>): void {\r\n for (const key of (keyset as any)._nodeKeys)\r\n this._nodeKeys.delete(key);\r\n for (const entry of (keyset as any)._instanceKeys) {\r\n const set = this._instanceKeys.get(entry[\"0\"].toLowerCase());\r\n if (set) {\r\n entry[\"1\"].forEach((key: string) => {\r\n set.delete(key);\r\n });\r\n }\r\n }\r\n }\r\n\r\n /**\r\n * Deletes a key or keys from this KeySet.\r\n * @param value A key or keys to delete.\r\n * @returns itself\r\n */\r\n public delete(value: Keys | Key): KeySet {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n const sizeBefore = this.size;\r\n if (this.isKeySet(value)) {\r\n this.deleteKeySet(value);\r\n } else if (this.isKeysArray(value)) {\r\n for (const key of value)\r\n this.delete(key);\r\n } else if (Key.isEntityProps(value)) {\r\n this.delete({ className: value.classFullName, id: value.id! } as InstanceKey);\r\n } else if (Key.isInstanceKey(value)) {\r\n const set = this._instanceKeys.get(value.className.toLowerCase());\r\n if (set)\r\n set.delete(value.id);\r\n } else if (Key.isNodeKey(value)) {\r\n this._nodeKeys.delete(JSON.stringify(value));\r\n } else {\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n if (this.size !== sizeBefore)\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains the specified key.\r\n * @param value The key to check.\r\n */\r\n public has(value: Key): boolean {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n if (Key.isEntityProps(value))\r\n return this.has({ className: value.classFullName, id: value.id! } as InstanceKey);\r\n if (Key.isInstanceKey(value)) {\r\n const set = this._instanceKeys.get(value.className.toLowerCase());\r\n return !!(set && set.has(value.id));\r\n }\r\n if (Key.isNodeKey(value))\r\n return this._nodeKeys.has(JSON.stringify(value));\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n\r\n private hasKeySet(readonlyKeys: Readonly<KeySet>, checkType: \"all\" | \"any\"): boolean {\r\n // note: cast-away read-onlyness to access private members...\r\n const keys = readonlyKeys as KeySet;\r\n\r\n if (checkType === \"all\") {\r\n if (this._nodeKeys.size < keys._nodeKeys.size || this._instanceKeys.size < keys._instanceKeys.size)\r\n return false;\r\n if ([...keys._nodeKeys].some((key) => !this._nodeKeys.has(key)))\r\n return false;\r\n for (const otherEntry of keys._instanceKeys) {\r\n const thisEntryKeys = this._instanceKeys.get(otherEntry[\"0\"].toLowerCase());\r\n if (!thisEntryKeys || thisEntryKeys.size < otherEntry[\"1\"].size)\r\n return false;\r\n if ([...otherEntry[\"1\"]].some((key) => !thisEntryKeys.has(key)))\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n // \"any\" check type\r\n if ([...keys._nodeKeys].some((key) => this._nodeKeys.has(key)))\r\n return true;\r\n for (const otherEntry of keys._instanceKeys) {\r\n const thisEntryKeys = this._instanceKeys.get(otherEntry[\"0\"].toLowerCase());\r\n if (thisEntryKeys && [...otherEntry[\"1\"]].some((key) => thisEntryKeys.has(key)))\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n private hasKeysArray(keys: ReadonlyArray<Key>, checkType: \"all\" | \"any\"): boolean {\r\n if (checkType === \"all\") {\r\n if (this.size < keys.length)\r\n return false;\r\n for (const key of keys) {\r\n if (!this.has(key))\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n // \"any\" check type\r\n for (const key of keys) {\r\n if (this.has(key))\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains all the specified keys.\r\n * @param keys The keys to check.\r\n */\r\n public hasAll(keys: Keys): boolean {\r\n if (!keys)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);\r\n if (this.isKeySet(keys))\r\n return this.hasKeySet(keys, \"all\");\r\n if (this.isKeysArray(keys))\r\n return this.hasKeysArray(keys, \"all\");\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains any of the specified keys.\r\n * @param keys The keys to check.\r\n */\r\n public hasAny(keys: Keys): boolean {\r\n if (!keys)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);\r\n if (this.isKeySet(keys))\r\n return this.hasKeySet(keys, \"any\");\r\n if (this.isKeysArray(keys))\r\n return this.hasKeysArray(keys, \"any\");\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);\r\n }\r\n\r\n /**\r\n * Get the number of keys stored in this KeySet.\r\n */\r\n public get size(): number {\r\n const nodeKeysCount = this._nodeKeys.size;\r\n let instanceIdsCount = 0;\r\n for (const set of this._instanceKeys.values())\r\n instanceIdsCount += set.size;\r\n return nodeKeysCount + instanceIdsCount;\r\n }\r\n\r\n /**\r\n * Is this KeySet currently empty.\r\n */\r\n public get isEmpty(): boolean {\r\n return 0 === this.size;\r\n }\r\n\r\n /** Iterate over all keys in this keyset. */\r\n public some(callback: (key: Key) => boolean) {\r\n for (const entry of this._instanceKeys) {\r\n const className = this._lowerCaseMap.get(entry[\"0\"].toLowerCase())!;\r\n if (some(entry[1], (id: Id64String) => callback({ className, id })))\r\n return true;\r\n }\r\n return some(this._nodeKeys, (serializedKey: string) => callback(NodeKey.fromJSON(JSON.parse(serializedKey))));\r\n }\r\n\r\n /** Iterate over all keys in this keyset. */\r\n public forEach(callback: (key: InstanceKey | NodeKey, index: number) => void) {\r\n let index = 0;\r\n this._instanceKeys.forEach((ids: Set<Id64String>, className: string) => {\r\n const recentClassName = this._lowerCaseMap.get(className.toLowerCase())!;\r\n ids.forEach((id: Id64String) => callback({ className: recentClassName, id }, index++));\r\n });\r\n this._nodeKeys.forEach((serializedKey: string) => {\r\n callback(NodeKey.fromJSON(JSON.parse(serializedKey)), index++);\r\n });\r\n }\r\n\r\n /** Iterate over all keys in this keyset in batches */\r\n public forEachBatch(batchSize: number, callback: (batch: KeySet, index: number) => void) {\r\n const size = this.size;\r\n const count = Math.ceil(size / batchSize);\r\n if (1 === count) {\r\n callback(this, 0);\r\n return;\r\n }\r\n let batch = new KeySet();\r\n let batchIndex = 0;\r\n let currBatchSize = 0;\r\n this.forEach((key, index) => {\r\n batch.add(key);\r\n ++currBatchSize;\r\n if (currBatchSize === batchSize || index === (size - 1)) {\r\n callback(batch, batchIndex++);\r\n batch = new KeySet();\r\n currBatchSize = 0;\r\n }\r\n });\r\n }\r\n\r\n /**\r\n * Serializes this KeySet to JSON\r\n * @public\r\n */\r\n public toJSON(): KeySetJSON {\r\n const instanceKeys: [string, string][] = [];\r\n for (const entry of this._instanceKeys.entries()) {\r\n if (entry[\"1\"].size > 0) {\r\n const className = this._lowerCaseMap.get(entry[\"0\"].toLowerCase());\r\n const compressedIds = CompressedId64Set.sortAndCompress(entry[\"1\"]);\r\n instanceKeys.push([className!, compressedIds.length > 0 ? compressedIds : Id64.invalid]);\r\n }\r\n }\r\n const nodeKeys: NodeKeyJSON[] = [];\r\n for (const serializedKey of this._nodeKeys.values())\r\n nodeKeys.push(JSON.parse(serializedKey));\r\n return {\r\n instanceKeys,\r\n nodeKeys,\r\n };\r\n }\r\n\r\n /**\r\n * Creates a KeySet from JSON\r\n * @public\r\n */\r\n public static fromJSON(json: KeySetJSON): KeySet {\r\n const keyset = new KeySet();\r\n keyset.addKeySetJSON(json);\r\n return keyset;\r\n }\r\n}\r\n\r\nconst some = <TItem>(set: Set<TItem>, cb: (item: TItem) => boolean) => {\r\n for (const item of set) {\r\n if (cb(item))\r\n return true;\r\n }\r\n return false;\r\n};\r\n"]}
1
+ {"version":3,"file":"KeySet.js","sourceRoot":"","sources":["../../../src/presentation-common/KeySet.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH,OAAO,EAAE,iBAAiB,EAAE,IAAI,EAAc,IAAI,EAAc,MAAM,qBAAqB,CAAC;AAG5F,OAAO,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAChE,OAAO,EAAE,OAAO,EAAe,MAAM,iBAAiB,CAAC;AAQvD,cAAc;AAC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,CAAC,GAAG,CAAC,CAAC,CAAC;gBACpE,YAAY,CAAC,IAAI,CAAC,CAAC,SAAU,EAAE,aAAa,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;aAC1F;SACF;QACD,mDAAmD;QACnD,MAAM,QAAQ,GAAkB,EAAE,CAAC;QACnC,KAAK,MAAM,aAAa,IAAI,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE;YACjD,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC;QAC3C,OAAO;YACL,YAAY;YACZ,QAAQ;SACT,CAAC;IACJ,CAAC;IAED;;;OAGG;IACI,MAAM,CAAC,QAAQ,CAAC,IAAgB;QACrC,MAAM,MAAM,GAAG,IAAI,MAAM,EAAE,CAAC;QAC5B,MAAM,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC;QAC3B,OAAO,MAAM,CAAC;IAChB,CAAC;CACF;AAED,MAAM,IAAI,GAAG,CAAQ,GAAe,EAAE,EAA4B,EAAE,EAAE;IACpE,KAAK,MAAM,IAAI,IAAI,GAAG,EAAE;QACtB,IAAI,EAAE,CAAC,IAAI,CAAC;YACV,OAAO,IAAI,CAAC;KACf;IACD,OAAO,KAAK,CAAC;AACf,CAAC,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Core\r\n */\r\n\r\nimport { CompressedId64Set, Guid, GuidString, Id64, Id64String } from \"@itwin/core-bentley\";\r\nimport { EntityProps } from \"@itwin/core-common\";\r\nimport { InstanceId, InstanceKey } from \"./EC\";\r\nimport { PresentationError, PresentationStatus } from \"./Error\";\r\nimport { NodeKey, NodeKeyJSON } from \"./hierarchy/Key\";\r\n\r\n/**\r\n * A single key that identifies something in an iTwin.js application\r\n * @public\r\n */\r\nexport type Key = Readonly<NodeKey> | Readonly<InstanceKey> | Readonly<EntityProps>;\r\n\r\n/** @public */\r\nexport namespace Key { // eslint-disable-line @typescript-eslint/no-redeclare\r\n /** Check if the supplied key is a `NodeKey` */\r\n export function isNodeKey(key: Key): key is NodeKey {\r\n return !!(key as NodeKey).type;\r\n }\r\n\r\n /** Check if the supplied key is an `InstanceKey` */\r\n export function isInstanceKey(key: Key): key is InstanceKey {\r\n return !!(key as InstanceKey).className && !!(key as InstanceKey).id;\r\n }\r\n\r\n /** Check if the supplied key is an `EntityProps` */\r\n export function isEntityProps(key: Key): key is EntityProps {\r\n return !!(key as EntityProps).classFullName && !!(key as EntityProps).id;\r\n }\r\n}\r\n\r\n/**\r\n * A type for multiple keys that identify something in iModel.js application\r\n * @public\r\n */\r\nexport type Keys = ReadonlyArray<Key> | Readonly<KeySet>;\r\n\r\n/**\r\n * A data structure of serialized [[KeySet]]\r\n * @public\r\n */\r\nexport interface KeySetJSON {\r\n /** JSON representation of a list of instance keys */\r\n instanceKeys: Array<[string, string]>;\r\n /** An array of serialized node keys */\r\n // eslint-disable-next-line deprecation/deprecation\r\n nodeKeys: NodeKeyJSON[];\r\n}\r\n\r\n/**\r\n * A class that holds multiple [[Key]] objects. It's basically\r\n * used as a container that holds multiple keys of different types.\r\n *\r\n * @public\r\n */\r\nexport class KeySet {\r\n // note: all keys are stored as strings because we need ability to find them by value\r\n private _instanceKeys: Map<string, Set<string>>; // lower case class name => instance ids\r\n private _lowerCaseMap: Map<string, string>; // lower case class name => most recent class name\r\n private _nodeKeys: Set<string>;\r\n private _guid!: GuidString;\r\n\r\n /**\r\n * Creates an instance of KeySet.\r\n * @param source Optional source to initialize from.\r\n */\r\n constructor(source?: Keys) {\r\n this._instanceKeys = new Map();\r\n this._lowerCaseMap = new Map();\r\n this._nodeKeys = new Set();\r\n this.recalculateGuid();\r\n if (source)\r\n this.add(source);\r\n }\r\n\r\n private recalculateGuid() {\r\n // empty keyset should have empty guid, otherwise use a random guid value\r\n this._guid = this.isEmpty ? Guid.empty : Guid.createValue();\r\n }\r\n\r\n /**\r\n * Get a GUID that identifies changes in this keyset. The value\r\n * does not uniquely identify contents of the keyset, but it can be\r\n * used to check whether keyset has changed.\r\n */\r\n public get guid(): GuidString { return this._guid; }\r\n\r\n /**\r\n * Get a map of instance keys stored in this KeySet\r\n *\r\n * **Warning**: getting instance keys might be expensive for\r\n * large KeySets.\r\n */\r\n public get instanceKeys(): Map<string, Set<InstanceId>> {\r\n const map = new Map<string, Set<InstanceId>>();\r\n for (const entry of this._instanceKeys)\r\n map.set(this._lowerCaseMap.get(entry[\"0\"])!, new Set([...entry[\"1\"]].map((key: string) => Id64.fromJSON(key))));\r\n return map;\r\n }\r\n\r\n /**\r\n * Get instance keys count\r\n */\r\n public get instanceKeysCount(): number {\r\n let count = 0;\r\n this._instanceKeys.forEach((set: Set<string>) => count += set.size);\r\n return count;\r\n }\r\n\r\n /**\r\n * Get a set of node keys stored in this KeySet\r\n *\r\n * **Warning**: getting node keys might be expensive for\r\n * large KeySets.\r\n */\r\n public get nodeKeys(): Set<NodeKey> {\r\n const set = new Set<NodeKey>();\r\n for (const serialized of this._nodeKeys) {\r\n // eslint-disable-next-line deprecation/deprecation\r\n const key = NodeKey.fromJSON(JSON.parse(serialized));\r\n set.add(key);\r\n }\r\n return set;\r\n }\r\n\r\n /**\r\n * Get node keys count\r\n */\r\n public get nodeKeysCount(): number {\r\n return this._nodeKeys.size;\r\n }\r\n\r\n private isKeySet(set: Keys | Key): set is Readonly<KeySet> {\r\n return !!(set as KeySet)._nodeKeys && !!(set as KeySet)._instanceKeys;\r\n }\r\n\r\n private isKeysArray(keys: Keys | Key): keys is ReadonlyArray<Key> {\r\n return Array.isArray(keys);\r\n }\r\n\r\n /**\r\n * Clear this KeySet.\r\n * @returns itself\r\n */\r\n public clear(): KeySet {\r\n if (this.isEmpty)\r\n return this;\r\n\r\n this._instanceKeys = new Map();\r\n this._lowerCaseMap = new Map();\r\n this._nodeKeys = new Set();\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n private addKeySet(keyset: Readonly<KeySet>, pred?: (key: Key) => boolean): void {\r\n for (const key of (keyset as any)._nodeKeys) {\r\n // eslint-disable-next-line deprecation/deprecation\r\n if (!pred || pred(NodeKey.fromJSON(JSON.parse(key))))\r\n this._nodeKeys.add(key);\r\n }\r\n for (const entry of (keyset as any)._instanceKeys) {\r\n let set = this._instanceKeys.get(entry[\"0\"]);\r\n const className = (keyset as KeySet)._lowerCaseMap.get(entry[\"0\"])!;\r\n if (!set) {\r\n set = new Set();\r\n this._instanceKeys.set(entry[\"0\"], set);\r\n this._lowerCaseMap.set(entry[\"0\"], className);\r\n }\r\n entry[\"1\"].forEach((id: Id64String) => {\r\n if (!pred || pred({ className, id }))\r\n set!.add(id);\r\n });\r\n }\r\n }\r\n\r\n private addKeySetJSON(keyset: Readonly<KeySetJSON>): void {\r\n for (const key of keyset.nodeKeys)\r\n this._nodeKeys.add(JSON.stringify(key));\r\n for (const entry of keyset.instanceKeys) {\r\n const lcClassName = entry[\"0\"].toLowerCase();\r\n const idsJson: string | Id64String[] = entry[\"1\"];\r\n const ids: Set<Id64String> =\r\n typeof idsJson === \"string\"\r\n ? idsJson === Id64.invalid\r\n ? new Set([Id64.invalid])\r\n : CompressedId64Set.decompressSet(idsJson)\r\n : new Set(idsJson);\r\n this._instanceKeys.set(lcClassName, ids);\r\n this._lowerCaseMap.set(lcClassName, entry[\"0\"]);\r\n }\r\n }\r\n\r\n /**\r\n * Add a key or keys to this KeySet.\r\n * @param value A key or keys to add.\r\n * @param pred An optional predicate function that indicates whether a key should be added\r\n * @returns itself\r\n */\r\n public add(value: Keys | Key, pred?: (key: Key) => boolean): KeySet {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n const sizeBefore = this.size;\r\n if (this.isKeySet(value)) {\r\n this.addKeySet(value, pred);\r\n } else if (this.isKeysArray(value)) {\r\n value.forEach((key) => this.add(key, pred));\r\n } else if (!pred || pred(value)) {\r\n if (Key.isEntityProps(value)) {\r\n this.add({ className: value.classFullName, id: Id64.fromJSON(value.id) } as InstanceKey);\r\n } else if (Key.isInstanceKey(value)) {\r\n const lcClassName = value.className.toLowerCase();\r\n if (!this._instanceKeys.has(lcClassName)) {\r\n this._instanceKeys.set(lcClassName, new Set());\r\n this._lowerCaseMap.set(lcClassName, value.className);\r\n }\r\n this._lowerCaseMap.set(lcClassName, value.className);\r\n this._instanceKeys.get(lcClassName)!.add(value.id);\r\n } else if (Key.isNodeKey(value)) {\r\n this._nodeKeys.add(JSON.stringify(value));\r\n } else {\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n }\r\n if (this.size !== sizeBefore)\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n private deleteKeySet(keyset: Readonly<KeySet>): void {\r\n for (const key of (keyset as any)._nodeKeys)\r\n this._nodeKeys.delete(key);\r\n for (const entry of (keyset as any)._instanceKeys) {\r\n const set = this._instanceKeys.get(entry[\"0\"].toLowerCase());\r\n if (set) {\r\n entry[\"1\"].forEach((key: string) => {\r\n set.delete(key);\r\n });\r\n }\r\n }\r\n }\r\n\r\n /**\r\n * Deletes a key or keys from this KeySet.\r\n * @param value A key or keys to delete.\r\n * @returns itself\r\n */\r\n public delete(value: Keys | Key): KeySet {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n const sizeBefore = this.size;\r\n if (this.isKeySet(value)) {\r\n this.deleteKeySet(value);\r\n } else if (this.isKeysArray(value)) {\r\n for (const key of value)\r\n this.delete(key);\r\n } else if (Key.isEntityProps(value)) {\r\n this.delete({ className: value.classFullName, id: value.id! } as InstanceKey);\r\n } else if (Key.isInstanceKey(value)) {\r\n const set = this._instanceKeys.get(value.className.toLowerCase());\r\n if (set)\r\n set.delete(value.id);\r\n } else if (Key.isNodeKey(value)) {\r\n this._nodeKeys.delete(JSON.stringify(value));\r\n } else {\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n if (this.size !== sizeBefore)\r\n this.recalculateGuid();\r\n return this;\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains the specified key.\r\n * @param value The key to check.\r\n */\r\n public has(value: Key): boolean {\r\n if (!value)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n if (Key.isEntityProps(value))\r\n return this.has({ className: value.classFullName, id: value.id! } as InstanceKey);\r\n if (Key.isInstanceKey(value)) {\r\n const set = this._instanceKeys.get(value.className.toLowerCase());\r\n return !!(set && set.has(value.id));\r\n }\r\n if (Key.isNodeKey(value))\r\n return this._nodeKeys.has(JSON.stringify(value));\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);\r\n }\r\n\r\n private hasKeySet(readonlyKeys: Readonly<KeySet>, checkType: \"all\" | \"any\"): boolean {\r\n // note: cast-away read-onlyness to access private members...\r\n const keys = readonlyKeys as KeySet;\r\n\r\n if (checkType === \"all\") {\r\n if (this._nodeKeys.size < keys._nodeKeys.size || this._instanceKeys.size < keys._instanceKeys.size)\r\n return false;\r\n if ([...keys._nodeKeys].some((key) => !this._nodeKeys.has(key)))\r\n return false;\r\n for (const otherEntry of keys._instanceKeys) {\r\n const thisEntryKeys = this._instanceKeys.get(otherEntry[\"0\"].toLowerCase());\r\n if (!thisEntryKeys || thisEntryKeys.size < otherEntry[\"1\"].size)\r\n return false;\r\n if ([...otherEntry[\"1\"]].some((key) => !thisEntryKeys.has(key)))\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n // \"any\" check type\r\n if ([...keys._nodeKeys].some((key) => this._nodeKeys.has(key)))\r\n return true;\r\n for (const otherEntry of keys._instanceKeys) {\r\n const thisEntryKeys = this._instanceKeys.get(otherEntry[\"0\"].toLowerCase());\r\n if (thisEntryKeys && [...otherEntry[\"1\"]].some((key) => thisEntryKeys.has(key)))\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n private hasKeysArray(keys: ReadonlyArray<Key>, checkType: \"all\" | \"any\"): boolean {\r\n if (checkType === \"all\") {\r\n if (this.size < keys.length)\r\n return false;\r\n for (const key of keys) {\r\n if (!this.has(key))\r\n return false;\r\n }\r\n return true;\r\n }\r\n\r\n // \"any\" check type\r\n for (const key of keys) {\r\n if (this.has(key))\r\n return true;\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains all the specified keys.\r\n * @param keys The keys to check.\r\n */\r\n public hasAll(keys: Keys): boolean {\r\n if (!keys)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);\r\n if (this.isKeySet(keys))\r\n return this.hasKeySet(keys, \"all\");\r\n if (this.isKeysArray(keys))\r\n return this.hasKeysArray(keys, \"all\");\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);\r\n }\r\n\r\n /**\r\n * Check if this KeySet contains any of the specified keys.\r\n * @param keys The keys to check.\r\n */\r\n public hasAny(keys: Keys): boolean {\r\n if (!keys)\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);\r\n if (this.isKeySet(keys))\r\n return this.hasKeySet(keys, \"any\");\r\n if (this.isKeysArray(keys))\r\n return this.hasKeysArray(keys, \"any\");\r\n throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);\r\n }\r\n\r\n /**\r\n * Get the number of keys stored in this KeySet.\r\n */\r\n public get size(): number {\r\n const nodeKeysCount = this._nodeKeys.size;\r\n let instanceIdsCount = 0;\r\n for (const set of this._instanceKeys.values())\r\n instanceIdsCount += set.size;\r\n return nodeKeysCount + instanceIdsCount;\r\n }\r\n\r\n /**\r\n * Is this KeySet currently empty.\r\n */\r\n public get isEmpty(): boolean {\r\n return 0 === this.size;\r\n }\r\n\r\n /** Iterate over all keys in this keyset. */\r\n public some(callback: (key: Key) => boolean) {\r\n for (const entry of this._instanceKeys) {\r\n const className = this._lowerCaseMap.get(entry[\"0\"].toLowerCase())!;\r\n if (some(entry[1], (id: Id64String) => callback({ className, id })))\r\n return true;\r\n }\r\n // eslint-disable-next-line deprecation/deprecation\r\n return some(this._nodeKeys, (serializedKey: string) => callback(NodeKey.fromJSON(JSON.parse(serializedKey))));\r\n }\r\n\r\n /** Iterate over all keys in this keyset. */\r\n public forEach(callback: (key: InstanceKey | NodeKey, index: number) => void) {\r\n let index = 0;\r\n this._instanceKeys.forEach((ids: Set<Id64String>, className: string) => {\r\n const recentClassName = this._lowerCaseMap.get(className.toLowerCase())!;\r\n ids.forEach((id: Id64String) => callback({ className: recentClassName, id }, index++));\r\n });\r\n this._nodeKeys.forEach((serializedKey: string) => {\r\n // eslint-disable-next-line deprecation/deprecation\r\n callback(NodeKey.fromJSON(JSON.parse(serializedKey)), index++);\r\n });\r\n }\r\n\r\n /** Iterate over all keys in this keyset in batches */\r\n public forEachBatch(batchSize: number, callback: (batch: KeySet, index: number) => void) {\r\n const size = this.size;\r\n const count = Math.ceil(size / batchSize);\r\n if (1 === count) {\r\n callback(this, 0);\r\n return;\r\n }\r\n let batch = new KeySet();\r\n let batchIndex = 0;\r\n let currBatchSize = 0;\r\n this.forEach((key, index) => {\r\n batch.add(key);\r\n ++currBatchSize;\r\n if (currBatchSize === batchSize || index === (size - 1)) {\r\n callback(batch, batchIndex++);\r\n batch = new KeySet();\r\n currBatchSize = 0;\r\n }\r\n });\r\n }\r\n\r\n /**\r\n * Serializes this KeySet to JSON\r\n * @public\r\n */\r\n public toJSON(): KeySetJSON {\r\n const instanceKeys: [string, string][] = [];\r\n for (const entry of this._instanceKeys.entries()) {\r\n if (entry[\"1\"].size > 0) {\r\n const className = this._lowerCaseMap.get(entry[\"0\"].toLowerCase());\r\n const compressedIds = CompressedId64Set.sortAndCompress(entry[\"1\"]);\r\n instanceKeys.push([className!, compressedIds.length > 0 ? compressedIds : Id64.invalid]);\r\n }\r\n }\r\n // eslint-disable-next-line deprecation/deprecation\r\n const nodeKeys: NodeKeyJSON[] = [];\r\n for (const serializedKey of this._nodeKeys.values())\r\n nodeKeys.push(JSON.parse(serializedKey));\r\n return {\r\n instanceKeys,\r\n nodeKeys,\r\n };\r\n }\r\n\r\n /**\r\n * Creates a KeySet from JSON\r\n * @public\r\n */\r\n public static fromJSON(json: KeySetJSON): KeySet {\r\n const keyset = new KeySet();\r\n keyset.addKeySetJSON(json);\r\n return keyset;\r\n }\r\n}\r\n\r\nconst some = <TItem>(set: Set<TItem>, cb: (item: TItem) => boolean) => {\r\n for (const item of set) {\r\n if (cb(item))\r\n return true;\r\n }\r\n return false;\r\n};\r\n"]}
@@ -12,16 +12,23 @@ export interface LabelCompositeValue {
12
12
  /**
13
13
  * JSON representation of [[LabelCompositeValue]]
14
14
  * @public
15
+ * @deprecated in 3.x. Use [[LabelCompositeValue]].
15
16
  */
16
17
  export interface LabelCompositeValueJSON {
17
18
  separator: string;
18
- values: LabelDefinitionJSON[];
19
+ values: LabelDefinition[];
19
20
  }
20
21
  /** @public */
21
22
  export declare namespace LabelCompositeValue {
22
- /** Serialize given [[LabelCompositeValue]] to JSON */
23
+ /**
24
+ * Serialize given [[LabelCompositeValue]] to JSON
25
+ * @deprecated in 3.x. Use [[LabelCompositeValue]].
26
+ */
23
27
  function toJSON(compositeValue: LabelCompositeValue): LabelCompositeValueJSON;
24
- /** Deserialize [[LabelCompositeValue]] from JSON */
28
+ /**
29
+ * Deserialize [[LabelCompositeValue]] from JSON
30
+ * @deprecated in 3.x. Use [[LabelCompositeValue]].
31
+ */
25
32
  function fromJSON(json: LabelCompositeValueJSON): LabelCompositeValue;
26
33
  }
27
34
  /**
@@ -30,10 +37,11 @@ export declare namespace LabelCompositeValue {
30
37
  */
31
38
  export declare type LabelRawValue = string | number | boolean | LabelCompositeValue;
32
39
  /**
33
- * JSON representation of [[LabelRawValue]]
40
+ * JSON representation of [[LabelRawValue]]
34
41
  * @public
42
+ * @deprecated in 3.x. Use [[LabelRawValue]].
35
43
  */
36
- export declare type LabelRawValueJSON = string | number | boolean | LabelCompositeValueJSON;
44
+ export declare type LabelRawValueJSON = LabelRawValue;
37
45
  /**
38
46
  * Data structure that describes label definition.
39
47
  * @public
@@ -49,32 +57,32 @@ export interface LabelDefinition {
49
57
  /**
50
58
  * JSON representation of [[LabelDefinition]]
51
59
  * @public
60
+ * @deprecated in 3.x. Use [[LabelDefinition]].
52
61
  */
53
62
  export interface LabelDefinitionJSON {
54
63
  displayValue: string;
55
- rawValue: LabelRawValueJSON;
64
+ rawValue: LabelRawValue;
56
65
  typeName: string;
57
66
  }
58
67
  /** @public */
59
68
  export declare namespace LabelDefinition {
60
- /** Serialize given [[LabelDefinition]] to JSON */
69
+ /**
70
+ * Serialize given [[LabelDefinition]] to JSON
71
+ * @deprecated in 3.x. Use [[LabelDefinition]].
72
+ */
61
73
  function toJSON(labelDefinition: LabelDefinition): LabelDefinitionJSON;
62
- /** Deserialize [[LabelDefinition]] from JSON */
74
+ /**
75
+ * Deserialize [[LabelDefinition]] from JSON
76
+ * @deprecated in 3.x. Use [[LabelDefinition]].
77
+ */
63
78
  function fromJSON(json: LabelDefinitionJSON | string): LabelDefinition;
64
79
  /** @internal */
65
80
  const COMPOSITE_DEFINITION_TYPENAME = "composite";
66
- /**
67
- * Reviver function that can be used as a second argument for
68
- * `JSON.parse` method when parsing [[LabelDefinition]] objects.
69
- *
70
- * @internal
71
- */
72
- function reviver(key: string, value: any): any;
73
81
  /** @internal */
74
82
  function isCompositeDefinition(def: LabelDefinition): def is LabelDefinition & {
75
83
  rawValue: LabelCompositeValue;
76
84
  };
77
85
  /** @internal */
78
- function fromLabelString(label: string): LabelDefinitionJSON;
86
+ function fromLabelString(label: string): LabelDefinition;
79
87
  }
80
88
  //# sourceMappingURL=LabelDefinition.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"LabelDef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;;;GAIG;AACH,MAAM,WAAW,mBAAmB;IAClC,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,aAAa,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,cAAc;AACd,yBAAiB,eAAe,CAAC;IAC/B;;;OAGG;IAEH,SAAgB,MAAM,CAAC,eAAe,EAAE,eAAe,GAAG,mBAAmB,CAE5E;IAED;;;OAGG;IAEH,SAAgB,QAAQ,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM,GAAG,eAAe,CAI5E;IAED,gBAAgB;IACT,MAAM,6BAA6B,cAAc,CAAC;IAEzD,gBAAgB;IAEhB,SAAgB,qBAAqB,CAAC,GAAG,EAAE,eAAe,GAAG,GAAG,IAAI,eAAe,GAAG;QAAE,QAAQ,EAAE,mBAAmB,CAAA;KAAE,CAEtH;IAED,gBAAgB;IAChB,SAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,GAAG,eAAe,CAM9D;CACF"}
@@ -8,55 +8,52 @@
8
8
  /** @public */
9
9
  export var LabelCompositeValue;
10
10
  (function (LabelCompositeValue) {
11
- /** Serialize given [[LabelCompositeValue]] to JSON */
11
+ /**
12
+ * Serialize given [[LabelCompositeValue]] to JSON
13
+ * @deprecated in 3.x. Use [[LabelCompositeValue]].
14
+ */
15
+ // eslint-disable-next-line deprecation/deprecation
12
16
  function toJSON(compositeValue) {
13
- return { ...compositeValue, values: compositeValue.values.map(LabelDefinition.toJSON) };
17
+ return { ...compositeValue };
14
18
  }
15
19
  LabelCompositeValue.toJSON = toJSON;
16
- /** Deserialize [[LabelCompositeValue]] from JSON */
20
+ /**
21
+ * Deserialize [[LabelCompositeValue]] from JSON
22
+ * @deprecated in 3.x. Use [[LabelCompositeValue]].
23
+ */
24
+ // eslint-disable-next-line deprecation/deprecation
17
25
  function fromJSON(json) {
18
- return {
19
- ...json,
20
- values: json.values.map(LabelDefinition.fromJSON),
21
- };
26
+ return { ...json };
22
27
  }
23
28
  LabelCompositeValue.fromJSON = fromJSON;
24
29
  })(LabelCompositeValue || (LabelCompositeValue = {}));
25
30
  /** @public */
26
31
  export var LabelDefinition;
27
32
  (function (LabelDefinition) {
28
- /** Serialize given [[LabelDefinition]] to JSON */
33
+ /**
34
+ * Serialize given [[LabelDefinition]] to JSON
35
+ * @deprecated in 3.x. Use [[LabelDefinition]].
36
+ */
37
+ // eslint-disable-next-line deprecation/deprecation
29
38
  function toJSON(labelDefinition) {
30
- return {
31
- displayValue: labelDefinition.displayValue,
32
- typeName: labelDefinition.typeName,
33
- rawValue: isCompositeDefinition(labelDefinition) ? LabelCompositeValue.toJSON(labelDefinition.rawValue) : labelDefinition.rawValue,
34
- };
39
+ return { ...labelDefinition };
35
40
  }
36
41
  LabelDefinition.toJSON = toJSON;
37
- /** Deserialize [[LabelDefinition]] from JSON */
42
+ /**
43
+ * Deserialize [[LabelDefinition]] from JSON
44
+ * @deprecated in 3.x. Use [[LabelDefinition]].
45
+ */
46
+ // eslint-disable-next-line deprecation/deprecation
38
47
  function fromJSON(json) {
39
48
  if (typeof json === "string")
40
- return JSON.parse(json, reviver);
41
- return {
42
- ...json,
43
- rawValue: isCompositeDefinition(json) ? LabelCompositeValue.fromJSON(json.rawValue) : json.rawValue,
44
- };
49
+ return JSON.parse(json);
50
+ return { ...json };
45
51
  }
46
52
  LabelDefinition.fromJSON = fromJSON;
47
53
  /** @internal */
48
54
  LabelDefinition.COMPOSITE_DEFINITION_TYPENAME = "composite";
49
- /**
50
- * Reviver function that can be used as a second argument for
51
- * `JSON.parse` method when parsing [[LabelDefinition]] objects.
52
- *
53
- * @internal
54
- */
55
- function reviver(key, value) {
56
- return key === "" ? fromJSON(value) : value;
57
- }
58
- LabelDefinition.reviver = reviver;
59
55
  /** @internal */
56
+ // istanbul ignore next
60
57
  function isCompositeDefinition(def) {
61
58
  return def.typeName === LabelDefinition.COMPOSITE_DEFINITION_TYPENAME;
62
59
  }
@@ -1 +1 @@
1
- {"version":3,"file":"LabelDefinition.js","sour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AAC,CAAC,CAAC,CAAC,mBAAmB,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,QAAQ;SACpG,CAAC;IACJ,CAAC;IAPe,wBAAQ,WAOvB,CAAA;IAED,gBAAgB;IACH,6CAA6B,GAAG,WAAW,CAAC;IAEzD;;;;;OAKG;IACH,SAAgB,OAAO,CAAC,GAAW,EAAE,KAAU;QAC7C,OAAO,GAAG,KAAK,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC;IAC9C,CAAC;IAFe,uBAAO,UAEtB,CAAA;IAED,gBAAgB;IAChB,SAAgB,qBAAqB,CAAC,GAAoB;QACxD,OAAO,GAAG,CAAC,QAAQ,KAAK,gBAAA,6BAA6B,CAAC;IACxD,CAAC;IAFe,qCAAqB,wBAEpC,CAAA;IAED,gBAAgB;IAChB,SAAgB,eAAe,CAAC,KAAa;QAC3C,OAAO;YACL,YAAY,EAAE,KAAK;YACnB,QAAQ,EAAE,KAAK;YACf,QAAQ,EAAE,QAAQ;SACnB,CAAC;IACJ,CAAC;IANe,+BAAe,kBAM9B,CAAA;AACH,CAAC,EA9CgB,eAAe,KAAf,eAAe,QA8C/B","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Hierarchies\r\n */\r\n\r\n/**\r\n * Data structure that describes raw composite label value.\r\n * @public\r\n */\r\nexport interface LabelCompositeValue {\r\n separator: string;\r\n values: LabelDefinition[];\r\n}\r\n\r\n/**\r\n * JSON representation of [[LabelCompositeValue]]\r\n * @public\r\n */\r\nexport interface LabelCompositeValueJSON {\r\n separator: string;\r\n values: LabelDefinitionJSON[];\r\n}\r\n\r\n/** @public */\r\nexport namespace LabelCompositeValue {\r\n /** Serialize given [[LabelCompositeValue]] to JSON */\r\n export function toJSON(compositeValue: LabelCompositeValue): LabelCompositeValueJSON {\r\n return { ...compositeValue, values: compositeValue.values.map(LabelDefinition.toJSON) };\r\n }\r\n\r\n /** Deserialize [[LabelCompositeValue]] from JSON */\r\n export function fromJSON(json: LabelCompositeValueJSON): LabelCompositeValue {\r\n return {\r\n ...json,\r\n values: json.values.map(LabelDefinition.fromJSON),\r\n };\r\n }\r\n}\r\n\r\n/**\r\n * Type definition of label raw value.\r\n * @public\r\n */\r\nexport type LabelRawValue = string | number | boolean | LabelCompositeValue;\r\n\r\n/**\r\n * JSON representation of [[LabelRawValue]]\r\n * @public\r\n */\r\nexport type LabelRawValueJSON = string | number | boolean | LabelCompositeValueJSON;\r\n\r\n/**\r\n * Data structure that describes label definition.\r\n * @public\r\n */\r\nexport interface LabelDefinition {\r\n /** Display value of label */\r\n displayValue: string;\r\n /** Raw value of label */\r\n rawValue: LabelRawValue;\r\n /** Type name of raw value */\r\n typeName: string;\r\n}\r\n\r\n/**\r\n * JSON representation of [[LabelDefinition]]\r\n * @public\r\n */\r\nexport interface LabelDefinitionJSON {\r\n displayValue: string;\r\n rawValue: LabelRawValueJSON;\r\n typeName: string;\r\n}\r\n\r\n/** @public */\r\nexport namespace LabelDefinition {\r\n /** Serialize given [[LabelDefinition]] to JSON */\r\n export function toJSON(labelDefinition: LabelDefinition): LabelDefinitionJSON {\r\n return {\r\n displayValue: labelDefinition.displayValue,\r\n typeName: labelDefinition.typeName,\r\n rawValue: isCompositeDefinition(labelDefinition) ? LabelCompositeValue.toJSON(labelDefinition.rawValue) : labelDefinition.rawValue,\r\n };\r\n }\r\n\r\n /** Deserialize [[LabelDefinition]] from JSON */\r\n export function fromJSON(json: LabelDefinitionJSON | string): LabelDefinition {\r\n if (typeof json === \"string\")\r\n return JSON.parse(json, reviver);\r\n return {\r\n ...json,\r\n rawValue: isCompositeDefinition(json) ? LabelCompositeValue.fromJSON(json.rawValue) : json.rawValue,\r\n };\r\n }\r\n\r\n /** @internal */\r\n export const COMPOSITE_DEFINITION_TYPENAME = \"composite\";\r\n\r\n /**\r\n * Reviver function that can be used as a second argument for\r\n * `JSON.parse` method when parsing [[LabelDefinition]] objects.\r\n *\r\n * @internal\r\n */\r\n export function reviver(key: string, value: any): any {\r\n return key === \"\" ? fromJSON(value) : value;\r\n }\r\n\r\n /** @internal */\r\n export function isCompositeDefinition(def: LabelDefinition): def is LabelDefinition & { rawValue: LabelCompositeValue } {\r\n return def.typeName === COMPOSITE_DEFINITION_TYPENAME;\r\n }\r\n\r\n /** @internal */\r\n export function fromLabelString(label: string): LabelDefinitionJSON {\r\n return {\r\n displayValue: label,\r\n rawValue: label,\r\n typeName: \"string\",\r\n };\r\n }\r\n}\r\n"]}
1
+ {"version":3,"file":"LabelDefinition.js","sourceRoot":"","sources":["../../../src/presentation-common/LabelDefinition.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAqBH,cAAc;AACd,MAAM,KAAW,mBAAmB,CAkBnC;AAlBD,WAAiB,mBAAmB;IAClC;;;OAGG;IACH,mDAAmD;IACnD,SAAgB,MAAM,CAAC,cAAmC;QACxD,OAAO,EAAE,GAAG,cAAc,EAAE,CAAC;IAC/B,CAAC;IAFe,0BAAM,SAErB,CAAA;IAED;;;OAGG;IACH,mDAAmD;IACnD,SAAgB,QAAQ,CAAC,IAA6B;QACpD,OAAO,EAAE,GAAG,IAAI,EAAE,CAAC;IACrB,CAAC;IAFe,4BAAQ,WAEvB,CAAA;AACH,CAAC,EAlBgB,mBAAmB,KAAnB,mBAAmB,QAkBnC;AAuCD,cAAc;AACd,MAAM,KAAW,eAAe,CAsC/B;AAtCD,WAAiB,eAAe;IAC9B;;;OAGG;IACH,mDAAmD;IACnD,SAAgB,MAAM,CAAC,eAAgC;QACrD,OAAO,EAAE,GAAG,eAAe,EAAE,CAAC;IAChC,CAAC;IAFe,sBAAM,SAErB,CAAA;IAED;;;OAGG;IACH,mDAAmD;IACnD,SAAgB,QAAQ,CAAC,IAAkC;QACzD,IAAI,OAAO,IAAI,KAAK,QAAQ;YAC1B,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;QAC1B,OAAO,EAAE,GAAG,IAAI,EAAE,CAAC;IACrB,CAAC;IAJe,wBAAQ,WAIvB,CAAA;IAED,gBAAgB;IACH,6CAA6B,GAAG,WAAW,CAAC;IAEzD,gBAAgB;IAChB,uBAAuB;IACvB,SAAgB,qBAAqB,CAAC,GAAoB;QACxD,OAAO,GAAG,CAAC,QAAQ,KAAK,gBAAA,6BAA6B,CAAC;IACxD,CAAC;IAFe,qCAAqB,wBAEpC,CAAA;IAED,gBAAgB;IAChB,SAAgB,eAAe,CAAC,KAAa;QAC3C,OAAO;YACL,YAAY,EAAE,KAAK;YACnB,QAAQ,EAAE,KAAK;YACf,QAAQ,EAAE,QAAQ;SACnB,CAAC;IACJ,CAAC;IANe,+BAAe,kBAM9B,CAAA;AACH,CAAC,EAtCgB,eAAe,KAAf,eAAe,QAsC/B","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Hierarchies\r\n */\r\n\r\n/**\r\n * Data structure that describes raw composite label value.\r\n * @public\r\n */\r\nexport interface LabelCompositeValue {\r\n separator: string;\r\n values: LabelDefinition[];\r\n}\r\n\r\n/**\r\n * JSON representation of [[LabelCompositeValue]]\r\n * @public\r\n * @deprecated in 3.x. Use [[LabelCompositeValue]].\r\n */\r\nexport interface LabelCompositeValueJSON {\r\n separator: string;\r\n values: LabelDefinition[];\r\n}\r\n\r\n/** @public */\r\nexport namespace LabelCompositeValue {\r\n /**\r\n * Serialize given [[LabelCompositeValue]] to JSON\r\n * @deprecated in 3.x. Use [[LabelCompositeValue]].\r\n */\r\n // eslint-disable-next-line deprecation/deprecation\r\n export function toJSON(compositeValue: LabelCompositeValue): LabelCompositeValueJSON {\r\n return { ...compositeValue };\r\n }\r\n\r\n /**\r\n * Deserialize [[LabelCompositeValue]] from JSON\r\n * @deprecated in 3.x. Use [[LabelCompositeValue]].\r\n */\r\n // eslint-disable-next-line deprecation/deprecation\r\n export function fromJSON(json: LabelCompositeValueJSON): LabelCompositeValue {\r\n return { ...json };\r\n }\r\n}\r\n\r\n/**\r\n * Type definition of label raw value.\r\n * @public\r\n */\r\nexport type LabelRawValue = string | number | boolean | LabelCompositeValue;\r\n\r\n/**\r\n * JSON representation of [[LabelRawValue]]\r\n * @public\r\n * @deprecated in 3.x. Use [[LabelRawValue]].\r\n */\r\nexport type LabelRawValueJSON = LabelRawValue;\r\n\r\n/**\r\n * Data structure that describes label definition.\r\n * @public\r\n */\r\nexport interface LabelDefinition {\r\n /** Display value of label */\r\n displayValue: string;\r\n /** Raw value of label */\r\n rawValue: LabelRawValue;\r\n /** Type name of raw value */\r\n typeName: string;\r\n}\r\n\r\n/**\r\n * JSON representation of [[LabelDefinition]]\r\n * @public\r\n * @deprecated in 3.x. Use [[LabelDefinition]].\r\n */\r\nexport interface LabelDefinitionJSON {\r\n displayValue: string;\r\n rawValue: LabelRawValue;\r\n typeName: string;\r\n}\r\n\r\n/** @public */\r\nexport namespace LabelDefinition {\r\n /**\r\n * Serialize given [[LabelDefinition]] to JSON\r\n * @deprecated in 3.x. Use [[LabelDefinition]].\r\n */\r\n // eslint-disable-next-line deprecation/deprecation\r\n export function toJSON(labelDefinition: LabelDefinition): LabelDefinitionJSON {\r\n return { ...labelDefinition };\r\n }\r\n\r\n /**\r\n * Deserialize [[LabelDefinition]] from JSON\r\n * @deprecated in 3.x. Use [[LabelDefinition]].\r\n */\r\n // eslint-disable-next-line deprecation/deprecation\r\n export function fromJSON(json: LabelDefinitionJSON | string): LabelDefinition {\r\n if (typeof json === \"string\")\r\n return JSON.parse(json);\r\n return { ...json };\r\n }\r\n\r\n /** @internal */\r\n export const COMPOSITE_DEFINITION_TYPENAME = \"composite\";\r\n\r\n /** @internal */\r\n // istanbul ignore next\r\n export function isCompositeDefinition(def: LabelDefinition): def is LabelDefinition & { rawValue: LabelCompositeValue } {\r\n return def.typeName === COMPOSITE_DEFINITION_TYPENAME;\r\n }\r\n\r\n /** @internal */\r\n export function fromLabelString(label: string): LabelDefinition {\r\n return {\r\n displayValue: label,\r\n rawValue: label,\r\n typeName: \"string\",\r\n };\r\n }\r\n}\r\n"]}
@@ -1,7 +1,7 @@
1
1
  /** @packageDocumentation
2
2
  * @module Core
3
3
  */
4
- import { NodeKeyJSON } from "./hierarchy/Key";
4
+ import { NodeKey } from "./hierarchy/Key";
5
5
  import { RulesetVariableJSON } from "./RulesetVariables";
6
6
  /** @internal */
7
7
  export declare const PRESENTATION_IPC_CHANNEL_NAME = "presentation-ipc-interface";
@@ -23,8 +23,11 @@ export interface UnsetRulesetVariableParams extends CommonIpcParams {
23
23
  export interface UpdateHierarchyStateParams<TNodeKey> extends CommonIpcParams {
24
24
  rulesetId: string;
25
25
  imodelKey: string;
26
- changeType: "nodesExpanded" | "nodesCollapsed";
27
- nodeKeys: Array<TNodeKey>;
26
+ stateChanges: Array<{
27
+ nodeKey: TNodeKey | undefined;
28
+ isExpanded?: boolean;
29
+ instanceFilters?: string[];
30
+ }>;
28
31
  }
29
32
  /** @internal */
30
33
  export interface PresentationIpcInterface {
@@ -33,6 +36,6 @@ export interface PresentationIpcInterface {
33
36
  /** Unsets ruleset variable value. */
34
37
  unsetRulesetVariable(params: UnsetRulesetVariableParams): Promise<void>;
35
38
  /** Updates hierarchy state saved on the backend. Hierarchy state is used when performing updates after iModel data changes */
36
- updateHierarchyState(params: UpdateHierarchyStateParams<NodeKeyJSON>): Promise<void>;
39
+ updateHierarchyState(params: UpdateHierarchyStateParams<NodeKey>): Promise<void>;
37
40
  }
38
41
  //# sourceMappingURL=PresentationIpcInterface.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"PresentationIpcInterface.d.ts","sourceRoot":"","sources":["../../../src/presentation-common/PresentationIpcInterface.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AAEzD,gBAAgB;AAChB,eAAO,MAAM,6BAA6B,+BAA+B,CAAC;AAE1E,gBAAgB;AAChB,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,gBAAgB;AAChB,MAAM,WAAW,wBAAwB,CAAC,SAAS,CAAE,SAAQ,eAAe;IAC1E,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,SAAS,CAAC;CACrB;AAED,gBAAgB;AAChB,MAAM,WAAW,0BAA2B,SAAQ,eAAe;IACjE,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;CACpB;AAED,gBAAgB;AAChB,MAAM,WAAW,0BAA0B,CAAC,QAAQ,CAAE,SAAQ,eAAe;IAC3E,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,eAAe,GAAG,gBAAgB,CAAC;IAC/C,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC;CAC3B;AAED,gBAAgB;AAChB,MAAM,WAAW,wBAAwB;IACvC,mCAAmC;IACnC,kBAAkB,CAAC,MAAM,EAAE,wBAAwB,CAAC,mBAAmB,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEzF,qCAAqC;IACrC,oBAAoB,CAAC,MAAM,EAAE,0BAA0B,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAExE,8HAA8H;IAC9H,oBAAoB,CAAC,MAAM,EAAE,0BAA0B,CAAC,WAAW,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CACtF"}
1
+ {"version":3,"file":"PresentationIpcInterface.d.ts","sourceRoot":"","sources":["../../../src/present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 @@
1
- {"version":3,"file":"PresentationIpcInterface.js","sourceRoot":"","sources":["../../../src/presentation-common/PresentationIpcInterface.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAKH,gBAAgB;AAChB,MAAM,CAAC,MAAM,6BAA6B,GAAG,4BAA4B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Core\r\n */\r\n\r\nimport { NodeKeyJSON } from \"./hierarchy/Key\";\r\nimport { RulesetVariableJSON } from \"./RulesetVariables\";\r\n\r\n/** @internal */\r\nexport const PRESENTATION_IPC_CHANNEL_NAME = \"presentation-ipc-interface\";\r\n\r\n/** @internal */\r\nexport interface CommonIpcParams {\r\n clientId: string;\r\n}\r\n\r\n/** @internal */\r\nexport interface SetRulesetVariableParams<TVariable> extends CommonIpcParams {\r\n rulesetId: string;\r\n variable: TVariable;\r\n}\r\n\r\n/** @internal */\r\nexport interface UnsetRulesetVariableParams extends CommonIpcParams {\r\n rulesetId: string;\r\n variableId: string;\r\n}\r\n\r\n/** @internal */\r\nexport interface UpdateHierarchyStateParams<TNodeKey> extends CommonIpcParams {\r\n rulesetId: string;\r\n imodelKey: string;\r\n changeType: \"nodesExpanded\" | \"nodesCollapsed\";\r\n nodeKeys: Array<TNodeKey>;\r\n}\r\n\r\n/** @internal */\r\nexport interface PresentationIpcInterface {\r\n /** Sets ruleset variable value. */\r\n setRulesetVariable(params: SetRulesetVariableParams<RulesetVariableJSON>): Promise<void>;\r\n\r\n /** Unsets ruleset variable value. */\r\n unsetRulesetVariable(params: UnsetRulesetVariableParams): Promise<void>;\r\n\r\n /** Updates hierarchy state saved on the backend. Hierarchy state is used when performing updates after iModel data changes */\r\n updateHierarchyState(params: UpdateHierarchyStateParams<NodeKeyJSON>): Promise<void>;\r\n}\r\n"]}
1
+ {"version":3,"file":"PresentationIpcInterface.js","sourceRoot":"","sources":["../../../src/presentation-common/PresentationIpcInterface.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAKH,gBAAgB;AAChB,MAAM,CAAC,MAAM,6BAA6B,GAAG,4BAA4B,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n/** @packageDocumentation\r\n * @module Core\r\n */\r\n\r\nimport { NodeKey } from \"./hierarchy/Key\";\r\nimport { RulesetVariableJSON } from \"./RulesetVariables\";\r\n\r\n/** @internal */\r\nexport const PRESENTATION_IPC_CHANNEL_NAME = \"presentation-ipc-interface\";\r\n\r\n/** @internal */\r\nexport interface CommonIpcParams {\r\n clientId: string;\r\n}\r\n\r\n/** @internal */\r\nexport interface SetRulesetVariableParams<TVariable> extends CommonIpcParams {\r\n rulesetId: string;\r\n variable: TVariable;\r\n}\r\n\r\n/** @internal */\r\nexport interface UnsetRulesetVariableParams extends CommonIpcParams {\r\n rulesetId: string;\r\n variableId: string;\r\n}\r\n\r\n/** @internal */\r\nexport interface UpdateHierarchyStateParams<TNodeKey> extends CommonIpcParams {\r\n rulesetId: string;\r\n imodelKey: string;\r\n stateChanges: Array<{\r\n nodeKey: TNodeKey | undefined;\r\n isExpanded?: boolean;\r\n instanceFilters?: string[];\r\n }>;\r\n}\r\n\r\n/** @internal */\r\nexport interface PresentationIpcInterface {\r\n /** Sets ruleset variable value. */\r\n setRulesetVariable(params: SetRulesetVariableParams<RulesetVariableJSON>): Promise<void>;\r\n\r\n /** Unsets ruleset variable value. */\r\n unsetRulesetVariable(params: UnsetRulesetVariableParams): Promise<void>;\r\n\r\n /** Updates hierarchy state saved on the backend. Hierarchy state is used when performing updates after iModel data changes */\r\n updateHierarchyState(params: UpdateHierarchyStateParams<NodeKey>): Promise<void>;\r\n}\r\n"]}
@@ -6,6 +6,7 @@ import { UnitSystemKey } from "@itwin/core-quantity";
6
6
  import { SelectionInfo } from "./content/Descriptor";
7
7
  import { FieldDescriptor } from "./content/Fields";
8
8
  import { InstanceKey } from "./EC";
9
+ import { InstanceFilterDefinition } from "./InstanceFilterDefinition";
9
10
  import { Ruleset } from "./rules/Ruleset";
10
11
  import { RulesetVariable } from "./RulesetVariables";
11
12
  import { SelectionScopeProps } from "./selection/SelectionScope";
@@ -49,6 +50,23 @@ export interface RequestOptionsWithRuleset<TIModel, TRulesetVariable = RulesetVa
49
50
  export interface HierarchyRequestOptions<TIModel, TNodeKey, TRulesetVariable = RulesetVariable> extends RequestOptionsWithRuleset<TIModel, TRulesetVariable> {
50
51
  /** Key of the parent node to get children for */
51
52
  parentKey?: TNodeKey;
53
+ /**
54
+ * An instance filter that should be applied for this hierarchy level.
55
+ *
56
+ * **Note:** May only be used on hierarchy levels that support filtering - check [[NavNode.supportsFiltering]] before
57
+ * requesting filtered children.
58
+ *
59
+ * @beta
60
+ */
61
+ instanceFilter?: InstanceFilterDefinition;
62
+ }
63
+ /**
64
+ * Params for hierarchy level descriptor requests.
65
+ * @beta
66
+ */
67
+ export interface HierarchyLevelDescriptorRequestOptions<TIModel, TNodeKey, TRulesetVariable = RulesetVariable> extends RequestOptionsWithRuleset<TIModel, TRulesetVariable> {
68
+ /** Key of the parent node to get hierarchy level descriptor for. */
69
+ parentKey?: TNodeKey;
52
70
  }
53
71
  /**
54
72
  * Request type of filtering hierarchies by given ECInstance paths.
@@ -73,10 +91,10 @@ export interface FilterByTextHierarchyRequestOptions<TIModel, TRulesetVariable =
73
91
  }
74
92
  /**
75
93
  * Request type for content sources requests.
76
- * @beta
94
+ * @public
77
95
  */
78
96
  export interface ContentSourcesRequestOptions<TIModel> extends RequestOptions<TIModel> {
79
- /** Full names of classes to get content sources for. */
97
+ /** Full names of classes to get content sources for. Format for a full class name: `SchemaName:ClassName`. */
80
98
  classes: string[];
81
99
  }
82
100
  /**
@@ -118,12 +136,12 @@ export interface DistinctValuesRequestOptions<TIModel, TDescriptor, TKeySet, TRu
118
136
  }
119
137
  /**
120
138
  * Request type for element properties requests
121
- * @beta
139
+ * @public
122
140
  */
123
141
  export declare type ElementPropertiesRequestOptions<TIModel> = SingleElementPropertiesRequestOptions<TIModel> | MultiElementPropertiesRequestOptions<TIModel>;
124
142
  /**
125
143
  * Request type for single element properties requests.
126
- * @beta
144
+ * @public
127
145
  */
128
146
  export interface SingleElementPropertiesRequestOptions<TIModel> extends RequestOptions<TIModel> {
129
147
  /** ID of the element to get properties for. */
@@ -131,18 +149,19 @@ export interface SingleElementPropertiesRequestOptions<TIModel> extends RequestO
131
149
  }
132
150
  /**
133
151
  * Request type for multiple elements properties requests.
134
- * @beta
152
+ * @public
135
153
  */
136
154
  export interface MultiElementPropertiesRequestOptions<TIModel> extends RequestOptions<TIModel> {
137
- /** Classes of the elements to get properties for. If `elementClasses` is undefined all classes
138
- * are used. Classes should be specified in one of these formats: "<schema name or alias>.<class_name>",
155
+ /**
156
+ * Classes of the elements to get properties for. If [[elementClasses]] is `undefined`, all classes
157
+ * are used. Classes should be specified in one of these formats: "<schema name or alias>.<class_name>" or
139
158
  * "<schema name or alias>:<class_name>".
140
159
  */
141
160
  elementClasses?: string[];
142
161
  }
143
162
  /**
144
163
  * Request type for content instance keys' requests.
145
- * @beta
164
+ * @public
146
165
  */
147
166
  export interface ContentInstanceKeysRequestOptions<TIModel, TKeySet, TRulesetVariable = RulesetVariable> extends Paged<RequestOptionsWithRuleset<TIModel, TRulesetVariable>> {
148
167
  /**
@@ -176,8 +195,8 @@ export interface DisplayLabelsRequestOptions<TIModel, TInstanceKey> extends Requ
176
195
  export interface SelectionScopeRequestOptions<TIModel> extends RequestOptions<TIModel> {
177
196
  }
178
197
  /**
179
- * Request options used for calculating selection based on picked instance ksy and selection scope
180
- * @alpha
198
+ * Request options used for calculating selection based on given instance keys and selection scope.
199
+ * @public
181
200
  */
182
201
  export interface ComputeSelectionRequestOptions<TIModel> extends RequestOptions<TIModel> {
183
202
  elementIds: Id64String[];
@@ -229,7 +248,7 @@ export declare type Prioritized<TOptions extends {}> = TOptions & {
229
248
  };
230
249
  /**
231
250
  * Checks if supplied request options are for single or multiple element properties.
232
- * @beta
251
+ * @internal
233
252
  */
234
253
  export declare function isSingleElementPropertiesRequestOptions<TIModel>(options: ElementPropertiesRequestOptions<TIModel>): options is SingleElementPropertiesRequestOptions<TIModel>;
235
254
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"PresentationManagerOptions.d.ts","sourceRoot":"","sources":["../../../src/presentation-common/PresentationManagerOptions.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AAEjE;;;GAGG;AACH,MAAM,WAAW,cAAc,CAAC,OAAO;IACrC,kCAAkC;IAClC,MAAM,EAAE,OAAO,CAAC;IAEhB,+DAA+D;IAC/D,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,UAAU,CAAC,EAAE,aAAa,CAAC;IAE3B;;;;OAIG;IACH,SAAS,CAAC,EAAE,eAAe,CAAC;CAC7B;AAED;;;;;GAKG;AACH,MAAM,WAAW,yBAAyB,CAAC,OAAO,EAAE,gBAAgB,GAAG,eAAe,CAAE,SAAQ,cAAc,CAAC,OAAO,CAAC;IACrH,+DAA+D;I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,MAAM,CAAC;IACf,+BAA+B;IAC/B,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;GAGG;AACH,oBAAY,KAAK,CAAC,QAAQ,SAAS,EAAE,IAAI,QAAQ,GAAG;IAClD,iCAAiC;IACjC,MAAM,CAAC,EAAE,WAAW,CAAC;CACtB,CAAC;AAEF;;;GAGG;AACH,oBAAY,WAAW,CAAC,QAAQ,SAAS,EAAE,IAAI,QAAQ,GAAG;IACxD,wBAAwB;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,uCAAuC,CAAC,OAAO,EAAE,OAAO,EAAE,+BAA+B,CAAC,OAAO,CAAC,GAAG,OAAO,IAAI,qCAAqC,CAAC,OAAO,CAAC,CAE7K;AAED;;;GAGG;AACH,oBAAY,eAAe,CAAC,QAAQ,SAAS,EAAE,IAAI,QAAQ,GAAG;IAC5D,4DAA4D;IAC5D,WAAW,CAAC,EAAE,OAAO,CAAC,MAAM,IAAI,CAAC,CAAC;CACnC,CAAC"}
1
+ {"version":3,"file":"PresentationManagerOptions.d.ts","sourceRoot":"","sources":["../../../src/presentation-common/PresentationManagerOptions.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,WAAW,EAAE,MAAM,MAAM,CAAC;AACnC,OAAO,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AACtE,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAC1C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4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5D,4DAA4D;IAC5D,WAAW,CAAC,EAAE,OAAO,CAAC,MAAM,IAAI,CAAC,CAAC;CACnC,CAAC"}
@@ -11,7 +11,7 @@ export function isComputeSelectionRequestOptions(options) {
11
11
  }
12
12
  /**
13
13
  * Checks if supplied request options are for single or multiple element properties.
14
- * @beta
14
+ * @internal
15
15
  */
16
16
  export function isSingleElementPropertiesRequestOptions(options) {
17
17
  return options.elementId !== undefined;