@itwin/presentation-common 5.2.0-dev.8 → 5.3.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.
- package/CHANGELOG.md +38 -1
- package/Ruleset.schema.json +18 -0
- package/lib/cjs/presentation-common/KeySet.d.ts +22 -7
- package/lib/cjs/presentation-common/KeySet.d.ts.map +1 -1
- package/lib/cjs/presentation-common/KeySet.js +28 -37
- package/lib/cjs/presentation-common/KeySet.js.map +1 -1
- package/lib/cjs/presentation-common/KoqPropertyValueFormatter.d.ts +2 -0
- package/lib/cjs/presentation-common/KoqPropertyValueFormatter.d.ts.map +1 -1
- package/lib/cjs/presentation-common/KoqPropertyValueFormatter.js +2 -2
- package/lib/cjs/presentation-common/KoqPropertyValueFormatter.js.map +1 -1
- package/lib/cjs/presentation-common/LocalizationHelper.d.ts +1 -1
- package/lib/cjs/presentation-common/LocalizationHelper.d.ts.map +1 -1
- package/lib/cjs/presentation-common/LocalizationHelper.js +9 -7
- package/lib/cjs/presentation-common/LocalizationHelper.js.map +1 -1
- package/lib/cjs/presentation-common/PresentationManagerOptions.d.ts +10 -0
- package/lib/cjs/presentation-common/PresentationManagerOptions.d.ts.map +1 -1
- package/lib/cjs/presentation-common/PresentationManagerOptions.js.map +1 -1
- package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts +8 -0
- package/lib/cjs/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
- package/lib/cjs/presentation-common/PresentationRpcInterface.js +1 -2
- package/lib/cjs/presentation-common/PresentationRpcInterface.js.map +1 -1
- package/lib/cjs/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
- package/lib/cjs/presentation-common/RpcRequestsHandler.js +2 -16
- package/lib/cjs/presentation-common/RpcRequestsHandler.js.map +1 -1
- package/lib/cjs/presentation-common/Update.d.ts +16 -0
- package/lib/cjs/presentation-common/Update.d.ts.map +1 -1
- package/lib/cjs/presentation-common/Update.js +1 -0
- package/lib/cjs/presentation-common/Update.js.map +1 -1
- package/lib/cjs/presentation-common/Utils.d.ts.map +1 -1
- package/lib/cjs/presentation-common/Utils.js +2 -0
- package/lib/cjs/presentation-common/Utils.js.map +1 -1
- package/lib/cjs/presentation-common/content/ContentTraverser.d.ts.map +1 -1
- package/lib/cjs/presentation-common/content/ContentTraverser.js +14 -10
- package/lib/cjs/presentation-common/content/ContentTraverser.js.map +1 -1
- package/lib/cjs/presentation-common/content/PropertyValueFormatter.d.ts.map +1 -1
- package/lib/cjs/presentation-common/content/PropertyValueFormatter.js +6 -1
- package/lib/cjs/presentation-common/content/PropertyValueFormatter.js.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts +2 -0
- package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js +1 -0
- package/lib/cjs/presentation-common/hierarchy/HierarchyLevel.js.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/Key.d.ts +23 -1
- package/lib/cjs/presentation-common/hierarchy/Key.d.ts.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/Key.js +8 -1
- package/lib/cjs/presentation-common/hierarchy/Key.js.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/Node.d.ts +4 -0
- package/lib/cjs/presentation-common/hierarchy/Node.d.ts.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/Node.js +1 -0
- package/lib/cjs/presentation-common/hierarchy/Node.js.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts +4 -0
- package/lib/cjs/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
- package/lib/cjs/presentation-common/hierarchy/NodePathElement.js +1 -0
- package/lib/cjs/presentation-common/hierarchy/NodePathElement.js.map +1 -1
- package/lib/cjs/presentation-common/rules/Rule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/Rule.js +1 -0
- package/lib/cjs/presentation-common/rules/Rule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/customization/CustomizationRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/customization/CustomizationRule.js +1 -0
- package/lib/cjs/presentation-common/rules/customization/CustomizationRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts +18 -0
- package/lib/cjs/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/customization/GroupingRule.js +5 -0
- package/lib/cjs/presentation-common/rules/customization/GroupingRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts +8 -0
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.js +3 -0
- package/lib/cjs/presentation-common/rules/hierarchy/ChildNodeSpecification.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts +12 -0
- package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js +3 -0
- package/lib/cjs/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/NavigationRule.d.ts +4 -0
- package/lib/cjs/presentation-common/rules/hierarchy/NavigationRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/NavigationRule.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/NavigationRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/NodeArtifactsRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/RootNodeRule.js.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.d.ts +2 -0
- package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.d.ts.map +1 -1
- package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.js +1 -0
- package/lib/cjs/presentation-common/rules/hierarchy/SubCondition.js.map +1 -1
- package/lib/esm/presentation-common/KeySet.d.ts +22 -7
- package/lib/esm/presentation-common/KeySet.d.ts.map +1 -1
- package/lib/esm/presentation-common/KeySet.js +29 -38
- package/lib/esm/presentation-common/KeySet.js.map +1 -1
- package/lib/esm/presentation-common/KoqPropertyValueFormatter.d.ts +2 -0
- package/lib/esm/presentation-common/KoqPropertyValueFormatter.d.ts.map +1 -1
- package/lib/esm/presentation-common/KoqPropertyValueFormatter.js +2 -2
- package/lib/esm/presentation-common/KoqPropertyValueFormatter.js.map +1 -1
- package/lib/esm/presentation-common/LocalizationHelper.d.ts +1 -1
- package/lib/esm/presentation-common/LocalizationHelper.d.ts.map +1 -1
- package/lib/esm/presentation-common/LocalizationHelper.js +9 -7
- package/lib/esm/presentation-common/LocalizationHelper.js.map +1 -1
- package/lib/esm/presentation-common/PresentationManagerOptions.d.ts +10 -0
- package/lib/esm/presentation-common/PresentationManagerOptions.d.ts.map +1 -1
- package/lib/esm/presentation-common/PresentationManagerOptions.js.map +1 -1
- package/lib/esm/presentation-common/PresentationRpcInterface.d.ts +8 -0
- package/lib/esm/presentation-common/PresentationRpcInterface.d.ts.map +1 -1
- package/lib/esm/presentation-common/PresentationRpcInterface.js +1 -2
- package/lib/esm/presentation-common/PresentationRpcInterface.js.map +1 -1
- package/lib/esm/presentation-common/RpcRequestsHandler.d.ts.map +1 -1
- package/lib/esm/presentation-common/RpcRequestsHandler.js +2 -16
- package/lib/esm/presentation-common/RpcRequestsHandler.js.map +1 -1
- package/lib/esm/presentation-common/Update.d.ts +16 -0
- package/lib/esm/presentation-common/Update.d.ts.map +1 -1
- package/lib/esm/presentation-common/Update.js +1 -0
- package/lib/esm/presentation-common/Update.js.map +1 -1
- package/lib/esm/presentation-common/Utils.d.ts.map +1 -1
- package/lib/esm/presentation-common/Utils.js +2 -0
- package/lib/esm/presentation-common/Utils.js.map +1 -1
- package/lib/esm/presentation-common/content/ContentTraverser.d.ts.map +1 -1
- package/lib/esm/presentation-common/content/ContentTraverser.js +14 -10
- package/lib/esm/presentation-common/content/ContentTraverser.js.map +1 -1
- package/lib/esm/presentation-common/content/PropertyValueFormatter.d.ts.map +1 -1
- package/lib/esm/presentation-common/content/PropertyValueFormatter.js +6 -1
- package/lib/esm/presentation-common/content/PropertyValueFormatter.js.map +1 -1
- package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts +2 -0
- package/lib/esm/presentation-common/hierarchy/HierarchyLevel.d.ts.map +1 -1
- package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js +1 -0
- package/lib/esm/presentation-common/hierarchy/HierarchyLevel.js.map +1 -1
- package/lib/esm/presentation-common/hierarchy/Key.d.ts +23 -1
- package/lib/esm/presentation-common/hierarchy/Key.d.ts.map +1 -1
- package/lib/esm/presentation-common/hierarchy/Key.js +8 -1
- package/lib/esm/presentation-common/hierarchy/Key.js.map +1 -1
- package/lib/esm/presentation-common/hierarchy/Node.d.ts +4 -0
- package/lib/esm/presentation-common/hierarchy/Node.d.ts.map +1 -1
- package/lib/esm/presentation-common/hierarchy/Node.js +1 -0
- package/lib/esm/presentation-common/hierarchy/Node.js.map +1 -1
- package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts +4 -0
- package/lib/esm/presentation-common/hierarchy/NodePathElement.d.ts.map +1 -1
- package/lib/esm/presentation-common/hierarchy/NodePathElement.js +1 -0
- package/lib/esm/presentation-common/hierarchy/NodePathElement.js.map +1 -1
- package/lib/esm/presentation-common/rules/Rule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/Rule.js +1 -0
- package/lib/esm/presentation-common/rules/Rule.js.map +1 -1
- package/lib/esm/presentation-common/rules/customization/CustomizationRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/customization/CustomizationRule.js +1 -0
- package/lib/esm/presentation-common/rules/customization/CustomizationRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts +18 -0
- package/lib/esm/presentation-common/rules/customization/GroupingRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/customization/GroupingRule.js +5 -0
- package/lib/esm/presentation-common/rules/customization/GroupingRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts +8 -0
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.js +3 -0
- package/lib/esm/presentation-common/rules/hierarchy/ChildNodeSpecification.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/CustomNodeSpecification.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts +12 -0
- package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js +3 -0
- package/lib/esm/presentation-common/rules/hierarchy/CustomQueryInstanceNodesSpecification.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/NavigationRule.d.ts +4 -0
- package/lib/esm/presentation-common/rules/hierarchy/NavigationRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/NavigationRule.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/NavigationRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/NodeArtifactsRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/RootNodeRule.js.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/SubCondition.d.ts +2 -0
- package/lib/esm/presentation-common/rules/hierarchy/SubCondition.d.ts.map +1 -1
- package/lib/esm/presentation-common/rules/hierarchy/SubCondition.js +1 -0
- package/lib/esm/presentation-common/rules/hierarchy/SubCondition.js.map +1 -1
- package/package.json +11 -11
package/lib/cjs/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.js
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
4
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
5
|
*--------------------------------------------------------------------------------------------*/
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-deprecated */
|
|
6
7
|
/** @packageDocumentation
|
|
7
8
|
* @module PresentationRules
|
|
8
9
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"InstanceNodesOfSpecificClassesSpecification.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { MultiSchemaClassesSpecification } from \"../ClassSpecifications.js\";\nimport { ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer } from \"./ChildNodeSpecification.js\";\n\n/**\n * Returns nodes for instances of specific ECClasses.\n *\n * @see [Instance nodes of specific classes specification reference documentation page]($docs/presentation/hierarchies/InstanceNodesOfSpecificClasses.md)\n * @public\n */\nexport interface InstanceNodesOfSpecificClassesSpecification extends ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer {\n /** Used for serializing to JSON. */\n specType: \"InstanceNodesOfSpecificClasses\";\n\n /**\n * Defines a set of [multi schema classes]($docs/presentation/MultiSchemaClassesSpecification.md) that\n * specify which ECClasses need to be selected to form the result.\n */\n classes: MultiSchemaClassesSpecification | MultiSchemaClassesSpecification[];\n\n /**\n * Defines a set of [multi schema classes]($docs/presentation/MultiSchemaClassesSpecification.md) that\n * prevents specified ECClasses and subclasses from being selected by [[classes]] attribute.\n */\n excludedClasses?: MultiSchemaClassesSpecification | MultiSchemaClassesSpecification[];\n\n /**\n * Specifies an [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#instance-filter) for filtering\n * instances of ECClasses specified through the [[classes]] attribute.\n */\n instanceFilter?: string;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"InstanceNodesOfSpecificClassesSpecification.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/InstanceNodesOfSpecificClassesSpecification.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG,qDAAqD;AACrD;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/* eslint-disable @typescript-eslint/no-deprecated */\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { MultiSchemaClassesSpecification } from \"../ClassSpecifications.js\";\nimport { ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer } from \"./ChildNodeSpecification.js\";\n\n/**\n * Returns nodes for instances of specific ECClasses.\n *\n * @see [Instance nodes of specific classes specification reference documentation page]($docs/presentation/hierarchies/InstanceNodesOfSpecificClasses.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface InstanceNodesOfSpecificClassesSpecification extends ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer {\n /** Used for serializing to JSON. */\n specType: \"InstanceNodesOfSpecificClasses\";\n\n /**\n * Defines a set of [multi schema classes]($docs/presentation/MultiSchemaClassesSpecification.md) that\n * specify which ECClasses need to be selected to form the result.\n */\n classes: MultiSchemaClassesSpecification | MultiSchemaClassesSpecification[];\n\n /**\n * Defines a set of [multi schema classes]($docs/presentation/MultiSchemaClassesSpecification.md) that\n * prevents specified ECClasses and subclasses from being selected by [[classes]] attribute.\n */\n excludedClasses?: MultiSchemaClassesSpecification | MultiSchemaClassesSpecification[];\n\n /**\n * Specifies an [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#instance-filter) for filtering\n * instances of ECClasses specified through the [[classes]] attribute.\n */\n instanceFilter?: string;\n}\n"]}
|
|
@@ -12,6 +12,8 @@ import { SubCondition } from "./SubCondition.js";
|
|
|
12
12
|
*
|
|
13
13
|
* @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)
|
|
14
14
|
* @public
|
|
15
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
16
|
+
* package for creating hierarchies.
|
|
15
17
|
*/
|
|
16
18
|
export interface NavigationRuleBase extends RuleBase {
|
|
17
19
|
/**
|
|
@@ -46,6 +48,8 @@ export interface NavigationRuleBase extends RuleBase {
|
|
|
46
48
|
*
|
|
47
49
|
* @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)
|
|
48
50
|
* @public
|
|
51
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
52
|
+
* package for creating hierarchies.
|
|
49
53
|
*/
|
|
50
54
|
export type NavigationRule = RootNodeRule | ChildNodeRule;
|
|
51
55
|
//# sourceMappingURL=NavigationRule.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NavigationRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NavigationRule.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NavigationRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NavigationRule.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAC1E,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEjD;;;;;;;GAOG;AACH,MAAM,WAAW,kBAAmB,SAAQ,QAAQ;IAClD;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,cAAc,CAAC,EAAE,sBAAsB,EAAE,CAAC;IAE1C;;;OAGG;IACH,kBAAkB,CAAC,EAAE,iBAAiB,EAAE,CAAC;IAEzC;;;;;OAKG;IACH,aAAa,CAAC,EAAE,YAAY,EAAE,CAAC;IAE/B;;OAEG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC;AAED;;;;;;;GAOG;AACH,MAAM,MAAM,cAAc,GAAG,YAAY,GAAG,aAAa,CAAC"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
4
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
5
|
*--------------------------------------------------------------------------------------------*/
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-deprecated */
|
|
6
7
|
/** @packageDocumentation
|
|
7
8
|
* @module PresentationRules
|
|
8
9
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NavigationRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NavigationRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { CustomizationRule } from \"../customization/CustomizationRule.js\";\nimport { RuleBase } from \"../Rule.js\";\nimport { ChildNodeRule } from \"./ChildNodeRule.js\";\nimport { ChildNodeSpecification } from \"./ChildNodeSpecification.js\";\nimport { RootNodeRule } from \"./RootNodeRule.js\";\nimport { SubCondition } from \"./SubCondition.js\";\n\n/**\n * Base class for all [[NavigationRule]] implementations.\n *\n * @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)\n * @public\n */\nexport interface NavigationRuleBase extends RuleBase {\n /**\n * Defines a condition which needs to be met in order for the rule to be used. The condition is an\n * [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#rule-condition) which has to evaluate\n * to a boolean value.\n */\n condition?: string;\n\n /**\n * A list of hierarchy specifications that define what nodes are going to be returned.\n */\n specifications?: ChildNodeSpecification[];\n\n /**\n * A list of [customization rules]($docs/presentation/hierarchies/index.md#hierarchy-customization) that\n * apply only to nodes produced by this rule.\n */\n customizationRules?: CustomizationRule[];\n\n /**\n * A list of sub-rules which share *placement attributes* and\n * [nested customization rules]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-customizationrules)\n * of the hierarchy rule. This means the attributes of hierarchy rule are still in effect and the sub-rules\n * can add additional condition of their own.\n */\n subConditions?: SubCondition[];\n\n /**\n * Stop processing rules that have lower priority. Used in cases when recursion suppression is needed.\n */\n stopFurtherProcessing?: boolean;\n}\n\n/**\n * Navigation rules are used to define hierarchies displayed in tree components.\n *\n * @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)\n * @public\n */\nexport type NavigationRule = RootNodeRule | ChildNodeRule;\n"]}
|
|
1
|
+
{"version":3,"file":"NavigationRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NavigationRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG,qDAAqD;AACrD;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/* eslint-disable @typescript-eslint/no-deprecated */\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { CustomizationRule } from \"../customization/CustomizationRule.js\";\nimport { RuleBase } from \"../Rule.js\";\nimport { ChildNodeRule } from \"./ChildNodeRule.js\";\nimport { ChildNodeSpecification } from \"./ChildNodeSpecification.js\";\nimport { RootNodeRule } from \"./RootNodeRule.js\";\nimport { SubCondition } from \"./SubCondition.js\";\n\n/**\n * Base class for all [[NavigationRule]] implementations.\n *\n * @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface NavigationRuleBase extends RuleBase {\n /**\n * Defines a condition which needs to be met in order for the rule to be used. The condition is an\n * [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#rule-condition) which has to evaluate\n * to a boolean value.\n */\n condition?: string;\n\n /**\n * A list of hierarchy specifications that define what nodes are going to be returned.\n */\n specifications?: ChildNodeSpecification[];\n\n /**\n * A list of [customization rules]($docs/presentation/hierarchies/index.md#hierarchy-customization) that\n * apply only to nodes produced by this rule.\n */\n customizationRules?: CustomizationRule[];\n\n /**\n * A list of sub-rules which share *placement attributes* and\n * [nested customization rules]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-customizationrules)\n * of the hierarchy rule. This means the attributes of hierarchy rule are still in effect and the sub-rules\n * can add additional condition of their own.\n */\n subConditions?: SubCondition[];\n\n /**\n * Stop processing rules that have lower priority. Used in cases when recursion suppression is needed.\n */\n stopFurtherProcessing?: boolean;\n}\n\n/**\n * Navigation rules are used to define hierarchies displayed in tree components.\n *\n * @see [Hierarchies reference documentation page]($docs/presentation/hierarchies/index.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport type NavigationRule = RootNodeRule | ChildNodeRule;\n"]}
|
|
@@ -8,6 +8,8 @@ import { RuleBase } from "../Rule.js";
|
|
|
8
8
|
*
|
|
9
9
|
* @see [Node artifacts rule reference documentation page]($docs/presentation/hierarchies/NodeArtifactsRule.md)
|
|
10
10
|
* @public
|
|
11
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
12
|
+
* package for creating hierarchies.
|
|
11
13
|
*/
|
|
12
14
|
export interface NodeArtifactsRule extends RuleBase {
|
|
13
15
|
/** Used for serializing to JSON. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NodeArtifactsRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NodeArtifactsRule.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC
|
|
1
|
+
{"version":3,"file":"NodeArtifactsRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NodeArtifactsRule.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAkB,SAAQ,QAAQ;IACjD,oCAAoC;IACpC,QAAQ,EAAE,eAAe,CAAC;IAE1B;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,KAAK,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;CAClC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NodeArtifactsRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NodeArtifactsRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RuleBase } from \"../Rule.js\";\n\n/**\n * Node artifacts rules are used to create and assign artifacts to specific nodes. The artifacts can be\n * accessed when evaluating parent node's `hideExpression` to decide whether it should be hidden or not.\n *\n * @see [Node artifacts rule reference documentation page]($docs/presentation/hierarchies/NodeArtifactsRule.md)\n * @public\n */\nexport interface NodeArtifactsRule extends RuleBase {\n /** Used for serializing to JSON. */\n ruleType: \"NodeArtifacts\";\n\n /**\n * Specifies an [ECExpression]($docs/presentation/customization/ECExpressions.md#rule-condition) that\n * allows applying node artifacts based on evaluation result, e.g. by some property of the parent node.\n */\n condition?: string;\n\n /**\n * A map of [ECExpressions]($docs/presentation/hierarchies/ECExpressions.md#specification) whose evaluation results\n * are used as artifact values.\n */\n items: { [key: string]: string };\n}\n"]}
|
|
1
|
+
{"version":3,"file":"NodeArtifactsRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/NodeArtifactsRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RuleBase } from \"../Rule.js\";\n\n/**\n * Node artifacts rules are used to create and assign artifacts to specific nodes. The artifacts can be\n * accessed when evaluating parent node's `hideExpression` to decide whether it should be hidden or not.\n *\n * @see [Node artifacts rule reference documentation page]($docs/presentation/hierarchies/NodeArtifactsRule.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface NodeArtifactsRule extends RuleBase {\n /** Used for serializing to JSON. */\n ruleType: \"NodeArtifacts\";\n\n /**\n * Specifies an [ECExpression]($docs/presentation/customization/ECExpressions.md#rule-condition) that\n * allows applying node artifacts based on evaluation result, e.g. by some property of the parent node.\n */\n condition?: string;\n\n /**\n * A map of [ECExpressions]($docs/presentation/hierarchies/ECExpressions.md#specification) whose evaluation results\n * are used as artifact values.\n */\n items: { [key: string]: string };\n}\n"]}
|
|
@@ -9,6 +9,8 @@ import { ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer } from "
|
|
|
9
9
|
*
|
|
10
10
|
* @see [Related instance nodes specification reference documentation page]($docs/presentation/hierarchies/RelatedInstanceNodes.md)
|
|
11
11
|
* @public
|
|
12
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
13
|
+
* package for creating hierarchies.
|
|
12
14
|
*/
|
|
13
15
|
export interface RelatedInstanceNodesSpecification extends ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer {
|
|
14
16
|
/** Used for serializing to JSON. */
|
package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelatedInstanceNodesSpecification.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RelatedInstanceNodesSpecification.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,uCAAuC,EAAE,MAAM,qCAAqC,CAAC;AAC9F,OAAO,EAAE,0BAA0B,EAAE,kCAAkC,EAAE,MAAM,6BAA6B,CAAC;AAE7G;;;;;;;;GAQG;AACH,MAAM,WAAW,iCAAkC,SAAQ,0BAA0B,EAAE,kCAAkC;IACvH,oCAAoC;IACpC,QAAQ,EAAE,sBAAsB,CAAC;IAEjC;;;;OAIG;IACH,iBAAiB,EAAE,uCAAuC,EAAE,CAAC;IAE7D;;;OAGG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
4
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
5
|
*--------------------------------------------------------------------------------------------*/
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-deprecated */
|
|
6
7
|
/** @packageDocumentation
|
|
7
8
|
* @module PresentationRules
|
|
8
9
|
*/
|
package/lib/cjs/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelatedInstanceNodesSpecification.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RepeatableRelationshipPathSpecification } from \"../RelationshipPathSpecification.js\";\nimport { ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer } from \"./ChildNodeSpecification.js\";\n\n/**\n * Produces ECInstance nodes that are related to some source ECInstance. The source instance is determined\n * by traversing the hierarchy upwards until an ECInstance node is encountered.\n *\n * @see [Related instance nodes specification reference documentation page]($docs/presentation/hierarchies/RelatedInstanceNodes.md)\n * @public\n */\nexport interface RelatedInstanceNodesSpecification extends ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer {\n /** Used for serializing to JSON. */\n specType: \"RelatedInstanceNodes\";\n\n /**\n * Specifies a chain of [relationship path specifications]($docs/presentation/RepeatableRelationshipPathSpecification.md)\n * that forms a path from a source instance to the output instances. When this array is empty, the specification produces\n * no results.\n */\n relationshipPaths: RepeatableRelationshipPathSpecification[];\n\n /**\n * Specifies an [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#instance-filter) for filtering\n * instances of ECClasses targeted through the [[relationshipPaths]] attribute.\n */\n instanceFilter?: string;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"RelatedInstanceNodesSpecification.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RelatedInstanceNodesSpecification.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG,qDAAqD;AACrD;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/* eslint-disable @typescript-eslint/no-deprecated */\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RepeatableRelationshipPathSpecification } from \"../RelationshipPathSpecification.js\";\nimport { ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer } from \"./ChildNodeSpecification.js\";\n\n/**\n * Produces ECInstance nodes that are related to some source ECInstance. The source instance is determined\n * by traversing the hierarchy upwards until an ECInstance node is encountered.\n *\n * @see [Related instance nodes specification reference documentation page]($docs/presentation/hierarchies/RelatedInstanceNodes.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface RelatedInstanceNodesSpecification extends ChildNodeSpecificationBase, DefaultGroupingPropertiesContainer {\n /** Used for serializing to JSON. */\n specType: \"RelatedInstanceNodes\";\n\n /**\n * Specifies a chain of [relationship path specifications]($docs/presentation/RepeatableRelationshipPathSpecification.md)\n * that forms a path from a source instance to the output instances. When this array is empty, the specification produces\n * no results.\n */\n relationshipPaths: RepeatableRelationshipPathSpecification[];\n\n /**\n * Specifies an [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#instance-filter) for filtering\n * instances of ECClasses targeted through the [[relationshipPaths]] attribute.\n */\n instanceFilter?: string;\n}\n"]}
|
|
@@ -7,6 +7,8 @@ import { NavigationRuleBase } from "./NavigationRule.js";
|
|
|
7
7
|
*
|
|
8
8
|
* @see [Root node rule reference documentation page]($docs/presentation/hierarchies/RootNodeRule.md)
|
|
9
9
|
* @public
|
|
10
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
11
|
+
* package for creating hierarchies.
|
|
10
12
|
*/
|
|
11
13
|
export interface RootNodeRule extends NavigationRuleBase {
|
|
12
14
|
/** Used for serializing to JSON. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RootNodeRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RootNodeRule.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RootNodeRule.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RootNodeRule.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAEzD;;;;;;;GAOG;AACH,MAAM,WAAW,YAAa,SAAQ,kBAAkB;IACtD,oCAAoC;IACpC,QAAQ,EAAE,WAAW,CAAC;IAEtB,gHAAgH;IAChH,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
4
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
5
|
*--------------------------------------------------------------------------------------------*/
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-deprecated */
|
|
6
7
|
/** @packageDocumentation
|
|
7
8
|
* @module PresentationRules
|
|
8
9
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RootNodeRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RootNodeRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { NavigationRuleBase } from \"./NavigationRule.js\";\n\n/**\n * Root node rules are used to define nodes that are displayed at the root hierarchy level.\n *\n * @see [Root node rule reference documentation page]($docs/presentation/hierarchies/RootNodeRule.md)\n * @public\n */\nexport interface RootNodeRule extends NavigationRuleBase {\n /** Used for serializing to JSON. */\n ruleType: \"RootNodes\";\n\n /** Tells the library to assign produced nodes a flag, indicating that they should be automatically expanded. */\n autoExpand?: boolean;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"RootNodeRule.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/RootNodeRule.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG,qDAAqD;AACrD;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/* eslint-disable @typescript-eslint/no-deprecated */\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { NavigationRuleBase } from \"./NavigationRule.js\";\n\n/**\n * Root node rules are used to define nodes that are displayed at the root hierarchy level.\n *\n * @see [Root node rule reference documentation page]($docs/presentation/hierarchies/RootNodeRule.md)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface RootNodeRule extends NavigationRuleBase {\n /** Used for serializing to JSON. */\n ruleType: \"RootNodes\";\n\n /** Tells the library to assign produced nodes a flag, indicating that they should be automatically expanded. */\n autoExpand?: boolean;\n}\n"]}
|
|
@@ -11,6 +11,8 @@ import { ChildNodeSpecification } from "./ChildNodeSpecification.js";
|
|
|
11
11
|
*
|
|
12
12
|
* @see [Sub-conditions reference documentation section]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-subconditions)
|
|
13
13
|
* @public
|
|
14
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
15
|
+
* package for creating hierarchies.
|
|
14
16
|
*/
|
|
15
17
|
export interface SubCondition {
|
|
16
18
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SubCondition.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/SubCondition.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SubCondition.d.ts","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/SubCondition.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AACzE,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAErE;;;;;;;;;;GAUG;AACH,MAAM,WAAW,YAAY;IAC3B;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;OAGG;IACH,eAAe,CAAC,EAAE,2BAA2B,EAAE,CAAC;IAEhD;;;;OAIG;IACH,aAAa,CAAC,EAAE,YAAY,EAAE,CAAC;IAE/B,0FAA0F;IAC1F,cAAc,CAAC,EAAE,sBAAsB,EAAE,CAAC;CAC3C"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
|
|
4
4
|
* See LICENSE.md in the project root for license terms and full copyright notice.
|
|
5
5
|
*--------------------------------------------------------------------------------------------*/
|
|
6
|
+
/* eslint-disable @typescript-eslint/no-deprecated */
|
|
6
7
|
/** @packageDocumentation
|
|
7
8
|
* @module PresentationRules
|
|
8
9
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SubCondition.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/SubCondition.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RequiredSchemaSpecification } from \"../SchemasSpecification.js\";\nimport { ChildNodeSpecification } from \"./ChildNodeSpecification.js\";\n\n/**\n * This is a sub-rule which shares *placement attributes* and\n * [nested customization rules]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-customizationrules)\n * of the hierarchy rule. This means the attributes of hierarchy rule are still in effect and the sub-rules\n * can add additional condition of their own.\n *\n * @see [Sub-conditions reference documentation section]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-subconditions)\n * @public\n */\nexport interface SubCondition {\n /**\n * Defines a condition which needs to be met in order for the rule to be used. The condition is an\n * [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#rule-condition) which has to evaluate\n * to a boolean value.\n */\n condition?: string;\n\n /**\n * Specifications that define [ECSchema requirements]($docs/presentation/RequiredSchemaSpecification.md) for\n * the rule to take effect.\n */\n requiredSchemas?: RequiredSchemaSpecification[];\n\n /**\n * A list of nested sub-rules which share *placement attributes* of this sub-condition. This means the\n * attributes of this sub-condition are still in effect and the sub-rules can add additional condition\n * of their own.\n */\n subConditions?: SubCondition[];\n\n /** A list of hierarchy specifications that define what nodes are going to be returned. */\n specifications?: ChildNodeSpecification[];\n}\n"]}
|
|
1
|
+
{"version":3,"file":"SubCondition.js","sourceRoot":"","sources":["../../../../../src/presentation-common/rules/hierarchy/SubCondition.ts"],"names":[],"mappings":";AAAA;;;gGAGgG;AAChG,qDAAqD;AACrD;;GAEG","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\n/* eslint-disable @typescript-eslint/no-deprecated */\n/** @packageDocumentation\n * @module PresentationRules\n */\n\nimport { RequiredSchemaSpecification } from \"../SchemasSpecification.js\";\nimport { ChildNodeSpecification } from \"./ChildNodeSpecification.js\";\n\n/**\n * This is a sub-rule which shares *placement attributes* and\n * [nested customization rules]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-customizationrules)\n * of the hierarchy rule. This means the attributes of hierarchy rule are still in effect and the sub-rules\n * can add additional condition of their own.\n *\n * @see [Sub-conditions reference documentation section]($docs/presentation/hierarchies/ChildNodeRule.md#attribute-subconditions)\n * @public\n * @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)\n * package for creating hierarchies.\n */\nexport interface SubCondition {\n /**\n * Defines a condition which needs to be met in order for the rule to be used. The condition is an\n * [ECExpression]($docs/presentation/hierarchies/ECExpressions.md#rule-condition) which has to evaluate\n * to a boolean value.\n */\n condition?: string;\n\n /**\n * Specifications that define [ECSchema requirements]($docs/presentation/RequiredSchemaSpecification.md) for\n * the rule to take effect.\n */\n requiredSchemas?: RequiredSchemaSpecification[];\n\n /**\n * A list of nested sub-rules which share *placement attributes* of this sub-condition. This means the\n * attributes of this sub-condition are still in effect and the sub-rules can add additional condition\n * of their own.\n */\n subConditions?: SubCondition[];\n\n /** A list of hierarchy specifications that define what nodes are going to be returned. */\n specifications?: ChildNodeSpecification[];\n}\n"]}
|
|
@@ -12,12 +12,17 @@ import { NodeKey } from "./hierarchy/Key.js";
|
|
|
12
12
|
export type Key = Readonly<NodeKey> | Readonly<InstanceKey> | Readonly<EntityProps>;
|
|
13
13
|
/** @public */
|
|
14
14
|
export declare namespace Key {
|
|
15
|
-
/**
|
|
16
|
-
|
|
15
|
+
/**
|
|
16
|
+
* Check if the supplied key is a `NodeKey`
|
|
17
|
+
*
|
|
18
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
19
|
+
* package for creating hierarchies.
|
|
20
|
+
*/
|
|
21
|
+
function isNodeKey(key: Key): key is Extract<Key, Readonly<NodeKey>>;
|
|
17
22
|
/** Check if the supplied key is an `InstanceKey` */
|
|
18
|
-
function isInstanceKey(key: Key): key is InstanceKey
|
|
23
|
+
function isInstanceKey(key: Key): key is Extract<Key, Readonly<InstanceKey>>;
|
|
19
24
|
/** Check if the supplied key is an `EntityProps` */
|
|
20
|
-
function isEntityProps(key: Key): key is EntityProps
|
|
25
|
+
function isEntityProps(key: Key): key is Extract<Key, Readonly<EntityProps>>;
|
|
21
26
|
}
|
|
22
27
|
/**
|
|
23
28
|
* A type for multiple keys that identify something in iModel.js application
|
|
@@ -31,7 +36,12 @@ export type Keys = ReadonlyArray<Key> | Readonly<KeySet>;
|
|
|
31
36
|
export interface KeySetJSON {
|
|
32
37
|
/** JSON representation of a list of instance keys */
|
|
33
38
|
instanceKeys: Array<[string, string]>;
|
|
34
|
-
/**
|
|
39
|
+
/**
|
|
40
|
+
* An array of serialized node keys
|
|
41
|
+
*
|
|
42
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
43
|
+
* package for creating hierarchies.
|
|
44
|
+
*/
|
|
35
45
|
nodeKeys: NodeKey[];
|
|
36
46
|
}
|
|
37
47
|
/**
|
|
@@ -71,12 +81,17 @@ export declare class KeySet {
|
|
|
71
81
|
/**
|
|
72
82
|
* Get a set of node keys stored in this KeySet
|
|
73
83
|
*
|
|
74
|
-
* **Warning**: getting node keys might be expensive for
|
|
75
|
-
*
|
|
84
|
+
* **Warning**: getting node keys might be expensive for large KeySets.
|
|
85
|
+
*
|
|
86
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
87
|
+
* package for creating hierarchies.
|
|
76
88
|
*/
|
|
77
89
|
get nodeKeys(): Set<NodeKey>;
|
|
78
90
|
/**
|
|
79
91
|
* Get node keys count
|
|
92
|
+
*
|
|
93
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
94
|
+
* package for creating hierarchies.
|
|
80
95
|
*/
|
|
81
96
|
get nodeKeysCount(): number;
|
|
82
97
|
private isKeySet;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"KeySet.d.ts","sourceRoot":"","sources":["../../../src/presentation-common/KeySet.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"KeySet.d.ts","sourceRoot":"","sources":["../../../src/presentation-common/KeySet.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAmC,UAAU,EAAoB,MAAM,qBAAqB,CAAC;AACpG,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAE7C;;;GAGG;AAEH,MAAM,MAAM,GAAG,GAAG,QAAQ,CAAC,OAAO,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,CAAC;AAEpF,cAAc;AAEd,yBAAiB,GAAG,CAAC;IACnB;;;;;OAKG;IAEH,SAAgB,SAAS,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,IAAI,OAAO,CAAC,GAAG,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAC,CAG1E;IAED,oDAAoD;IACpD,SAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,IAAI,OAAO,CAAC,GAAG,EAAE,QAAQ,CAAC,WAAW,CAAC,CAAC,CAElF;IAED,oDAAoD;IACpD,SAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,IAAI,OAAO,CAAC,GAAG,EAAE,QAAQ,CAAC,WAAW,CAAC,CAAC,CAElF;CACF;AAED;;;GAGG;AACH,MAAM,MAAM,IAAI,GAAG,aAAa,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,MAAM,CAAC,CAAC;AAEzD;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB,qDAAqD;IACrD,YAAY,EAAE,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,CAAC;IACtC;;;;;OAKG;IAEH,QAAQ,EAAE,OAAO,EAAE,CAAC;CACrB;AAED;;;;;GAKG;AACH,qBAAa,MAAM;IAEjB,OAAO,CAAC,aAAa,CAA2B;IAChD,OAAO,CAAC,aAAa,CAAsB;IAC3C,OAAO,CAAC,SAAS,CAAc;IAC/B,OAAO,CAAC,KAAK,CAAc;IAE3B;;;OAGG;gBACS,MAAM,CAAC,EAAE,IAAI;IAUzB,OAAO,CAAC,eAAe;IAKvB;;;;OAIG;IACH,IAAW,IAAI,IAAI,UAAU,CAE5B;IAED;;;;;OAKG;IACH,IAAW,YAAY,IAAI,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,UAAU,CAAC,CAAC,CAMtD;IAED;;OAEG;IACH,IAAW,iBAAiB,IAAI,MAAM,CAIrC;IAED;;;;;;;OAOG;IACH,IAAW,QAAQ,iBAOlB;IAED;;;;;OAKG;IACH,IAAW,aAAa,IAAI,MAAM,CAEjC;IAED,OAAO,CAAC,QAAQ;IAIhB,OAAO,CAAC,WAAW;IAInB;;;OAGG;IACI,KAAK,IAAI,MAAM;IAYtB,OAAO,CAAC,SAAS;IAsBjB,OAAO,CAAC,aAAa;IAgBrB;;;;;OAKG;IACI,GAAG,CAAC,KAAK,EAAE,IAAI,GAAG,GAAG,EAAE,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,OAAO,GAAG,MAAM;IA4BnE,OAAO,CAAC,YAAY;IAcpB;;;;OAIG;IACI,MAAM,CAAC,KAAK,EAAE,IAAI,GAAG,GAAG,GAAG,MAAM;IA0BxC;;;OAGG;IACI,GAAG,CAAC,KAAK,EAAE,GAAG,GAAG,OAAO;IAc/B,OAAO,CAAC,SAAS;IAoCjB,OAAO,CAAC,YAAY;IAsBpB;;;OAGG;IACI,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO;IAQlC;;;OAGG;IACI,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO;IAQlC;;OAEG;IACH,IAAW,IAAI,IAAI,MAAM,CAOxB;IAED;;OAEG;IACH,IAAW,OAAO,IAAI,OAAO,CAE5B;IAED,4CAA4C;IACrC,IAAI,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,OAAO;IAU3C,4CAA4C;IAErC,OAAO,CAAC,QAAQ,EAAE,CAAC,GAAG,EAAE,WAAW,GAAG,OAAO,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI;IAW5E,sDAAsD;IAC/C,YAAY,CAAC,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI;IAqBvF;;;OAGG;IACI,MAAM,IAAI,UAAU;IAoB3B;;;OAGG;WACW,QAAQ,CAAC,IAAI,EAAE,UAAU,GAAG,MAAM;CAKjD"}
|
|
@@ -5,14 +5,20 @@
|
|
|
5
5
|
/** @packageDocumentation
|
|
6
6
|
* @module Core
|
|
7
7
|
*/
|
|
8
|
-
import { CompressedId64Set, Guid, Id64 } from "@itwin/core-bentley";
|
|
9
|
-
import { PresentationError, PresentationStatus } from "./Error.js";
|
|
8
|
+
import { assert, CompressedId64Set, Guid, Id64 } from "@itwin/core-bentley";
|
|
10
9
|
/** @public */
|
|
11
10
|
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
12
11
|
export var Key;
|
|
13
12
|
(function (Key) {
|
|
14
|
-
/**
|
|
13
|
+
/**
|
|
14
|
+
* Check if the supplied key is a `NodeKey`
|
|
15
|
+
*
|
|
16
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
17
|
+
* package for creating hierarchies.
|
|
18
|
+
*/
|
|
19
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
15
20
|
function isNodeKey(key) {
|
|
21
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
16
22
|
return !!key.type;
|
|
17
23
|
}
|
|
18
24
|
Key.isNodeKey = isNodeKey;
|
|
@@ -88,10 +94,13 @@ export class KeySet {
|
|
|
88
94
|
/**
|
|
89
95
|
* Get a set of node keys stored in this KeySet
|
|
90
96
|
*
|
|
91
|
-
* **Warning**: getting node keys might be expensive for
|
|
92
|
-
*
|
|
97
|
+
* **Warning**: getting node keys might be expensive for large KeySets.
|
|
98
|
+
*
|
|
99
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
100
|
+
* package for creating hierarchies.
|
|
93
101
|
*/
|
|
94
102
|
get nodeKeys() {
|
|
103
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
95
104
|
const set = new Set();
|
|
96
105
|
for (const serialized of this._nodeKeys) {
|
|
97
106
|
set.add(JSON.parse(serialized));
|
|
@@ -100,6 +109,9 @@ export class KeySet {
|
|
|
100
109
|
}
|
|
101
110
|
/**
|
|
102
111
|
* Get node keys count
|
|
112
|
+
*
|
|
113
|
+
* @deprecated in 5.2. Use the new [@itwin/presentation-hierarchies](https://github.com/iTwin/presentation/blob/master/packages/hierarchies/README.md)
|
|
114
|
+
* package for creating hierarchies.
|
|
103
115
|
*/
|
|
104
116
|
get nodeKeysCount() {
|
|
105
117
|
return this._nodeKeys.size;
|
|
@@ -146,6 +158,7 @@ export class KeySet {
|
|
|
146
158
|
}
|
|
147
159
|
}
|
|
148
160
|
addKeySetJSON(keyset) {
|
|
161
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
149
162
|
for (const key of keyset.nodeKeys) {
|
|
150
163
|
this._nodeKeys.add(JSON.stringify(key));
|
|
151
164
|
}
|
|
@@ -165,9 +178,6 @@ export class KeySet {
|
|
|
165
178
|
* @returns itself
|
|
166
179
|
*/
|
|
167
180
|
add(value, pred) {
|
|
168
|
-
if (!value) {
|
|
169
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);
|
|
170
|
-
}
|
|
171
181
|
const sizeBefore = this.size;
|
|
172
182
|
if (this.isKeySet(value)) {
|
|
173
183
|
this.addKeySet(value, pred);
|
|
@@ -187,13 +197,11 @@ export class KeySet {
|
|
|
187
197
|
}
|
|
188
198
|
this._lowerCaseMap.set(lcClassName, normalizedClassName);
|
|
189
199
|
this._instanceKeys.get(lcClassName).add(value.id);
|
|
200
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
190
201
|
}
|
|
191
202
|
else if (Key.isNodeKey(value)) {
|
|
192
203
|
this._nodeKeys.add(JSON.stringify(value));
|
|
193
204
|
}
|
|
194
|
-
else {
|
|
195
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${JSON.stringify(value)}`);
|
|
196
|
-
}
|
|
197
205
|
}
|
|
198
206
|
if (this.size !== sizeBefore) {
|
|
199
207
|
this.recalculateGuid();
|
|
@@ -219,9 +227,6 @@ export class KeySet {
|
|
|
219
227
|
* @returns itself
|
|
220
228
|
*/
|
|
221
229
|
delete(value) {
|
|
222
|
-
if (!value) {
|
|
223
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);
|
|
224
|
-
}
|
|
225
230
|
const sizeBefore = this.size;
|
|
226
231
|
if (this.isKeySet(value)) {
|
|
227
232
|
this.deleteKeySet(value);
|
|
@@ -240,13 +245,11 @@ export class KeySet {
|
|
|
240
245
|
if (set) {
|
|
241
246
|
set.delete(value.id);
|
|
242
247
|
}
|
|
248
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
243
249
|
}
|
|
244
250
|
else if (Key.isNodeKey(value)) {
|
|
245
251
|
this._nodeKeys.delete(JSON.stringify(value));
|
|
246
252
|
}
|
|
247
|
-
else {
|
|
248
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${JSON.stringify(value)}`);
|
|
249
|
-
}
|
|
250
253
|
if (this.size !== sizeBefore) {
|
|
251
254
|
this.recalculateGuid();
|
|
252
255
|
}
|
|
@@ -257,9 +260,6 @@ export class KeySet {
|
|
|
257
260
|
* @param value The key to check.
|
|
258
261
|
*/
|
|
259
262
|
has(value) {
|
|
260
|
-
if (!value) {
|
|
261
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${value}`);
|
|
262
|
-
}
|
|
263
263
|
if (Key.isEntityProps(value)) {
|
|
264
264
|
return this.has({ className: value.classFullName, id: value.id });
|
|
265
265
|
}
|
|
@@ -268,10 +268,9 @@ export class KeySet {
|
|
|
268
268
|
const set = this._instanceKeys.get(normalizedClassName.toLowerCase());
|
|
269
269
|
return !!(set && set.has(value.id));
|
|
270
270
|
}
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${JSON.stringify(value)}`);
|
|
271
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
272
|
+
assert(Key.isNodeKey(value));
|
|
273
|
+
return this._nodeKeys.has(JSON.stringify(value));
|
|
275
274
|
}
|
|
276
275
|
hasKeySet(readonlyKeys, checkType) {
|
|
277
276
|
// note: cast-away read-onlyness to access private members...
|
|
@@ -331,32 +330,22 @@ export class KeySet {
|
|
|
331
330
|
* @param keys The keys to check.
|
|
332
331
|
*/
|
|
333
332
|
hasAll(keys) {
|
|
334
|
-
if (!keys) {
|
|
335
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);
|
|
336
|
-
}
|
|
337
333
|
if (this.isKeySet(keys)) {
|
|
338
334
|
return this.hasKeySet(keys, "all");
|
|
339
335
|
}
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
}
|
|
343
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);
|
|
336
|
+
assert(this.isKeysArray(keys));
|
|
337
|
+
return this.hasKeysArray(keys, "all");
|
|
344
338
|
}
|
|
345
339
|
/**
|
|
346
340
|
* Check if this KeySet contains any of the specified keys.
|
|
347
341
|
* @param keys The keys to check.
|
|
348
342
|
*/
|
|
349
343
|
hasAny(keys) {
|
|
350
|
-
if (!keys) {
|
|
351
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: value = ${keys}`);
|
|
352
|
-
}
|
|
353
344
|
if (this.isKeySet(keys)) {
|
|
354
345
|
return this.hasKeySet(keys, "any");
|
|
355
346
|
}
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
}
|
|
359
|
-
throw new PresentationError(PresentationStatus.InvalidArgument, `Invalid argument: keys = ${keys}`);
|
|
347
|
+
assert(this.isKeysArray(keys));
|
|
348
|
+
return this.hasKeysArray(keys, "any");
|
|
360
349
|
}
|
|
361
350
|
/**
|
|
362
351
|
* Get the number of keys stored in this KeySet.
|
|
@@ -386,6 +375,7 @@ export class KeySet {
|
|
|
386
375
|
return some(this._nodeKeys, (serializedKey) => callback(JSON.parse(serializedKey)));
|
|
387
376
|
}
|
|
388
377
|
/** Iterate over all keys in this keyset. */
|
|
378
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
389
379
|
forEach(callback) {
|
|
390
380
|
let index = 0;
|
|
391
381
|
this._instanceKeys.forEach((ids, className) => {
|
|
@@ -430,6 +420,7 @@ export class KeySet {
|
|
|
430
420
|
instanceKeys.push([className, compressedIds.length > 0 ? compressedIds : Id64.invalid]);
|
|
431
421
|
}
|
|
432
422
|
}
|
|
423
|
+
// eslint-disable-next-line @typescript-eslint/no-deprecated
|
|
433
424
|
const nodeKeys = [];
|
|
434
425
|
for (const serializedKey of this._nodeKeys.values()) {
|
|
435
426
|
nodeKeys.push(JSON.parse(serializedKey));
|