@itwin/core-backend 3.0.0-dev.76 → 3.0.0-dev.80
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/lib/{AliCloudStorageService.d.ts → cjs/AliCloudStorageService.d.ts} +0 -0
- package/lib/cjs/AliCloudStorageService.d.ts.map +1 -0
- package/lib/{AliCloudStorageService.js → cjs/AliCloudStorageService.js} +0 -0
- package/lib/cjs/AliCloudStorageService.js.map +1 -0
- package/lib/{BackendHubAccess.d.ts → cjs/BackendHubAccess.d.ts} +0 -0
- package/lib/cjs/BackendHubAccess.d.ts.map +1 -0
- package/lib/{BackendHubAccess.js → cjs/BackendHubAccess.js} +0 -0
- package/lib/cjs/BackendHubAccess.js.map +1 -0
- package/lib/{BackendLoggerCategory.d.ts → cjs/BackendLoggerCategory.d.ts} +0 -0
- package/lib/cjs/BackendLoggerCategory.d.ts.map +1 -0
- package/lib/{BackendLoggerCategory.js → cjs/BackendLoggerCategory.js} +0 -0
- package/lib/cjs/BackendLoggerCategory.js.map +1 -0
- package/lib/{BisCoreSchema.d.ts → cjs/BisCoreSchema.d.ts} +0 -0
- package/lib/cjs/BisCoreSchema.d.ts.map +1 -0
- package/lib/{BisCoreSchema.js → cjs/BisCoreSchema.js} +0 -0
- package/lib/cjs/BisCoreSchema.js.map +1 -0
- package/lib/{BriefcaseManager.d.ts → cjs/BriefcaseManager.d.ts} +0 -0
- package/lib/cjs/BriefcaseManager.d.ts.map +1 -0
- package/lib/{BriefcaseManager.js → cjs/BriefcaseManager.js} +2 -2
- package/lib/cjs/BriefcaseManager.js.map +1 -0
- package/lib/{Category.d.ts → cjs/Category.d.ts} +0 -0
- package/lib/cjs/Category.d.ts.map +1 -0
- package/lib/{Category.js → cjs/Category.js} +0 -0
- package/lib/cjs/Category.js.map +1 -0
- package/lib/{ChangeSummaryManager.d.ts → cjs/ChangeSummaryManager.d.ts} +1 -1
- package/lib/cjs/ChangeSummaryManager.d.ts.map +1 -0
- package/lib/{ChangeSummaryManager.js → cjs/ChangeSummaryManager.js} +0 -0
- package/lib/cjs/ChangeSummaryManager.js.map +1 -0
- package/lib/{ChangedElementsDb.d.ts → cjs/ChangedElementsDb.d.ts} +0 -0
- package/lib/cjs/ChangedElementsDb.d.ts.map +1 -0
- package/lib/{ChangedElementsDb.js → cjs/ChangedElementsDb.js} +0 -0
- package/lib/cjs/ChangedElementsDb.js.map +1 -0
- package/lib/{ChangedElementsManager.d.ts → cjs/ChangedElementsManager.d.ts} +0 -0
- package/lib/cjs/ChangedElementsManager.d.ts.map +1 -0
- package/lib/{ChangedElementsManager.js → cjs/ChangedElementsManager.js} +0 -0
- package/lib/cjs/ChangedElementsManager.js.map +1 -0
- package/lib/{CheckpointManager.d.ts → cjs/CheckpointManager.d.ts} +3 -1
- package/lib/cjs/CheckpointManager.d.ts.map +1 -0
- package/lib/{CheckpointManager.js → cjs/CheckpointManager.js} +2 -2
- package/lib/cjs/CheckpointManager.js.map +1 -0
- package/lib/{ClassRegistry.d.ts → cjs/ClassRegistry.d.ts} +0 -0
- package/lib/cjs/ClassRegistry.d.ts.map +1 -0
- package/lib/{ClassRegistry.js → cjs/ClassRegistry.js} +0 -0
- package/lib/cjs/ClassRegistry.js.map +1 -0
- package/lib/{CloudStorageBackend.d.ts → cjs/CloudStorageBackend.d.ts} +0 -0
- package/lib/cjs/CloudStorageBackend.d.ts.map +1 -0
- package/lib/{CloudStorageBackend.js → cjs/CloudStorageBackend.js} +3 -3
- package/lib/cjs/CloudStorageBackend.js.map +1 -0
- package/lib/{CodeSpecs.d.ts → cjs/CodeSpecs.d.ts} +0 -0
- package/lib/cjs/CodeSpecs.d.ts.map +1 -0
- package/lib/{CodeSpecs.js → cjs/CodeSpecs.js} +0 -0
- package/lib/cjs/CodeSpecs.js.map +1 -0
- package/lib/{ConcurrentQuery.d.ts → cjs/ConcurrentQuery.d.ts} +0 -0
- package/lib/cjs/ConcurrentQuery.d.ts.map +1 -0
- package/lib/{ConcurrentQuery.js → cjs/ConcurrentQuery.js} +0 -0
- package/lib/cjs/ConcurrentQuery.js.map +1 -0
- package/lib/{DevTools.d.ts → cjs/DevTools.d.ts} +0 -0
- package/lib/cjs/DevTools.d.ts.map +1 -0
- package/lib/{DevTools.js → cjs/DevTools.js} +3 -3
- package/lib/cjs/DevTools.js.map +1 -0
- package/lib/{DisplayStyle.d.ts → cjs/DisplayStyle.d.ts} +0 -0
- package/lib/cjs/DisplayStyle.d.ts.map +1 -0
- package/lib/{DisplayStyle.js → cjs/DisplayStyle.js} +5 -2
- package/lib/cjs/DisplayStyle.js.map +1 -0
- package/lib/{ECDb.d.ts → cjs/ECDb.d.ts} +0 -0
- package/lib/cjs/ECDb.d.ts.map +1 -0
- package/lib/{ECDb.js → cjs/ECDb.js} +51 -85
- package/lib/cjs/ECDb.js.map +1 -0
- package/lib/{ECSchemaXmlContext.d.ts → cjs/ECSchemaXmlContext.d.ts} +0 -0
- package/lib/cjs/ECSchemaXmlContext.d.ts.map +1 -0
- package/lib/{ECSchemaXmlContext.js → cjs/ECSchemaXmlContext.js} +0 -0
- package/lib/cjs/ECSchemaXmlContext.js.map +1 -0
- package/lib/{ECSqlStatement.d.ts → cjs/ECSqlStatement.d.ts} +0 -0
- package/lib/cjs/ECSqlStatement.d.ts.map +1 -0
- package/lib/{ECSqlStatement.js → cjs/ECSqlStatement.js} +0 -0
- package/lib/cjs/ECSqlStatement.js.map +1 -0
- package/lib/{Element.d.ts → cjs/Element.d.ts} +0 -0
- package/lib/cjs/Element.d.ts.map +1 -0
- package/lib/{Element.js → cjs/Element.js} +11 -4
- package/lib/cjs/Element.js.map +1 -0
- package/lib/{ElementAspect.d.ts → cjs/ElementAspect.d.ts} +0 -0
- package/lib/cjs/ElementAspect.d.ts.map +1 -0
- package/lib/{ElementAspect.js → cjs/ElementAspect.js} +0 -0
- package/lib/cjs/ElementAspect.js.map +1 -0
- package/lib/{ElementGraphics.d.ts → cjs/ElementGraphics.d.ts} +0 -0
- package/lib/cjs/ElementGraphics.d.ts.map +1 -0
- package/lib/{ElementGraphics.js → cjs/ElementGraphics.js} +0 -0
- package/lib/cjs/ElementGraphics.js.map +1 -0
- package/lib/{Entity.d.ts → cjs/Entity.d.ts} +0 -0
- package/lib/cjs/Entity.d.ts.map +1 -0
- package/lib/{Entity.js → cjs/Entity.js} +0 -0
- package/lib/cjs/Entity.js.map +1 -0
- package/lib/{ExportGraphics.d.ts → cjs/ExportGraphics.d.ts} +0 -0
- package/lib/cjs/ExportGraphics.d.ts.map +1 -0
- package/lib/{ExportGraphics.js → cjs/ExportGraphics.js} +0 -0
- package/lib/cjs/ExportGraphics.js.map +1 -0
- package/lib/{ExternalSource.d.ts → cjs/ExternalSource.d.ts} +0 -0
- package/lib/cjs/ExternalSource.d.ts.map +1 -0
- package/lib/{ExternalSource.js → cjs/ExternalSource.js} +0 -0
- package/lib/cjs/ExternalSource.js.map +1 -0
- package/lib/{GeometrySummary.d.ts → cjs/GeometrySummary.d.ts} +0 -0
- package/lib/cjs/GeometrySummary.d.ts.map +1 -0
- package/lib/{GeometrySummary.js → cjs/GeometrySummary.js} +0 -0
- package/lib/cjs/GeometrySummary.js.map +1 -0
- package/lib/{IModelCloneContext.d.ts → cjs/IModelCloneContext.d.ts} +0 -0
- package/lib/cjs/IModelCloneContext.d.ts.map +1 -0
- package/lib/{IModelCloneContext.js → cjs/IModelCloneContext.js} +0 -0
- package/lib/cjs/IModelCloneContext.js.map +1 -0
- package/lib/{IModelDb.d.ts → cjs/IModelDb.d.ts} +4 -6
- package/lib/cjs/IModelDb.d.ts.map +1 -0
- package/lib/{IModelDb.js → cjs/IModelDb.js} +99 -104
- package/lib/cjs/IModelDb.js.map +1 -0
- package/lib/{IModelHost.d.ts → cjs/IModelHost.d.ts} +1 -2
- package/lib/cjs/IModelHost.d.ts.map +1 -0
- package/lib/{IModelHost.js → cjs/IModelHost.js} +11 -6
- package/lib/cjs/IModelHost.js.map +1 -0
- package/lib/{IModelHubBackend.d.ts → cjs/IModelHubBackend.d.ts} +0 -0
- package/lib/cjs/IModelHubBackend.d.ts.map +1 -0
- package/lib/{IModelHubBackend.js → cjs/IModelHubBackend.js} +6 -6
- package/lib/cjs/IModelHubBackend.js.map +1 -0
- package/lib/{IModelJsFs.d.ts → cjs/IModelJsFs.d.ts} +0 -0
- package/lib/cjs/IModelJsFs.d.ts.map +1 -0
- package/lib/{IModelJsFs.js → cjs/IModelJsFs.js} +0 -0
- package/lib/cjs/IModelJsFs.js.map +1 -0
- package/lib/{IModelSchemaLoader.d.ts → cjs/IModelSchemaLoader.d.ts} +0 -0
- package/lib/cjs/IModelSchemaLoader.d.ts.map +1 -0
- package/lib/{IModelSchemaLoader.js → cjs/IModelSchemaLoader.js} +0 -0
- package/lib/cjs/IModelSchemaLoader.js.map +1 -0
- package/lib/{IpcHost.d.ts → cjs/IpcHost.d.ts} +0 -0
- package/lib/cjs/IpcHost.d.ts.map +1 -0
- package/lib/{IpcHost.js → cjs/IpcHost.js} +0 -0
- package/lib/cjs/IpcHost.js.map +1 -0
- package/lib/{LineStyle.d.ts → cjs/LineStyle.d.ts} +0 -0
- package/lib/cjs/LineStyle.d.ts.map +1 -0
- package/lib/{LineStyle.js → cjs/LineStyle.js} +0 -0
- package/lib/cjs/LineStyle.js.map +1 -0
- package/lib/{LocalhostIpcHost.d.ts → cjs/LocalhostIpcHost.d.ts} +0 -0
- package/lib/cjs/LocalhostIpcHost.d.ts.map +1 -0
- package/lib/{LocalhostIpcHost.js → cjs/LocalhostIpcHost.js} +0 -0
- package/lib/cjs/LocalhostIpcHost.js.map +1 -0
- package/lib/{Material.d.ts → cjs/Material.d.ts} +0 -0
- package/lib/cjs/Material.d.ts.map +1 -0
- package/lib/{Material.js → cjs/Material.js} +0 -0
- package/lib/cjs/Material.js.map +1 -0
- package/lib/{Model.d.ts → cjs/Model.d.ts} +0 -0
- package/lib/cjs/Model.d.ts.map +1 -0
- package/lib/{Model.js → cjs/Model.js} +1 -1
- package/lib/cjs/Model.js.map +1 -0
- package/lib/{NativeAppStorage.d.ts → cjs/NativeAppStorage.d.ts} +0 -0
- package/lib/cjs/NativeAppStorage.d.ts.map +1 -0
- package/lib/{NativeAppStorage.js → cjs/NativeAppStorage.js} +0 -0
- package/lib/cjs/NativeAppStorage.js.map +1 -0
- package/lib/{NativeHost.d.ts → cjs/NativeHost.d.ts} +2 -2
- package/lib/cjs/NativeHost.d.ts.map +1 -0
- package/lib/{NativeHost.js → cjs/NativeHost.js} +4 -1
- package/lib/cjs/NativeHost.js.map +1 -0
- package/lib/{NavigationRelationship.d.ts → cjs/NavigationRelationship.d.ts} +0 -0
- package/lib/cjs/NavigationRelationship.d.ts.map +1 -0
- package/lib/{NavigationRelationship.js → cjs/NavigationRelationship.js} +0 -0
- package/lib/cjs/NavigationRelationship.js.map +1 -0
- package/lib/{PromiseMemoizer.d.ts → cjs/PromiseMemoizer.d.ts} +0 -0
- package/lib/cjs/PromiseMemoizer.d.ts.map +1 -0
- package/lib/{PromiseMemoizer.js → cjs/PromiseMemoizer.js} +0 -0
- package/lib/cjs/PromiseMemoizer.js.map +1 -0
- package/lib/{Relationship.d.ts → cjs/Relationship.d.ts} +0 -0
- package/lib/cjs/Relationship.d.ts.map +1 -0
- package/lib/{Relationship.js → cjs/Relationship.js} +0 -0
- package/lib/cjs/Relationship.js.map +1 -0
- package/lib/{RpcBackend.d.ts → cjs/RpcBackend.d.ts} +0 -0
- package/lib/cjs/RpcBackend.d.ts.map +1 -0
- package/lib/{RpcBackend.js → cjs/RpcBackend.js} +0 -0
- package/lib/cjs/RpcBackend.js.map +1 -0
- package/lib/{SQLiteDb.d.ts → cjs/SQLiteDb.d.ts} +0 -0
- package/lib/cjs/SQLiteDb.d.ts.map +1 -0
- package/lib/{SQLiteDb.js → cjs/SQLiteDb.js} +0 -0
- package/lib/cjs/SQLiteDb.js.map +1 -0
- package/lib/{Schema.d.ts → cjs/Schema.d.ts} +0 -0
- package/lib/cjs/Schema.d.ts.map +1 -0
- package/lib/{Schema.js → cjs/Schema.js} +0 -0
- package/lib/cjs/Schema.js.map +1 -0
- package/lib/{ServerBasedLocks.d.ts → cjs/ServerBasedLocks.d.ts} +0 -0
- package/lib/cjs/ServerBasedLocks.d.ts.map +1 -0
- package/lib/{ServerBasedLocks.js → cjs/ServerBasedLocks.js} +0 -0
- package/lib/cjs/ServerBasedLocks.js.map +1 -0
- package/lib/{SqliteStatement.d.ts → cjs/SqliteStatement.d.ts} +0 -0
- package/lib/cjs/SqliteStatement.d.ts.map +1 -0
- package/lib/{SqliteStatement.js → cjs/SqliteStatement.js} +0 -0
- package/lib/cjs/SqliteStatement.js.map +1 -0
- package/lib/{Texture.d.ts → cjs/Texture.d.ts} +0 -0
- package/lib/cjs/Texture.d.ts.map +1 -0
- package/lib/{Texture.js → cjs/Texture.js} +0 -0
- package/lib/cjs/Texture.js.map +1 -0
- package/lib/{TxnManager.d.ts → cjs/TxnManager.d.ts} +0 -0
- package/lib/cjs/TxnManager.d.ts.map +1 -0
- package/lib/{TxnManager.js → cjs/TxnManager.js} +0 -0
- package/lib/cjs/TxnManager.js.map +1 -0
- package/lib/{ViewDefinition.d.ts → cjs/ViewDefinition.d.ts} +0 -0
- package/lib/cjs/ViewDefinition.d.ts.map +1 -0
- package/lib/{ViewDefinition.js → cjs/ViewDefinition.js} +0 -0
- package/lib/cjs/ViewDefinition.js.map +1 -0
- package/lib/{assets → cjs/assets}/IModelChange.02.00.00.ecschema.xml +0 -0
- package/lib/{core-backend.d.ts → cjs/core-backend.d.ts} +0 -0
- package/lib/cjs/core-backend.d.ts.map +1 -0
- package/lib/{core-backend.js → cjs/core-backend.js} +0 -0
- package/lib/cjs/core-backend.js.map +1 -0
- package/lib/{domains → cjs/domains}/FunctionalElements.d.ts +0 -0
- package/lib/cjs/domains/FunctionalElements.d.ts.map +1 -0
- package/lib/{domains → cjs/domains}/FunctionalElements.js +0 -0
- package/lib/cjs/domains/FunctionalElements.js.map +1 -0
- package/lib/{domains → cjs/domains}/FunctionalSchema.d.ts +0 -0
- package/lib/cjs/domains/FunctionalSchema.d.ts.map +1 -0
- package/lib/{domains → cjs/domains}/FunctionalSchema.js +0 -0
- package/lib/cjs/domains/FunctionalSchema.js.map +1 -0
- package/lib/{domains → cjs/domains}/GenericElements.d.ts +0 -0
- package/lib/cjs/domains/GenericElements.d.ts.map +1 -0
- package/lib/{domains → cjs/domains}/GenericElements.js +0 -0
- package/lib/cjs/domains/GenericElements.js.map +1 -0
- package/lib/{domains → cjs/domains}/GenericSchema.d.ts +0 -0
- package/lib/cjs/domains/GenericSchema.d.ts.map +1 -0
- package/lib/{domains → cjs/domains}/GenericSchema.js +0 -0
- package/lib/cjs/domains/GenericSchema.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/DevToolsRpcImpl.d.ts +0 -0
- package/lib/cjs/rpc-impl/DevToolsRpcImpl.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/DevToolsRpcImpl.js +0 -0
- package/lib/cjs/rpc-impl/DevToolsRpcImpl.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/IModelReadRpcImpl.d.ts +0 -0
- package/lib/cjs/rpc-impl/IModelReadRpcImpl.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/IModelReadRpcImpl.js +1 -1
- package/lib/cjs/rpc-impl/IModelReadRpcImpl.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/IModelTileRpcImpl.d.ts +0 -0
- package/lib/cjs/rpc-impl/IModelTileRpcImpl.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/IModelTileRpcImpl.js +6 -3
- package/lib/cjs/rpc-impl/IModelTileRpcImpl.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/RpcBriefcaseUtility.d.ts +0 -0
- package/lib/cjs/rpc-impl/RpcBriefcaseUtility.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/RpcBriefcaseUtility.js +9 -8
- package/lib/cjs/rpc-impl/RpcBriefcaseUtility.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/SnapshotIModelRpcImpl.d.ts +0 -0
- package/lib/cjs/rpc-impl/SnapshotIModelRpcImpl.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/SnapshotIModelRpcImpl.js +1 -1
- package/lib/cjs/rpc-impl/SnapshotIModelRpcImpl.js.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/WipRpcImpl.d.ts +1 -2
- package/lib/cjs/rpc-impl/WipRpcImpl.d.ts.map +1 -0
- package/lib/{rpc-impl → cjs/rpc-impl}/WipRpcImpl.js +1 -2
- package/lib/cjs/rpc-impl/WipRpcImpl.js.map +1 -0
- package/package.json +37 -41
- package/lib/AliCloudStorageService.d.ts.map +0 -1
- package/lib/AliCloudStorageService.js.map +0 -1
- package/lib/BackendHubAccess.d.ts.map +0 -1
- package/lib/BackendHubAccess.js.map +0 -1
- package/lib/BackendLoggerCategory.d.ts.map +0 -1
- package/lib/BackendLoggerCategory.js.map +0 -1
- package/lib/BisCoreSchema.d.ts.map +0 -1
- package/lib/BisCoreSchema.js.map +0 -1
- package/lib/BriefcaseManager.d.ts.map +0 -1
- package/lib/BriefcaseManager.js.map +0 -1
- package/lib/Category.d.ts.map +0 -1
- package/lib/Category.js.map +0 -1
- package/lib/ChangeSummaryManager.d.ts.map +0 -1
- package/lib/ChangeSummaryManager.js.map +0 -1
- package/lib/ChangedElementsDb.d.ts.map +0 -1
- package/lib/ChangedElementsDb.js.map +0 -1
- package/lib/ChangedElementsManager.d.ts.map +0 -1
- package/lib/ChangedElementsManager.js.map +0 -1
- package/lib/CheckpointManager.d.ts.map +0 -1
- package/lib/CheckpointManager.js.map +0 -1
- package/lib/ClassRegistry.d.ts.map +0 -1
- package/lib/ClassRegistry.js.map +0 -1
- package/lib/CloudStorageBackend.d.ts.map +0 -1
- package/lib/CloudStorageBackend.js.map +0 -1
- package/lib/CodeSpecs.d.ts.map +0 -1
- package/lib/CodeSpecs.js.map +0 -1
- package/lib/ConcurrentQuery.d.ts.map +0 -1
- package/lib/ConcurrentQuery.js.map +0 -1
- package/lib/DevTools.d.ts.map +0 -1
- package/lib/DevTools.js.map +0 -1
- package/lib/DisplayStyle.d.ts.map +0 -1
- package/lib/DisplayStyle.js.map +0 -1
- package/lib/ECDb.d.ts.map +0 -1
- package/lib/ECDb.js.map +0 -1
- package/lib/ECSchemaXmlContext.d.ts.map +0 -1
- package/lib/ECSchemaXmlContext.js.map +0 -1
- package/lib/ECSqlStatement.d.ts.map +0 -1
- package/lib/ECSqlStatement.js.map +0 -1
- package/lib/Element.d.ts.map +0 -1
- package/lib/Element.js.map +0 -1
- package/lib/ElementAspect.d.ts.map +0 -1
- package/lib/ElementAspect.js.map +0 -1
- package/lib/ElementGraphics.d.ts.map +0 -1
- package/lib/ElementGraphics.js.map +0 -1
- package/lib/Entity.d.ts.map +0 -1
- package/lib/Entity.js.map +0 -1
- package/lib/ExportGraphics.d.ts.map +0 -1
- package/lib/ExportGraphics.js.map +0 -1
- package/lib/ExternalSource.d.ts.map +0 -1
- package/lib/ExternalSource.js.map +0 -1
- package/lib/GeometrySummary.d.ts.map +0 -1
- package/lib/GeometrySummary.js.map +0 -1
- package/lib/IModelCloneContext.d.ts.map +0 -1
- package/lib/IModelCloneContext.js.map +0 -1
- package/lib/IModelDb.d.ts.map +0 -1
- package/lib/IModelDb.js.map +0 -1
- package/lib/IModelHost.d.ts.map +0 -1
- package/lib/IModelHost.js.map +0 -1
- package/lib/IModelHubBackend.d.ts.map +0 -1
- package/lib/IModelHubBackend.js.map +0 -1
- package/lib/IModelJsFs.d.ts.map +0 -1
- package/lib/IModelJsFs.js.map +0 -1
- package/lib/IModelSchemaLoader.d.ts.map +0 -1
- package/lib/IModelSchemaLoader.js.map +0 -1
- package/lib/IpcHost.d.ts.map +0 -1
- package/lib/IpcHost.js.map +0 -1
- package/lib/LineStyle.d.ts.map +0 -1
- package/lib/LineStyle.js.map +0 -1
- package/lib/LocalhostIpcHost.d.ts.map +0 -1
- package/lib/LocalhostIpcHost.js.map +0 -1
- package/lib/Material.d.ts.map +0 -1
- package/lib/Material.js.map +0 -1
- package/lib/Model.d.ts.map +0 -1
- package/lib/Model.js.map +0 -1
- package/lib/NativeAppStorage.d.ts.map +0 -1
- package/lib/NativeAppStorage.js.map +0 -1
- package/lib/NativeHost.d.ts.map +0 -1
- package/lib/NativeHost.js.map +0 -1
- package/lib/NavigationRelationship.d.ts.map +0 -1
- package/lib/NavigationRelationship.js.map +0 -1
- package/lib/PromiseMemoizer.d.ts.map +0 -1
- package/lib/PromiseMemoizer.js.map +0 -1
- package/lib/Relationship.d.ts.map +0 -1
- package/lib/Relationship.js.map +0 -1
- package/lib/RpcBackend.d.ts.map +0 -1
- package/lib/RpcBackend.js.map +0 -1
- package/lib/SQLiteDb.d.ts.map +0 -1
- package/lib/SQLiteDb.js.map +0 -1
- package/lib/Schema.d.ts.map +0 -1
- package/lib/Schema.js.map +0 -1
- package/lib/ServerBasedLocks.d.ts.map +0 -1
- package/lib/ServerBasedLocks.js.map +0 -1
- package/lib/SqliteStatement.d.ts.map +0 -1
- package/lib/SqliteStatement.js.map +0 -1
- package/lib/Texture.d.ts.map +0 -1
- package/lib/Texture.js.map +0 -1
- package/lib/TxnManager.d.ts.map +0 -1
- package/lib/TxnManager.js.map +0 -1
- package/lib/ViewDefinition.d.ts.map +0 -1
- package/lib/ViewDefinition.js.map +0 -1
- package/lib/core-backend.d.ts.map +0 -1
- package/lib/core-backend.js.map +0 -1
- package/lib/domains/FunctionalElements.d.ts.map +0 -1
- package/lib/domains/FunctionalElements.js.map +0 -1
- package/lib/domains/FunctionalSchema.d.ts.map +0 -1
- package/lib/domains/FunctionalSchema.js.map +0 -1
- package/lib/domains/GenericElements.d.ts.map +0 -1
- package/lib/domains/GenericElements.js.map +0 -1
- package/lib/domains/GenericSchema.d.ts.map +0 -1
- package/lib/domains/GenericSchema.js.map +0 -1
- package/lib/rpc-impl/DevToolsRpcImpl.d.ts.map +0 -1
- package/lib/rpc-impl/DevToolsRpcImpl.js.map +0 -1
- package/lib/rpc-impl/IModelReadRpcImpl.d.ts.map +0 -1
- package/lib/rpc-impl/IModelReadRpcImpl.js.map +0 -1
- package/lib/rpc-impl/IModelTileRpcImpl.d.ts.map +0 -1
- package/lib/rpc-impl/IModelTileRpcImpl.js.map +0 -1
- package/lib/rpc-impl/RpcBriefcaseUtility.d.ts.map +0 -1
- package/lib/rpc-impl/RpcBriefcaseUtility.js.map +0 -1
- package/lib/rpc-impl/SnapshotIModelRpcImpl.d.ts.map +0 -1
- package/lib/rpc-impl/SnapshotIModelRpcImpl.js.map +0 -1
- package/lib/rpc-impl/WipRpcImpl.d.ts.map +0 -1
- package/lib/rpc-impl/WipRpcImpl.js.map +0 -1
package/lib/Element.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Element.js","sourceRoot":"","sources":["../src/Element.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;;AAEH,sDAA4H;AAC5H,wDAAsE;AACtE,oDAM4B;AAC5B,qCAAkC;AAGlC,mCAAuE;AACvE,qEAA+D;AAmE/D;;;;;;;;;;;;;;;;GAgBG;AACH,MAAa,OAAQ,SAAQ,eAAM;IAmBjC;;OAEG;IACH,YAAY,KAAmB,EAAE,MAAgB;QAC/C,KAAK,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC;QACrB,IAAI,CAAC,IAAI,GAAG,kBAAI,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAE,0EAA0E;QAClH,IAAI,CAAC,KAAK,GAAG,4BAAc,CAAC,UAAU,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QACpD,IAAI,CAAC,MAAM,GAAG,4BAAc,CAAC,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QACpD,IAAI,CAAC,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC;QAC3C,IA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W,CAAC,OAAO,EAAE,IAAI,CAAC,gBAAgB,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;IAC9G,CAAC;IAED;;OAEG;IACI,MAAM,CAAC,WAAW,CAAC,OAA2B,EAAE,KAAiC;QACtF,MAAM,WAAW,GAA+B,EAAE,CAAC;QACnD,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;YACvB,OAAO,WAAW,CAAC;QAErB,MAAM,UAAU,GAAG,IAAI,+BAAgB,EAAE,CAAC;QAC1C,KAAK,MAAM,KAAK,IAAI,KAAK,EAAE;YACzB,MAAM,OAAO,GAAG,OAAO,CAAC,mBAAmB,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;YAC3D,IAAI,CAAC,mBAAI,CAAC,OAAO,CAAC,OAAO,CAAC;gBACxB,SAAS;YAEX,KAAK,CAAC,OAAO,GAAG,OAAO,CAAC;YACxB,WAAW,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YACxB,KAAK,MAAM,OAAO,IAAI,KAAK,CAAC,gBAAgB,EAAE;gBAC5C,UAAU,CAAC,KAAK,EAAE,CAAC;gBACnB,KAAK,MAAM,QAAQ,IAAI,4BAAc,CAAC,eAAe,CAAC,aAAa,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE;oBACvF,MAAM,QAAQ,GAAG,OAAO,CAAC,mBAAmB,CAAC,QAAQ,CAAC,CAAC;oBACvD,IAAI,mBAAI,CAAC,OAAO,CAAC,QAAQ,CAAC;wBACxB,UAAU,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;iBAC/B;gBAED,OAAO,CAAC,UAAU,GAAG,gCAAiB,CAAC,WAAW,CAAC,UAAU,CAAC,CAAC;aAChE;SACF;QAED,OAAO,WAAW,CAAC;IACrB,CAAC;CACF;AAlFD,wCAkFC","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 Elements\r\n */\r\n\r\nimport { CompressedId64Set, GuidString, Id64, Id64Set, Id64String, JsonUtils, OrderedId64Array } from \"@itwin/core-bentley\";\r\nimport { ClipVector, Range3d, Transform } from \"@itwin/core-geometry\";\r\nimport {\r\n AxisAlignedBox3d, BisCodeSpec, Code, CodeScopeProps, CodeSpec, DefinitionElementProps, ElementAlignedBox3d, ElementProps, EntityMetaData,\r\n GeometricElement2dProps, GeometricElement3dProps, GeometricElementProps, GeometricModel2dProps, GeometricModel3dProps, GeometryPartProps,\r\n GeometryStreamProps, IModel, InformationPartitionElementProps, LineStyleProps, ModelProps, PhysicalElementProps, PhysicalTypeProps, Placement2d,\r\n Placement3d, RelatedElement, RenderSchedule, RenderTimelineProps, RepositoryLinkProps, SectionDrawingLocationProps, SectionDrawingProps,\r\n SectionType, SheetBorderTemplateProps, SheetProps, SheetTemplateProps, SubjectProps, TypeDefinition, TypeDefinitionElementProps, UrlLinkProps,\r\n} from \"@itwin/core-common\";\r\nimport { Entity } from \"./Entity\";\r\nimport { IModelCloneContext } from \"./IModelCloneContext\";\r\nimport { IModelDb } from \"./IModelDb\";\r\nimport { DefinitionModel, DrawingModel, PhysicalModel } from \"./Model\";\r\nimport { SubjectOwnsSubjects } from \"./NavigationRelationship\";\r\n\r\n/** Argument for the `Element.onXxx` static methods\r\n * @beta\r\n */\r\nexport interface OnElementArg {\r\n /** The iModel for the Element affected by this method. */\r\n iModel: IModelDb;\r\n}\r\n\r\n/** Argument for `Element.onInsert` and `Element.onUpdate` static methods.\r\n * @beta\r\n */\r\nexport interface OnElementPropsArg extends OnElementArg {\r\n /** The properties of the Element affected by this method.\r\n * @note the properties may be modified. If so the modified values will be inserted/updated.\r\n */\r\n props: ElementProps;\r\n}\r\n\r\n/** Argument for the `Element.onXxx` static methods that only supply the Id of the affected Element.\r\n * @beta\r\n */\r\nexport interface OnElementIdArg extends OnElementArg {\r\n /** The Id of the Element affected by this method */\r\n id: Id64String;\r\n}\r\n\r\n/** Argument for the `Element.onChildXxx` static methods\r\n * @beta\r\n */\r\nexport interface OnChildElementArg extends OnElementArg {\r\n parentId: Id64String;\r\n}\r\n\r\n/** Argument for the `Element.onChildXxx` static methods that supply the properties of the child Element to be inserted or updated.\r\n * @beta\r\n */\r\nexport interface OnChildElementPropsArg extends OnChildElementArg {\r\n /** The new properties of the child Element for this method. */\r\n childProps: Readonly<ElementProps>;\r\n}\r\n\r\n/** Argument for the `Element.onChildXxx` static methods that only supply the Id of the child Element.\r\n * @beta\r\n */\r\nexport interface OnChildElementIdArg extends OnChildElementArg {\r\n /** The Id of the child element for this method */\r\n childId: Id64String;\r\n}\r\n\r\n/** Argument for the `Element.onSubModelInsert` static method\r\n * @beta\r\n */\r\nexport interface OnSubModelPropsArg extends OnElementArg {\r\n /** The properties of the prospective sub-model */\r\n subModelProps: ModelProps;\r\n}\r\n\r\n/** Argument for several `Element.onSubModelXxx` static methods\r\n * @beta\r\n */\r\nexport interface OnSubModelIdArg extends OnElementArg {\r\n /** The modelId of the sub Model */\r\n subModelId: Id64String;\r\n}\r\n\r\n/** Elements are the smallest individually identifiable building blocks for modeling the real world in an iModel.\r\n * Each element represents an entity in the real world. Sets of Elements (contained in [[Model]]s) are used to model\r\n * other Elements that represent larger scale real world entities. Using this recursive modeling strategy,\r\n * Elements can represent entities at any scale. Elements can represent physical things or abstract concepts\r\n * or simply be information records.\r\n *\r\n * Every Element has a 64-bit id (inherited from Entity) that uniquely identifies it within an iModel. Every Element also\r\n * has a \"code\" that identifies its meaning in the real world. Additionally, Elements may have a \"federationGuid\"\r\n * to hold a GUID, if the element was assigned that GUID by some other federated database. The iModel database enforces\r\n * uniqueness of id, code, and federationGuid.\r\n *\r\n * See:\r\n * * [Element Fundamentals]($docs/bis/intro/element-fundamentals.md)\r\n * * [Working with schemas and elements in TypeScript]($docs/learning/backend/SchemasAndElementsInTypeScript.md)\r\n * * [Creating elements]($docs/learning/backend/CreateElements.md)\r\n * @public\r\n */\r\nexport class Element extends Entity implements ElementProps {\r\n /** @internal */\r\n public static override get className(): string { return \"Element\"; }\r\n /** @internal */\r\n public static override get protectedOperations() { return [\"onInsert\", \"onUpdate\", \"onDelete\"]; }\r\n\r\n /** The ModelId of the [Model]($docs/bis/intro/model-fundamentals.md) containing this element */\r\n public readonly model: Id64String;\r\n /** The [Code]($docs/bis/intro/codes.md) for this element */\r\n public code: Code;\r\n /** The parent element, if present, of this element. */\r\n public parent?: RelatedElement;\r\n /** A [FederationGuid]($docs/bis/intro/element-fundamentals.md#federationguid) assigned to this element by some other federated database */\r\n public federationGuid?: GuidString;\r\n /** A [user-assigned label]($docs/bis/intro/element-fundamentals.md#userlabel) for this element. */\r\n public userLabel?: string;\r\n /** Optional [json properties]($docs/bis/intro/element-fundamentals.md#jsonproperties) of this element. */\r\n public readonly jsonProperties: { [key: string]: any };\r\n\r\n /** constructor for Element.\r\n * @internal\r\n */\r\n constructor(props: ElementProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.code = Code.fromJSON(props.code); // TODO: Validate props.code - don't silently fail if it is the wrong type\r\n this.model = RelatedElement.idFromJson(props.model);\r\n this.parent = RelatedElement.fromJSON(props.parent);\r\n this.federationGuid = props.federationGuid;\r\n this.userLabel = props.userLabel;\r\n this.jsonProperties = { ...props.jsonProperties }; // make sure we have our own copy\r\n }\r\n\r\n /** Called before a new Element is inserted.\r\n * @note throw an exception to disallow the insert\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element to be inserted\r\n * @beta\r\n */\r\n protected static onInsert(arg: OnElementPropsArg): void {\r\n const { iModel, props } = arg;\r\n iModel.locks.checkSharedLock(props.model, \"model\", \"insert\"); // inserting requires shared lock on model\r\n if (props.parent) // inserting requires shared lock on parent, if present\r\n iModel.locks.checkSharedLock(props.parent.id, \"parent\", \"insert\");\r\n }\r\n\r\n /** Called after a new Element was inserted.\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element that was inserted\r\n * @beta\r\n */\r\n protected static onInserted(arg: OnElementIdArg): void {\r\n arg.iModel.locks.elementWasCreated(arg.id);\r\n }\r\n\r\n /** Called before an Element is updated.\r\n * @note throw an exception to disallow the update\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element to be updated\r\n * @beta\r\n */\r\n protected static onUpdate(arg: OnElementPropsArg): void {\r\n arg.iModel.locks.checkExclusiveLock(arg.props.id!, \"element\", \"update\");\r\n }\r\n\r\n /** Called after an Element was updated.\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element that was updated\r\n * @beta\r\n */\r\n protected static onUpdated(_arg: OnElementIdArg): void { }\r\n\r\n /** Called before an Element is deleted.\r\n * @note throw an exception to disallow the delete\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element to be deleted\r\n * @beta\r\n */\r\n protected static onDelete(arg: OnElementIdArg): void {\r\n arg.iModel.locks.checkExclusiveLock(arg.id, \"element\", \"delete\");\r\n }\r\n\r\n /** Called after an Element was deleted.\r\n * @note If you override this method, you must call super.\r\n * @note `this` is the class of the Element that was deleted\r\n * @beta\r\n */\r\n protected static onDeleted(_arg: OnElementIdArg): void { }\r\n\r\n /** Called when an element with an instance of this class as its parent is about to be deleted.\r\n * @note throw an exception if the element should not be deleted\r\n * @note implementers should not presume that the element was deleted if this method does not throw,\r\n * since the delete may fail for other reasons. Instead, rely on [[onChildDeleted]] for that purpose.\r\n * @note `this` is the class of the parent Element whose child will be deleted\r\n * @beta\r\n */\r\n protected static onChildDelete(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called after an element with an instance of this class as its parent was successfully deleted.\r\n * @note `this` is the class of the parent Element whose child was deleted\r\n * @beta\r\n */\r\n protected static onChildDeleted(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called when a *new element* with an instance of this class as its parent is about to be inserted.\r\n * @note throw an exception if the element should not be inserted\r\n * @note `this` is the class of the prospective parent Element.\r\n * @beta\r\n */\r\n protected static onChildInsert(_arg: OnChildElementPropsArg): void { }\r\n\r\n /** Called after a *new element* with an instance of this class as its parent was inserted.\r\n * @note `this` is the class of the parent Element.\r\n * @beta\r\n */\r\n protected static onChildInserted(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called when an element with an instance of this class as its parent is about to be updated.\r\n * @note throw an exception if the element should not be updated\r\n * @note `this` is the class of the parent Element.\r\n * @beta\r\n */\r\n protected static onChildUpdate(_arg: OnChildElementPropsArg): void { }\r\n\r\n /** Called after an element with an instance of this the class as its parent was updated.\r\n * @note `this` is the class of the parent Element.\r\n * @beta\r\n */\r\n protected static onChildUpdated(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called when an *existing element* is about to be updated so that an instance of this class will become its new parent.\r\n * @note throw an exception if the element should not be added\r\n * @note `this` is the class of the prospective parent Element.\r\n * @beta\r\n */\r\n protected static onChildAdd(_arg: OnChildElementPropsArg): void { }\r\n\r\n /** Called after an *existing element* has been updated so that an instance of this class is its new parent.\r\n * @note `this` is the class of the new parent Element.\r\n * @beta\r\n */\r\n protected static onChildAdded(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called when an element with an instance of this class as its parent is about to be updated change to a different parent.\r\n * @note throw an exception if the element should not be dropped\r\n * @note `this` is the class of the parent Element.\r\n * @beta\r\n */\r\n protected static onChildDrop(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called after an element with an instance of this class as its previous parent was updated to have a new parent.\r\n * @note `this` is the class of the previous parent Element.\r\n * @beta\r\n */\r\n protected static onChildDropped(_arg: OnChildElementIdArg): void { }\r\n\r\n /** Called when an instance of this class is being *sub-modeled* by a new Model.\r\n * @note throw an exception if model should not be inserted\r\n * @note `this` is the class of Element to be sub-modeled.\r\n * @beta\r\n */\r\n protected static onSubModelInsert(_arg: OnSubModelPropsArg): void { }\r\n\r\n /** Called after an instance of this class was *sub-modeled* by a new Model.\r\n * @note `this` is the class of Element that is now sub-modeled.\r\n * @beta\r\n */\r\n protected static onSubModelInserted(_arg: OnSubModelIdArg): void { }\r\n\r\n /** Called when a sub-model of an instance of this class is being deleted.\r\n * @note throw an exception if model should not be deleted\r\n * @note `this` is the class of Element that is sub-modeled.\r\n * @beta\r\n */\r\n protected static onSubModelDelete(_arg: OnSubModelIdArg): void { }\r\n\r\n /** Called after a sub-model of an instance of this class was deleted.\r\n * @note `this` is the class of Element that was sub-modeled.\r\n * @beta\r\n */\r\n protected static onSubModelDeleted(_arg: OnSubModelIdArg): void { }\r\n\r\n /** Called during the iModel transformation process after an Element from the source iModel was *cloned* for the target iModel.\r\n * The transformation process automatically handles remapping BisCore properties and those that are properly described in ECSchema.\r\n * This callback is only meant to be overridden if there are other Ids in non-standard locations that need to be remapped or other data that needs to be fixed up after the clone.\r\n * @param _context The context that persists any remapping between the source iModel and target iModel.\r\n * @param _sourceProps The ElementProps for the source Element that was cloned.\r\n * @param _targetProps The ElementProps that are a result of the clone. These can be further modified.\r\n * @note If you override this method, you must call super.\r\n * @beta\r\n */\r\n protected static onCloned(_context: IModelCloneContext, _sourceProps: ElementProps, _targetProps: ElementProps): void { }\r\n\r\n /** Called when a *root* element in a subgraph is changed and before its outputs are processed.\r\n * This special callback is made when:\r\n * * the element is part of an [[ElementDrivesElement]] graph, and\r\n * * the element has no inputs, and\r\n * * none of the element's outputs have been processed.\r\n * @see [[ElementDrivesElement]] for more on element dependency graphs.\r\n * @beta\r\n */\r\n protected static onBeforeOutputsHandled(_id: Id64String, _iModel: IModelDb): void { }\r\n\r\n /** Called on an element in a graph after all of its inputs have been processed and before its outputs are processed.\r\n * This callback is made when:\r\n * * the specified element is part of an [[ElementDrivesElement]] graph, and\r\n * * there was a direct change to some element upstream in the dependency graph.\r\n * * all upstream elements in the graph have been processed.\r\n * * none of the downstream elements have been processed.\r\n * This method is not called if none of the element's inputs were changed.\r\n * @see [[ElementDrivesElement]] for more on element dependency graphs.\r\n * @beta\r\n */\r\n protected static onAllInputsHandled(_id: Id64String, _iModel: IModelDb): void { }\r\n\r\n /** Save this Element's properties to an object for serializing to JSON.\r\n * @internal\r\n */\r\n public override toJSON(): ElementProps {\r\n const val = super.toJSON() as ElementProps;\r\n\r\n if (Code.isValid(this.code))\r\n val.code = this.code;\r\n\r\n val.model = this.model;\r\n val.userLabel = this.userLabel;\r\n val.federationGuid = this.federationGuid;\r\n if (this.parent) val.parent = this.parent;\r\n if (Object.keys(this.jsonProperties).length > 0)\r\n val.jsonProperties = this.jsonProperties;\r\n return val;\r\n }\r\n\r\n /** Collect the Ids of this element's *predecessors* at this level of the class hierarchy.\r\n * A *predecessor* is an element that had to be inserted before this element could have been inserted.\r\n * This is important for cloning operations but can be useful in other situations as well.\r\n * @param predecessorIds The Id64Set to populate with predecessor Ids.\r\n * @note In order to clone/transform an element, all predecessor elements must have been previously cloned and remapped within the [IModelCloneContext]($backend).\r\n * @note This should be overridden (with `super` called) at each level the class hierarchy that introduces predecessors.\r\n * @see getPredecessorIds\r\n * @beta\r\n */\r\n protected collectPredecessorIds(predecessorIds: Id64Set): void {\r\n predecessorIds.add(this.model); // The modeledElement is a predecessor\r\n if (this.code.scope && Id64.isValidId64(this.code.scope))\r\n predecessorIds.add(this.code.scope); // The element that scopes the code is a predecessor\r\n if (this.parent)\r\n predecessorIds.add(this.parent.id); // A parent element is a predecessor\r\n }\r\n\r\n /** Get the Ids of this element's *predecessors*. A *predecessor* is an element that had to be inserted before this element could have been inserted.\r\n * This is important for cloning operations but can be useful in other situations as well.\r\n * @see collectPredecessorIds\r\n * @beta\r\n */\r\n public getPredecessorIds(): Id64Set {\r\n const predecessorIds = new Set<Id64String>();\r\n this.collectPredecessorIds(predecessorIds);\r\n return predecessorIds;\r\n }\r\n\r\n /** Get the class metadata for this element. */\r\n public getClassMetaData(): EntityMetaData | undefined { return this.iModel.classMetaDataRegistry.find(this.classFullName); }\r\n\r\n private getAllUserProperties(): any { if (!this.jsonProperties.UserProps) this.jsonProperties.UserProps = new Object(); return this.jsonProperties.UserProps; }\r\n\r\n /** Get a set of JSON user properties by namespace */\r\n public getUserProperties(namespace: string) { return this.getAllUserProperties()[namespace]; }\r\n\r\n /** Change a set of user JSON properties of this Element by namespace. */\r\n public setUserProperties(nameSpace: string, value: any) { this.getAllUserProperties()[nameSpace] = value; }\r\n\r\n /** Remove a set of JSON user properties, specified by namespace, from this Element */\r\n public removeUserProperties(nameSpace: string) { delete this.getAllUserProperties()[nameSpace]; }\r\n\r\n /** Get a JSON property of this element, by namespace */\r\n public getJsonProperty(nameSpace: string): any { return this.jsonProperties[nameSpace]; }\r\n public setJsonProperty(nameSpace: string, value: any) { this.jsonProperties[nameSpace] = value; }\r\n\r\n /** Get a display label for this Element. By default returns userLabel if present, otherwise code value. */\r\n public getDisplayLabel(): string { return this.userLabel ?? this.code.value; }\r\n\r\n /** Get a list of HTML strings that describe this Element for the tooltip. Strings will be listed on separate lines in the tooltip.\r\n * Any instances of the pattern `%{tag}` will be replaced by the localized value of tag.\r\n */\r\n public getToolTipMessage(): string[] {\r\n const addKey = (key: string) => `<b>%{iModelJs:Element.${key}}:</b> `; // %{iModelJs:Element.xxx} is replaced with localized value of xxx in frontend.\r\n const msg: string[] = [];\r\n const display = this.getDisplayLabel();\r\n msg.push(display ? display : `${addKey(\"Id\") + this.id}, ${addKey(\"Type\")}${this.className}`);\r\n\r\n if (this instanceof GeometricElement)\r\n msg.push(addKey(\"Category\") + this.iModel.elements.getElement(this.category).getDisplayLabel());\r\n\r\n msg.push(addKey(\"Model\") + this.iModel.elements.getElement(this.model).getDisplayLabel());\r\n return msg;\r\n }\r\n\r\n /** Insert this Element into the iModel. */\r\n public insert() { return this.iModel.elements.insertElement(this); }\r\n /** Update this Element in the iModel. */\r\n public update() { this.iModel.elements.updateElement(this); }\r\n /** Delete this Element from the iModel. */\r\n public delete() { this.iModel.elements.deleteElement(this.id); }\r\n}\r\n\r\n/** An abstract base class to model real world entities that intrinsically have geometry.\r\n * @public\r\n */\r\nexport abstract class GeometricElement extends Element implements GeometricElementProps {\r\n /** @internal */\r\n public static override get className(): string { return \"GeometricElement\"; }\r\n /** The Id of the [[Category]] for this GeometricElement. */\r\n public category: Id64String;\r\n /** The GeometryStream for this GeometricElement. */\r\n public geom?: GeometryStreamProps;\r\n /** The origin, orientation, and bounding box of this GeometricElement. */\r\n public abstract get placement(): Placement2d | Placement3d;\r\n\r\n /** @internal */\r\n public constructor(props: GeometricElementProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.category = Id64.fromJSON(props.category);\r\n this.geom = props.geom;\r\n }\r\n\r\n /** Type guard for instanceof [[GeometricElement3d]] */\r\n public is3d(): this is GeometricElement3d { return this instanceof GeometricElement3d; }\r\n /** Type guard for instanceof [[GeometricElement2d]] */\r\n public is2d(): this is GeometricElement2d { return this instanceof GeometricElement2d; }\r\n /** Get the [Transform]($geometry) from the Placement of this GeometricElement */\r\n public getPlacementTransform(): Transform { return this.placement.transform; }\r\n public calculateRange3d(): AxisAlignedBox3d { return this.placement.calculateRange(); }\r\n\r\n /** @internal */\r\n public override toJSON(): GeometricElementProps {\r\n const val = super.toJSON() as GeometricElementProps;\r\n val.category = this.category;\r\n if (this.geom)\r\n val.geom = this.geom;\r\n return val;\r\n }\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n predecessorIds.add(this.category);\r\n // TODO: GeometryPartIds?\r\n }\r\n}\r\n\r\n/** An abstract base class to model real world entities that intrinsically have 3d geometry.\r\n * See [how to create a GeometricElement3d]($docs/learning/backend/CreateElements.md#GeometricElement3d).\r\n * @public\r\n */\r\nexport abstract class GeometricElement3d extends GeometricElement implements GeometricElement3dProps {\r\n /** @internal */\r\n public static override get className(): string { return \"GeometricElement3d\"; }\r\n public placement: Placement3d;\r\n public typeDefinition?: TypeDefinition;\r\n\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.placement = Placement3d.fromJSON(props.placement);\r\n if (props.typeDefinition)\r\n this.typeDefinition = TypeDefinition.fromJSON(props.typeDefinition);\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): GeometricElement3dProps {\r\n const val = super.toJSON() as GeometricElement3dProps;\r\n val.placement = this.placement;\r\n if (undefined !== this.typeDefinition) { val.typeDefinition = this.typeDefinition; }\r\n return val;\r\n }\r\n\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n if (undefined !== this.typeDefinition) { predecessorIds.add(this.typeDefinition.id); }\r\n }\r\n}\r\n\r\n/** A 3d Graphical Element\r\n * @public\r\n */\r\nexport abstract class GraphicalElement3d extends GeometricElement3d {\r\n /** @internal */\r\n public static override get className(): string { return \"GraphicalElement3d\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** An abstract base class to model information entities that intrinsically have 2d geometry.\r\n * @public\r\n */\r\nexport abstract class GeometricElement2d extends GeometricElement implements GeometricElement2dProps {\r\n /** @internal */\r\n public static override get className(): string { return \"GeometricElement2d\"; }\r\n public placement: Placement2d;\r\n public typeDefinition?: TypeDefinition;\r\n\r\n /** @internal */\r\n public constructor(props: GeometricElement2dProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.placement = Placement2d.fromJSON(props.placement);\r\n if (props.typeDefinition)\r\n this.typeDefinition = TypeDefinition.fromJSON(props.typeDefinition);\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): GeometricElement2dProps {\r\n const val = super.toJSON() as GeometricElement2dProps;\r\n val.placement = this.placement;\r\n if (undefined !== this.typeDefinition) { val.typeDefinition = this.typeDefinition; }\r\n return val;\r\n }\r\n\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n if (undefined !== this.typeDefinition) { predecessorIds.add(this.typeDefinition.id); }\r\n }\r\n}\r\n\r\n/** An abstract base class for 2d Geometric Elements that are used to convey information within graphical presentations (like drawings).\r\n * @public\r\n */\r\nexport abstract class GraphicalElement2d extends GeometricElement2d {\r\n /** @internal */\r\n public static override get className(): string { return \"GraphicalElement2d\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement2dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** 2d element used to annotate drawings and sheets.\r\n * @public\r\n */\r\nexport class AnnotationElement2d extends GraphicalElement2d {\r\n /** @internal */\r\n public static override get className(): string { return \"AnnotationElement2d\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement2dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** 2d element used to persist graphics for use in drawings.\r\n * @public\r\n */\r\nexport class DrawingGraphic extends GraphicalElement2d {\r\n /** @internal */\r\n public static override get className(): string { return \"DrawingGraphic\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement2dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** 2D Text Annotation\r\n * @public\r\n */\r\nexport class TextAnnotation2d extends AnnotationElement2d {\r\n /** @internal */\r\n public static override get className(): string { return \"TextAnnotation2d\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement2dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** 3D Text Annotation\r\n * @public\r\n */\r\nexport class TextAnnotation3d extends GraphicalElement3d {\r\n /** @internal */\r\n public static override get className(): string { return \"TextAnnotation3d\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** An Element that occupies real world space. Its coordinates are in the project space of its iModel.\r\n * @public\r\n */\r\nexport abstract class SpatialElement extends GeometricElement3d {\r\n /** @internal */\r\n public static override get className(): string { return \"SpatialElement\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** An Element that is spatially located, has mass, and can be *touched*.\r\n * @public\r\n */\r\nexport abstract class PhysicalElement extends SpatialElement {\r\n /** @internal */\r\n public static override get className(): string { return \"PhysicalElement\"; }\r\n /** If defined, the [[PhysicalMaterial]] that makes up this PhysicalElement. */\r\n public physicalMaterial?: RelatedElement;\r\n /** @internal */\r\n public constructor(props: PhysicalElementProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.physicalMaterial = RelatedElement.fromJSON(props.physicalMaterial);\r\n }\r\n /** @internal */\r\n public override toJSON(): PhysicalElementProps {\r\n const val = super.toJSON() as PhysicalElementProps;\r\n val.physicalMaterial = this.physicalMaterial?.toJSON();\r\n return val;\r\n }\r\n}\r\n\r\n/** Identifies a *tracked* real world location but has no mass and cannot be *touched*.\r\n * @public\r\n */\r\nexport abstract class SpatialLocationElement extends SpatialElement {\r\n /** @internal */\r\n public static override get className(): string { return \"SpatialLocationElement\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** A Volume Element is a Spatial Location Element that is restricted to defining a volume.\r\n * @public\r\n */\r\nexport class VolumeElement extends SpatialLocationElement {\r\n /** @internal */\r\n public static override get className(): string { return \"VolumeElement\"; }\r\n /** @internal */\r\n public constructor(props: GeometricElement3dProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** A SectionDrawingLocation element identifies the location of a [[SectionDrawing]] in the context of a [[SpatialModel]],\r\n * enabling [HyperModeling]($hypermodeling).\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.11.\r\n * @public\r\n */\r\nexport class SectionDrawingLocation extends SpatialLocationElement {\r\n /** The Id of the [[ViewDefinition]] to which this location refers. */\r\n public sectionView: RelatedElement;\r\n\r\n /** @internal */\r\n public static override get className(): string { return \"SectionDrawingLocation\"; }\r\n\r\n public constructor(props: SectionDrawingLocationProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.sectionView = RelatedElement.fromJSON(props.sectionView) ?? RelatedElement.none;\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): SectionDrawingLocationProps {\r\n return {\r\n ...super.toJSON(),\r\n sectionView: this.sectionView.toJSON(),\r\n };\r\n }\r\n}\r\n\r\n/** Information Content Element is an abstract base class for modeling pure information entities. Only the\r\n * core framework should directly subclass from Information Content Element. Domain and application developers\r\n * should start with the most appropriate subclass of Information Content Element.\r\n * @public\r\n */\r\nexport abstract class InformationContentElement extends Element {\r\n /** @internal */\r\n public static override get className(): string { return \"InformationContentElement\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** Element used in conjunction with bis:ElementDrivesElement relationships to bundle multiple inputs before\r\n * driving the output element.\r\n * @beta\r\n */\r\nexport abstract class DriverBundleElement extends InformationContentElement {\r\n /** @internal */\r\n public static override get className(): string { return \"DriverBundleElement\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** Information Reference is an abstract base class for modeling entities whose main purpose is to reference something else.\r\n * @public\r\n */\r\nexport abstract class InformationReferenceElement extends InformationContentElement {\r\n /** @internal */\r\n public static override get className(): string { return \"InformationReferenceElement\"; }\r\n /** @internal */\r\n public constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** A Subject is an information element that describes what this repository (or part thereof) is about.\r\n * See [how to create a Subject element]$(docs/learning/backend/CreateElements.md#Subject).\r\n * @public\r\n */\r\nexport class Subject extends InformationReferenceElement implements SubjectProps {\r\n /** @internal */\r\n public static override get className(): string { return \"Subject\"; }\r\n public description?: string;\r\n /** @internal */\r\n public constructor(props: SubjectProps, iModel: IModelDb) { super(props, iModel); }\r\n /** @internal */\r\n public override toJSON(): SubjectProps { // This override only specializes the return type\r\n return super.toJSON() as SubjectProps; // Entity.toJSON takes care of auto-handled properties\r\n }\r\n /** Create a Code for a Subject given a name that is meant to be unique within the scope of its parent Subject.\r\n * @param iModelDb The IModelDb\r\n * @param parentSubjectId The Id of the parent Subject that provides the scope for names of its child Subjects.\r\n * @param codeValue The child Subject name\r\n */\r\n public static createCode(iModelDb: IModelDb, parentSubjectId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.subject);\r\n return new Code({ spec: codeSpec.id, scope: parentSubjectId, value: codeValue });\r\n }\r\n /** Create a Subject\r\n * @param iModelDb The IModelDb\r\n * @param parentSubjectId The new Subject will be a child of this Subject\r\n * @param name The name (codeValue) of the Subject\r\n * @param description The optional description of the Subject\r\n * @returns The newly constructed Subject\r\n * @throws [[IModelError]] if there is a problem creating the Subject\r\n */\r\n public static create(iModelDb: IModelDb, parentSubjectId: Id64String, name: string, description?: string): Subject {\r\n const subjectProps: SubjectProps = {\r\n classFullName: this.classFullName,\r\n model: IModel.repositoryModelId,\r\n parent: new SubjectOwnsSubjects(parentSubjectId),\r\n code: this.createCode(iModelDb, parentSubjectId, name),\r\n description,\r\n };\r\n return new Subject(subjectProps, iModelDb);\r\n }\r\n /** Insert a Subject\r\n * @param iModelDb Insert into this IModelDb\r\n * @param parentSubjectId The new Subject will be inserted as a child of this Subject\r\n * @param name The name (codeValue) of the Subject\r\n * @param description The optional description of the Subject\r\n * @returns The Id of the newly inserted Subject\r\n * @throws [[IModelError]] if there is a problem inserting the Subject\r\n */\r\n public static insert(iModelDb: IModelDb, parentSubjectId: Id64String, name: string, description?: string): Id64String {\r\n const subject = this.create(iModelDb, parentSubjectId, name, description);\r\n return iModelDb.elements.insertElement(subject);\r\n }\r\n}\r\n\r\n/** An InformationContentElement that identifies the content of a document.\r\n * The realized form of a document is called a DocumentCarrier (different class than Document).\r\n * For example, a will is a legal document. The will published into a PDF file is an ElectronicDocumentCopy.\r\n * The will printed onto paper is a PrintedDocumentCopy.\r\n * In this example, the Document only identifies, names, and tracks the content of the will.\r\n * @public\r\n */\r\nexport abstract class Document extends InformationContentElement {\r\n /** @internal */\r\n public static override get className(): string { return \"Document\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** A document that represents a drawing, that is, a two-dimensional graphical representation of engineering data. A Drawing element is usually modelled by a [[DrawingModel]].\r\n * @public\r\n */\r\nexport class Drawing extends Document {\r\n /** @internal */\r\n public static override get className(): string { return \"Drawing\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n\r\n /** Create a Code for a Drawing given a name that is meant to be unique within the scope of the specified DocumentListModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DocumentListModel that contains the Drawing and provides the scope for its name.\r\n * @param codeValue The Drawing name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.drawing);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n\r\n /** Insert a Drawing element and a DrawingModel that breaks it down.\r\n * @param iModelDb Insert into this iModel\r\n * @param documentListModelId Insert the new Drawing into this DocumentListModel\r\n * @param name The name of the Drawing.\r\n * @returns The Id of the newly inserted Drawing element and the DrawingModel that breaks it down (same value).\r\n * @throws [[IModelError]] if unable to insert the element.\r\n */\r\n public static insert(iModelDb: IModelDb, documentListModelId: Id64String, name: string): Id64String {\r\n const drawingProps: ElementProps = {\r\n classFullName: this.classFullName,\r\n model: documentListModelId,\r\n code: this.createCode(iModelDb, documentListModelId, name),\r\n };\r\n const drawingId: Id64String = iModelDb.elements.insertElement(drawingProps);\r\n const model: DrawingModel = iModelDb.models.createModel({\r\n classFullName: DrawingModel.classFullName,\r\n modeledElement: { id: drawingId },\r\n });\r\n return iModelDb.models.insertModel(model);\r\n }\r\n}\r\n\r\n/** A document that represents a section drawing, that is, a graphical documentation derived from a planar\r\n * section of a spatial view. A SectionDrawing element is modelled by a [[SectionDrawingModel]] or a [[GraphicalModel3d]].\r\n * A [[SectionDrawingLocation]] can associate the drawing with a spatial location, enabling [HyperModeling]($hypermodeling).\r\n * @public\r\n */\r\nexport class SectionDrawing extends Drawing {\r\n /** The type of section used to generate the drawing. */\r\n public sectionType: SectionType;\r\n /** The spatial view from which the section was generated. */\r\n public spatialView: RelatedElement;\r\n /** A transform from the section drawing model's coordinates to spatial coordinates. */\r\n public drawingToSpatialTransform?: Transform;\r\n /** If the section drawing is placed onto a [[Sheet]] via a [[ViewAttachment]], a transform from the sheet's coordinates to spatial coordinates. */\r\n public sheetToSpatialTransform?: Transform;\r\n /** If the section drawing is placed onto a [[Sheet]] via a [[ViewAttachment]], the clip to apply to the sheet graphics when drawn in the context\r\n * of the spatial view.\r\n * @note The ClipVector is defined in spatial coordinates.\r\n */\r\n public drawingBoundaryClip?: ClipVector;\r\n /** If true, when displaying the section drawing as a [DrawingViewState]($frontend), the [[spatialView]] will also be displayed. */\r\n public displaySpatialView: boolean;\r\n\r\n /** @internal */\r\n public static override get className(): string { return \"SectionDrawing\"; }\r\n\r\n /** @internal */\r\n constructor(props: SectionDrawingProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.sectionType = JsonUtils.asInt(props.sectionType, SectionType.Section);\r\n this.spatialView = RelatedElement.fromJSON(props.spatialView) ?? RelatedElement.none;\r\n this.displaySpatialView = JsonUtils.asBool(props.jsonProperties?.displaySpatialView);\r\n\r\n const json = props.jsonProperties;\r\n if (!json)\r\n return;\r\n\r\n if (json.drawingToSpatialTransform)\r\n this.drawingToSpatialTransform = Transform.fromJSON(json.drawingToSpatialTransform);\r\n\r\n if (json.sheetToSpatialTransform)\r\n this.sheetToSpatialTransform = Transform.fromJSON(json.sheetToSpatialTransform);\r\n\r\n if (json.drawingBoundaryClip)\r\n this.drawingBoundaryClip = ClipVector.fromJSON(json.drawingBoundaryClip);\r\n }\r\n\r\n /** Convert to JSON representation. */\r\n public override toJSON(): SectionDrawingProps {\r\n const props: SectionDrawingProps = {\r\n ...super.toJSON(),\r\n sectionType: this.sectionType,\r\n spatialView: this.spatialView.toJSON(),\r\n };\r\n\r\n if (!props.jsonProperties)\r\n props.jsonProperties = {};\r\n\r\n props.jsonProperties.displaySpatialView = this.displaySpatialView ? true : undefined;\r\n props.jsonProperties.drawingToSpatialTransform = this.drawingToSpatialTransform?.toJSON();\r\n props.jsonProperties.sheetToSpatialTransform = this.sheetToSpatialTransform?.toJSON();\r\n props.jsonProperties.drawingBoundaryClip = this.drawingBoundaryClip?.toJSON();\r\n\r\n return props;\r\n }\r\n}\r\n\r\n/** The template for a SheetBorder\r\n * @public\r\n */\r\nexport class SheetBorderTemplate extends Document implements SheetBorderTemplateProps {\r\n /** @internal */\r\n public static override get className(): string { return \"SheetBorderTemplate\"; }\r\n public height?: number;\r\n public width?: number;\r\n /** @internal */\r\n public constructor(props: SheetBorderTemplateProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** The template for a [[Sheet]]\r\n * @public\r\n */\r\nexport class SheetTemplate extends Document implements SheetTemplateProps {\r\n /** @internal */\r\n public static override get className(): string { return \"SheetTemplate\"; }\r\n public height?: number;\r\n public width?: number;\r\n public border?: Id64String;\r\n /** @internal */\r\n constructor(props: SheetTemplateProps, iModel: IModelDb) { super(props, iModel); }\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n if (undefined !== this.border) { predecessorIds.add(this.border); }\r\n }\r\n}\r\n\r\n/** A digital representation of a *sheet of paper*. Modeled by a [[SheetModel]].\r\n * @public\r\n */\r\nexport class Sheet extends Document implements SheetProps {\r\n /** @internal */\r\n public static override get className(): string { return \"Sheet\"; }\r\n public height: number;\r\n public width: number;\r\n public scale?: number;\r\n public sheetTemplate?: Id64String;\r\n /** @internal */\r\n constructor(props: SheetProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.height = JsonUtils.asDouble(props.height);\r\n this.width = JsonUtils.asDouble(props.width);\r\n this.scale = props.scale;\r\n this.sheetTemplate = props.sheetTemplate ? Id64.fromJSON(props.sheetTemplate) : undefined;\r\n }\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n if (undefined !== this.sheetTemplate) { predecessorIds.add(this.sheetTemplate); }\r\n }\r\n /** Create a Code for a Sheet given a name that is meant to be unique within the scope of the specified DocumentListModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DocumentListModel that contains the Sheet and provides the scope for its name.\r\n * @param codeValue The Sheet name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.sheet);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** Information Record Element is an abstract base class for modeling information records. Information Record\r\n * Element is the default choice if no other subclass of Information Content Element makes sense.\r\n * @public\r\n */\r\nexport abstract class InformationRecordElement extends InformationContentElement {\r\n /** @internal */\r\n public static override get className(): string { return \"InformationRecordElement\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** A Definition Element holds configuration-related information that is meant to be referenced / shared.\r\n * @public\r\n */\r\nexport abstract class DefinitionElement extends InformationContentElement implements DefinitionElementProps {\r\n /** @internal */\r\n public static override get className(): string { return \"DefinitionElement\"; }\r\n /** If true, don't show this DefinitionElement in user interface lists. */\r\n public isPrivate: boolean;\r\n /** @internal */\r\n constructor(props: DefinitionElementProps, iModel: IModelDb) { super(props, iModel); this.isPrivate = true === props.isPrivate; }\r\n /** @internal */\r\n public override toJSON(): DefinitionElementProps {\r\n const val = super.toJSON() as DefinitionElementProps;\r\n val.isPrivate = this.isPrivate;\r\n return val;\r\n }\r\n}\r\n\r\n/** This abstract class unifies DefinitionGroup and DefinitionContainer for relationship endpoint purposes.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.10\r\n * @public\r\n */\r\nexport abstract class DefinitionSet extends DefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"DefinitionSet\"; }\r\n}\r\n\r\n/** A DefinitionContainer exclusively owns a set of DefinitionElements contained within its sub-model (of type DefinitionModel).\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.10\r\n * @public\r\n */\r\nexport class DefinitionContainer extends DefinitionSet {\r\n /** @internal */\r\n public static override get className(): string { return \"DefinitionContainer\"; }\r\n /** Create a DefinitionContainer\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that will contain this DefinitionContainer element.\r\n * @param code The Code for this DefinitionContainer.\r\n * @param isPrivate The optional hint, that if `true` means it should not be displayed in the UI.\r\n * @returns The newly constructed DefinitionContainer\r\n * @note There is not a predefined CodeSpec for DefinitionContainer elements, so it is the responsibility of the domain or application to create one.\r\n * @throws [[IModelError]] if there is a problem creating the DefinitionContainer\r\n */\r\n public static create(iModelDb: IModelDb, definitionModelId: Id64String, code: Code, isPrivate?: boolean): DefinitionContainer {\r\n const elementProps: DefinitionElementProps = {\r\n classFullName: this.classFullName,\r\n model: definitionModelId,\r\n code,\r\n isPrivate,\r\n };\r\n return new DefinitionContainer(elementProps, iModelDb);\r\n }\r\n /** Insert a DefinitionContainer and its sub-model.\r\n * @param iModelDb Insert into this IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that will contain this DefinitionContainer element.\r\n * @param code The Code for this DefinitionContainer.\r\n * @param isPrivate The optional hint, that if `true` means it should not be displayed in the UI.\r\n * @returns The Id of the newly inserted DefinitionContainer and its newly inserted sub-model (of type DefinitionModel).\r\n * @note There is not a predefined CodeSpec for DefinitionContainer elements, so it is the responsibility of the domain or application to create one.\r\n * @throws [[IModelError]] if there is a problem inserting the DefinitionContainer\r\n */\r\n public static insert(iModelDb: IModelDb, definitionModelId: Id64String, code: Code, isPrivate?: boolean): Id64String {\r\n const containerElement = this.create(iModelDb, definitionModelId, code, isPrivate);\r\n const containerElementId = iModelDb.elements.insertElement(containerElement);\r\n const containerSubModelProps: ModelProps = {\r\n classFullName: DefinitionModel.classFullName,\r\n modeledElement: { id: containerElementId },\r\n isPrivate,\r\n };\r\n iModelDb.models.insertModel(containerSubModelProps);\r\n return containerElementId;\r\n }\r\n}\r\n\r\n/** A non-exclusive set of DefinitionElements grouped using the DefinitionGroupGroupsDefinitions relationship.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.10\r\n * @public\r\n */\r\nexport class DefinitionGroup extends DefinitionSet {\r\n /** @internal */\r\n public static override get className(): string { return \"DefinitionGroup\"; }\r\n /** Create a DefinitionGroup\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that will contain this DefinitionGroup element.\r\n * @param code The Code for this DefinitionGroup\r\n * @param isPrivate The optional hint, that if `true` means it should not be displayed in the UI.\r\n * @returns The newly constructed DefinitionGroup\r\n * @note There is not a predefined CodeSpec for DefinitionGroup elements, so it is the responsibility of the domain or application to create one.\r\n * @throws [[IModelError]] if there is a problem creating the DefinitionGroup\r\n */\r\n public static create(iModelDb: IModelDb, definitionModelId: Id64String, code: Code, isPrivate?: boolean): DefinitionGroup {\r\n const elementProps: DefinitionElementProps = {\r\n classFullName: this.classFullName,\r\n model: definitionModelId,\r\n code,\r\n isPrivate,\r\n };\r\n return new DefinitionGroup(elementProps, iModelDb);\r\n }\r\n}\r\n\r\n/** Defines a set of properties (the *type*) that may be associated with an element.\r\n * @public\r\n */\r\nexport abstract class TypeDefinitionElement extends DefinitionElement implements TypeDefinitionElementProps {\r\n /** @internal */\r\n public static override get className(): string { return \"TypeDefinitionElement\"; }\r\n public recipe?: RelatedElement;\r\n /** @internal */\r\n constructor(props: TypeDefinitionElementProps, iModel: IModelDb) { super(props, iModel); }\r\n /** @internal */\r\n protected override collectPredecessorIds(predecessorIds: Id64Set): void {\r\n super.collectPredecessorIds(predecessorIds);\r\n if (undefined !== this.recipe) { predecessorIds.add(this.recipe.id); }\r\n }\r\n}\r\n\r\n/** Defines a recipe for generating instances from a definition.\r\n * @beta\r\n */\r\nexport abstract class RecipeDefinitionElement extends DefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"RecipeDefinitionElement\"; }\r\n /** @internal */\r\n constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n}\r\n\r\n/** Defines a set of properties (the *type*) that can be associated with a Physical Element. A Physical\r\n * Type has a strong correlation with something that can be ordered from a catalog since all instances\r\n * share a common set of properties.\r\n * @public\r\n */\r\nexport abstract class PhysicalType extends TypeDefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"PhysicalType\"; }\r\n /** If defined, the [[PhysicalMaterial]] that makes up this PhysicalType. */\r\n public physicalMaterial?: RelatedElement;\r\n /** @internal */\r\n constructor(props: PhysicalTypeProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.physicalMaterial = RelatedElement.fromJSON(props.physicalMaterial);\r\n }\r\n /** @internal */\r\n public override toJSON(): PhysicalTypeProps {\r\n const val = super.toJSON() as PhysicalTypeProps;\r\n val.physicalMaterial = this.physicalMaterial?.toJSON();\r\n return val;\r\n }\r\n /** Create a Code for a PhysicalType element given a name that is meant to be unique within the scope of the specified DefinitionModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DefinitionModel that contains the PhysicalType element and provides the scope for its name.\r\n * @param codeValue The PhysicalType name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.physicalType);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** Defines a set of properties (the *type*) that can be associated with a spatial location.\r\n * @public\r\n */\r\nexport abstract class SpatialLocationType extends TypeDefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"SpatialLocationType\"; }\r\n /** @internal */\r\n constructor(props: TypeDefinitionElementProps, iModel: IModelDb) { super(props, iModel); }\r\n\r\n /** Create a Code for a SpatialLocationType element given a name that is meant to be unique within the scope of the specified DefinitionModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DefinitionModel that contains the SpatialLocationType element and provides the scope for its name.\r\n * @param codeValue The SpatialLocationType name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.spatialLocationType);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** A TemplateRecipe3d is a DefinitionElement that has a sub-model that contains the 3d template elements.\r\n * @beta\r\n */\r\nexport class TemplateRecipe3d extends RecipeDefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"TemplateRecipe3d\"; }\r\n /** @internal */\r\n public constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n /** Create a Code for a TemplateRecipe3d given a name that is meant to be unique within the scope of its Model.\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe3d element.\r\n * @param codeValue The name of the TemplateRecipe3d element.\r\n */\r\n public static createCode(iModelDb: IModelDb, definitionModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.templateRecipe3d);\r\n return new Code({ spec: codeSpec.id, scope: definitionModelId, value: codeValue });\r\n }\r\n /** Create a TemplateRecipe3d\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe3d element.\r\n * @param name The name (Code.value) of the TemplateRecipe3d\r\n * @returns The newly constructed TemplateRecipe3d\r\n * @throws [[IModelError]] if there is a problem creating the TemplateRecipe3d\r\n */\r\n public static create(iModelDb: IModelDb, definitionModelId: Id64String, name: string, isPrivate?: boolean): TemplateRecipe3d {\r\n const elementProps: DefinitionElementProps = {\r\n classFullName: this.classFullName,\r\n model: definitionModelId,\r\n code: this.createCode(iModelDb, definitionModelId, name),\r\n isPrivate,\r\n };\r\n return new TemplateRecipe3d(elementProps, iModelDb);\r\n }\r\n /** Insert a TemplateRecipe3d and a PhysicalModel (sub-model) that will contain the 3d template elements.\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe3d element.\r\n * @param name The name (Code.value) of the TemplateRecipe3d\r\n * @returns The Id of the newly inserted TemplateRecipe3d and the PhysicalModel that sub-models it.\r\n * @throws [[IModelError]] if there is a problem inserting the TemplateRecipe3d or its sub-model.\r\n */\r\n public static insert(iModelDb: IModelDb, definitionModelId: Id64String, name: string, isPrivate?: boolean): Id64String {\r\n const element = this.create(iModelDb, definitionModelId, name, isPrivate);\r\n const modeledElementId: Id64String = iModelDb.elements.insertElement(element);\r\n const modelProps: GeometricModel3dProps = {\r\n classFullName: PhysicalModel.classFullName,\r\n modeledElement: { id: modeledElementId },\r\n isTemplate: true,\r\n };\r\n return iModelDb.models.insertModel(modelProps); // will be the same value as modeledElementId\r\n }\r\n}\r\n\r\n/** Defines a set of properties (the *type*) that can be associated with a 2D Graphical Element.\r\n * @public\r\n */\r\nexport abstract class GraphicalType2d extends TypeDefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"GraphicalType2d\"; }\r\n /** @internal */\r\n public constructor(props: TypeDefinitionElementProps, iModel: IModelDb) { super(props, iModel); }\r\n\r\n /** Create a Code for a GraphicalType2d element given a name that is meant to be unique within the scope of the specified DefinitionModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DefinitionModel that contains the GraphicalType2d element and provides the scope for its name.\r\n * @param codeValue The GraphicalType2d name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.graphicalType2d);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** A recipe that uses a 2D template for creating new instances.\r\n * @beta\r\n */\r\nexport class TemplateRecipe2d extends RecipeDefinitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"TemplateRecipe2d\"; }\r\n /** @internal */\r\n public constructor(props: ElementProps, iModel: IModelDb) { super(props, iModel); }\r\n /** Create a Code for a TemplateRecipe2d given a name that is meant to be unique within the scope of its Model.\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe2d element.\r\n * @param codeValue The name of the TemplateRecipe2d element.\r\n */\r\n public static createCode(iModelDb: IModelDb, definitionModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.templateRecipe2d);\r\n return new Code({ spec: codeSpec.id, scope: definitionModelId, value: codeValue });\r\n }\r\n /** Create a TemplateRecipe2d\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe2d element.\r\n * @param name The name (Code.value) of the TemplateRecipe2d\r\n * @returns The newly constructed TemplateRecipe2d\r\n * @throws [[IModelError]] if there is a problem creating the TemplateRecipe2d\r\n */\r\n public static create(iModelDb: IModelDb, definitionModelId: Id64String, name: string, isPrivate?: boolean): TemplateRecipe2d {\r\n const elementProps: DefinitionElementProps = {\r\n classFullName: this.classFullName,\r\n model: definitionModelId,\r\n code: this.createCode(iModelDb, definitionModelId, name),\r\n isPrivate,\r\n };\r\n return new TemplateRecipe2d(elementProps, iModelDb);\r\n }\r\n /** Insert a TemplateRecipe2d and a DrawingModel (sub-model) that will contain the 2d template elements.\r\n * @param iModelDb The IModelDb\r\n * @param definitionModelId The Id of the [DefinitionModel]($backend) that contains this TemplateRecipe2d element.\r\n * @param name The name (Code.value) of the TemplateRecipe2d\r\n * @returns The Id of the newly inserted TemplateRecipe2d and the PhysicalModel that sub-models it.\r\n * @throws [[IModelError]] if there is a problem inserting the TemplateRecipe2d or its sub-model.\r\n */\r\n public static insert(iModelDb: IModelDb, definitionModelId: Id64String, name: string, isPrivate?: boolean): Id64String {\r\n const element = this.create(iModelDb, definitionModelId, name, isPrivate);\r\n const modeledElementId: Id64String = iModelDb.elements.insertElement(element);\r\n const modelProps: GeometricModel2dProps = {\r\n classFullName: DrawingModel.classFullName,\r\n modeledElement: { id: modeledElementId },\r\n isTemplate: true,\r\n };\r\n return iModelDb.models.insertModel(modelProps); // will be the same value as modeledElementId\r\n }\r\n}\r\n\r\n/** An abstract base class for elements that establishes a particular modeling perspective for its parent Subject.\r\n * Instances are always sub-modeled by a specialization of Model of the appropriate modeling perspective.\r\n * @see [iModel Information Hierarchy]($docs/bis/intro/top-of-the-world), [[Subject]], [[Model]]\r\n * @public\r\n */\r\nexport abstract class InformationPartitionElement extends InformationContentElement implements InformationPartitionElementProps {\r\n /** @internal */\r\n public static override get className(): string { return \"InformationPartitionElement\"; }\r\n /** A human-readable string describing the intent of the partition. */\r\n public description?: string;\r\n /** @internal */\r\n public constructor(props: InformationPartitionElementProps, iModel: IModelDb) { super(props, iModel); }\r\n /** @internal */\r\n public override toJSON(): InformationPartitionElementProps { // This override only specializes the return type\r\n return super.toJSON() as InformationPartitionElementProps; // Entity.toJSON takes care of auto-handled properties\r\n }\r\n /** Create a code that can be used for any subclass of InformationPartitionElement.\r\n * @param iModelDb The IModelDb\r\n * @param parentSubjectId The Id of the parent Subject that provides the scope for names of its child InformationPartitionElements.\r\n * @param codeValue The InformationPartitionElement name\r\n */\r\n public static createCode(iModel: IModelDb, parentSubjectId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.informationPartitionElement);\r\n return new Code({ spec: codeSpec.id, scope: parentSubjectId, value: codeValue });\r\n }\r\n}\r\n\r\n/** A DefinitionPartition element establishes a *Definition* modeling perspective for its parent Subject.\r\n * A DefinitionPartition is always sub-modeled by a DefinitionModel.\r\n * @see [[DefinitionModel]]\r\n * @public\r\n */\r\nexport class DefinitionPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"DefinitionPartition\"; }\r\n}\r\n\r\n/** A DocumentPartition element establishes a *Document* modeling perspective for its parent Subject.\r\n * A DocumentPartition is always sub-modeled by a DocumentListModel.\r\n * @see [[DocumentListModel]]\r\n * @public\r\n */\r\nexport class DocumentPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"DocumentPartition\"; }\r\n}\r\n\r\n/** A GroupInformationPartition element establishes a *Group Information* modeling perspective for its parent Subject.\r\n * A GroupInformationPartition is always sub-modeled by a GroupInformationModel.\r\n * @see [[GroupInformationModel]]\r\n * @public\r\n */\r\nexport class GroupInformationPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"GroupInformationPartition\"; }\r\n}\r\n\r\n/** A GraphicalPartition3d element establishes a *3D Graphical* modeling perspective for its parent Subject.\r\n * A GraphicalPartition3d is always sub-modeled by a GraphicalModel3d.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.8\r\n * @see [[GraphicalModel3d]]\r\n * @public\r\n */\r\nexport class GraphicalPartition3d extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"GraphicalPartition3d\"; }\r\n}\r\n\r\n/** An InformationRecordPartition element establishes a *Information Record* modeling perspective for its parent Subject.\r\n * A InformationRecordPartition is always sub-modeled by an InformationRecordModel.\r\n * @see [[InformationRecordModel]]\r\n * @public\r\n */\r\nexport class InformationRecordPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"InformationRecordPartition\"; }\r\n}\r\n\r\n/** A LinkPartition element establishes a *Link* modeling perspective for its parent Subject. A LinkPartition is always sub-modeled by a LinkModel.\r\n * @see [[LinkModel]]\r\n * @public\r\n */\r\nexport class LinkPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"LinkPartition\"; }\r\n}\r\n\r\n/** A PhysicalPartition element establishes a *Physical* modeling perspective for its parent Subject. A PhysicalPartition is always sub-modeled by a PhysicalModel.\r\n * @see [[PhysicalModel]]\r\n * @public\r\n */\r\nexport class PhysicalPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"PhysicalPartition\"; }\r\n}\r\n\r\n/** A SpatialLocationPartition element establishes a *SpatialLocation* modeling perspective for its parent Subject.\r\n * A SpatialLocationPartition is always sub-modeled by a SpatialLocationModel.\r\n * @see [[SpatialLocationModel]]\r\n * @public\r\n */\r\nexport class SpatialLocationPartition extends InformationPartitionElement {\r\n /** @internal */\r\n public static override get className(): string { return \"SpatialLocationPartition\"; }\r\n}\r\n\r\n/** Group Information is an abstract base class for modeling entities whose main purpose is to reference a group of related elements.\r\n * @public\r\n */\r\nexport abstract class GroupInformationElement extends InformationReferenceElement {\r\n /** @internal */\r\n public static override get className(): string { return \"GroupInformationElement\"; }\r\n}\r\n\r\n/** An information element that specifies a link.\r\n * @public\r\n */\r\nexport abstract class LinkElement extends InformationReferenceElement {\r\n /** @internal */\r\n public static override get className(): string { return \"LinkElement\"; }\r\n /** Create a Code for a LinkElement given a name that is meant to be unique within the scope of the specified Model.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the Model that contains the LinkElement and provides the scope for its name.\r\n * @param codeValue The LinkElement name\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.linkElement);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** An information element that specifies a URL link.\r\n * @public\r\n */\r\nexport class UrlLink extends LinkElement implements UrlLinkProps {\r\n /** @internal */\r\n public static override get className(): string { return \"UrlLink\"; }\r\n public description?: string;\r\n public url?: string;\r\n\r\n /** @internal */\r\n public constructor(props: UrlLinkProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.description = props.description;\r\n this.url = props.url;\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): UrlLinkProps {\r\n const val = super.toJSON() as UrlLinkProps;\r\n val.description = this.description;\r\n val.url = this.url;\r\n return val;\r\n }\r\n}\r\n\r\n/** Represents a folder-like structure that organizes repositories (typically files) in an external system.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.13\r\n * @alpha\r\n */\r\nexport class FolderLink extends UrlLink {\r\n /** @internal */\r\n public static override get className(): string { return \"FolderLink\"; }\r\n}\r\n\r\n/** An information element that links to a repository.\r\n * @public\r\n */\r\nexport class RepositoryLink extends UrlLink implements RepositoryLinkProps {\r\n /** @internal */\r\n public static override get className(): string { return \"RepositoryLink\"; }\r\n public repositoryGuid?: GuidString;\r\n /** @note This property was added to the BisCore schema in version 1.0.13 */\r\n public format?: string;\r\n\r\n /** @internal */\r\n public constructor(props: RepositoryLinkProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.repositoryGuid = props.repositoryGuid;\r\n this.format = props.format;\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): RepositoryLinkProps {\r\n const val = super.toJSON() as RepositoryLinkProps;\r\n val.repositoryGuid = this.repositoryGuid;\r\n val.format = this.format;\r\n return val;\r\n }\r\n}\r\n\r\n/** An information element that links to an embedded file.\r\n * @public\r\n */\r\nexport class EmbeddedFileLink extends LinkElement {\r\n /** @internal */\r\n public static override get className(): string { return \"EmbeddedFileLink\"; }\r\n}\r\n\r\n/** A real world entity is modeled as a Role Element when a set of external circumstances define an important\r\n * role (one that is worth tracking) that is not intrinsic to the entity playing the role. For example,\r\n * a person can play the role of a teacher or a rock can play the role of a boundary marker.\r\n * @public\r\n */\r\nexport abstract class RoleElement extends Element {\r\n /** @internal */\r\n public static override get className(): string { return \"RoleElement\"; }\r\n}\r\n\r\n/** A Definition Element that specifies a collection of geometry that is meant to be reused across Geometric\r\n * Element instances. Leveraging Geometry Parts can help reduce file size and improve display performance.\r\n * @public\r\n */\r\nexport class GeometryPart extends DefinitionElement implements GeometryPartProps {\r\n /** @internal */\r\n public static override get className(): string { return \"GeometryPart\"; }\r\n public geom?: GeometryStreamProps;\r\n public bbox: ElementAlignedBox3d;\r\n /** @internal */\r\n public constructor(props: GeometryPartProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.geom = props.geom;\r\n this.bbox = Range3d.fromJSON(props.bbox);\r\n }\r\n\r\n /** @internal */\r\n public override toJSON(): GeometryPartProps {\r\n const val = super.toJSON() as GeometryPartProps;\r\n val.geom = this.geom;\r\n val.bbox = this.bbox;\r\n return val;\r\n }\r\n\r\n /** Create a Code for a GeometryPart element given a name that is meant to be unique within the scope of the specified DefinitionModel.\r\n * @param iModel The IModelDb\r\n * @param scopeModelId The Id of the DefinitionModel that contains the GeometryPart element and provides the scope for its name.\r\n * @param codeValue The GeometryPart name\r\n * @note GeometryPart elements are not required to be named (have a non-empty Code).\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n const codeSpec: CodeSpec = iModel.codeSpecs.getByName(BisCodeSpec.geometryPart);\r\n return new Code({ spec: codeSpec.id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** The definition element for a line style\r\n * @public\r\n */\r\nexport class LineStyle extends DefinitionElement implements LineStyleProps {\r\n /** @internal */\r\n public static override get className(): string { return \"LineStyle\"; }\r\n public description?: string;\r\n public data!: string;\r\n /** @internal */\r\n constructor(props: LineStyleProps, iModel: IModelDb) { super(props, iModel); }\r\n\r\n /** Create a Code for a LineStyle definition given a name that is meant to be unique within the scope of the specified model.\r\n * @param iModel The IModel\r\n * @param scopeModelId The Id of the DefinitionModel that contains the LineStyle and provides the scope for its name.\r\n * @param codeValue The name of the LineStyle\r\n * @returns A LineStyle Code\r\n */\r\n public static createCode(iModel: IModelDb, scopeModelId: CodeScopeProps, codeValue: string): Code {\r\n return new Code({ spec: iModel.codeSpecs.getByName(BisCodeSpec.lineStyle).id, scope: scopeModelId, value: codeValue });\r\n }\r\n}\r\n\r\n/** Describes how to animate a view of a [[GeometricModel]] to show change over time using a [RenderSchedule.Script]($common).\r\n * @note This class was introduced in version 01.00.13 of the BisCore ECSchema. It should only be used with [[IModelDb]]s containing that version or newer.\r\n * @public\r\n */\r\nexport class RenderTimeline extends InformationRecordElement {\r\n /** @internal */\r\n public static override get className(): string { return \"RenderTimeline\"; }\r\n /** A human-readable description of the timeline, which may be an empty string. */\r\n public description: string;\r\n /** The JSON representation of the instructions for visualizing change over time.\r\n * @see [RenderSchedule.Script]($common) for the API for working with the script.\r\n */\r\n public scriptProps: RenderSchedule.ScriptProps;\r\n\r\n /** @internal */\r\n protected constructor(props: RenderTimelineProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n this.description = props.description ?? \"\";\r\n this.scriptProps = RenderTimeline.parseScriptProps(props.script);\r\n }\r\n\r\n public static fromJSON(props: RenderTimelineProps, iModel: IModelDb): RenderTimeline {\r\n return new RenderTimeline(props, iModel);\r\n }\r\n\r\n public override toJSON(): RenderTimelineProps {\r\n const props = super.toJSON() as RenderTimelineProps;\r\n if (this.description.length > 0)\r\n props.description = this.description;\r\n\r\n props.script = JSON.stringify(this.scriptProps);\r\n return props;\r\n }\r\n\r\n private static parseScriptProps(json: string): RenderSchedule.ScriptProps {\r\n try {\r\n return JSON.parse(json);\r\n } catch (_) {\r\n return [];\r\n }\r\n }\r\n\r\n /** @alpha */\r\n protected override collectPredecessorIds(ids: Id64Set): void {\r\n super.collectPredecessorIds(ids);\r\n const script = RenderSchedule.Script.fromJSON(this.scriptProps);\r\n script?.discloseIds(ids);\r\n }\r\n\r\n /** @alpha */\r\n protected static override onCloned(context: IModelCloneContext, sourceProps: RenderTimelineProps, targetProps: RenderTimelineProps): void {\r\n super.onCloned(context, sourceProps, targetProps);\r\n if (context.isBetweenIModels)\r\n targetProps.script = JSON.stringify(this.remapScript(context, this.parseScriptProps(targetProps.script)));\r\n }\r\n\r\n /** Remap Ids when cloning a RenderSchedule.Script between iModels on a DisplayStyle or RenderTimeline.\r\n * @internal\r\n */\r\n public static remapScript(context: IModelCloneContext, input: RenderSchedule.ScriptProps): RenderSchedule.ScriptProps {\r\n const scriptProps: RenderSchedule.ScriptProps = [];\r\n if (!Array.isArray(input))\r\n return scriptProps;\r\n\r\n const elementIds = new OrderedId64Array();\r\n for (const model of input) {\r\n const modelId = context.findTargetElementId(model.modelId);\r\n if (!Id64.isValid(modelId))\r\n continue;\r\n\r\n model.modelId = modelId;\r\n scriptProps.push(model);\r\n for (const element of model.elementTimelines) {\r\n elementIds.clear();\r\n for (const sourceId of RenderSchedule.ElementTimeline.getElementIds(element.elementIds)) {\r\n const targetId = context.findTargetElementId(sourceId);\r\n if (Id64.isValid(targetId))\r\n elementIds.insert(targetId);\r\n }\r\n\r\n element.elementIds = CompressedId64Set.compressIds(elementIds);\r\n }\r\n }\r\n\r\n return scriptProps;\r\n }\r\n}\r\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ElementAspect.d.ts","sourceRoot":"","sources":["../src/ElementAspect.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,yBAAyB,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAC3H,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,EAAY,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAE3D;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,wDAAwD;IACxD,MAAM,EAAE,QAAQ,CAAC;CAClB;AACD;;GAEG;AACH,MAAM,WAAW,gBAAiB,SAAQ,WAAW;IACnD,+DAA+D;IAC/D,KAAK,EAAE,QAAQ,CAAC,kBAAkB,CAAC,CAAC;CACrC;AACD;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,WAAW;IAChD,kDAAkD;IAClD,QAAQ,EAAE,UAAU,CAAC;CACtB;AAED;;;;GAIG;AACH,qBAAa,aAAc,SAAQ,MAAO,YAAW,kBAAkB;IACrE,gBAAgB;IAChB,WAA2B,SAAS,IAAI,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IAAI,CAAC;QACrB,GAAG,CAAC,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC;QAC7B,GAAG,CAAC,OAAO,GAAG,IAAI,CAAC,OAAO,CAAC;QAC3B,GAAG,CAAC,cAAc,GAAG,IAAI,CAAC,cAAc,CAAC;QACzC,OAAO,GAAG,CAAC;IACb,CAAC;CACF;AAhED,oDAgEC;AAED,cAAc;AACd,WAAiB,oBAAoB;IACnC;;OAEG;IACH,IAAY,IASX;IATD,WAAY,IAAI;QACd,oFAAoF;QACpF,2BAAmB,CAAA;QACnB,yFAAyF;QACzF,qCAA6B,CAAA;QAC7B;;WAEG;QACH,uBAAe,CAAA;IACjB,CAAC,EATW,IAAI,GAAJ,yBAAI,KAAJ,yBAAI,QASf;AACH,CAAC,EAdgB,oBAAoB,GAApB,4BAAoB,KAApB,4BAAoB,QAcpC","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 ElementAspects\n */\n\nimport { ChannelRootAspectProps, ElementAspectProps, ExternalSourceAspectProps, RelatedElement } from \"@itwin/core-common\";\nimport { Entity } from \"./Entity\";\nimport { IModelDb } from \"./IModelDb\";\nimport { ECSqlStatement } from \"./ECSqlStatement\";\nimport { DbResult, Id64String } from \"@itwin/core-bentley\";\n\n/** Argument for the `ElementAspect.onXxx` static methods\n * @beta\n */\nexport interface OnAspectArg {\n /** The iModel for the aspect affected by this event. */\n iModel: IModelDb;\n}\n/** Argument for the `ElementAspect.onXxx` static methods that supply the properties of an aspect to be inserted or updated.\n * @beta\n */\nexport interface OnAspectPropsArg extends OnAspectArg {\n /** The new properties of the aspect affected by this event. */\n props: Readonly<ElementAspectProps>;\n}\n/** Argument for the `ElementAspect.onXxx` static methods that only supply the Id of the affected aspect.\n * @beta\n */\nexport interface OnAspectIdArg extends OnAspectArg {\n /** The Id of the aspect affected by this event */\n aspectId: Id64String;\n}\n\n/** An Element Aspect is a class that defines a set of properties that are related to (and owned by) a single element.\n * Semantically, an ElementAspect can be considered part of the Element. Thus, an ElementAspect is deleted if its owning Element is deleted.\n * BIS Guideline: Subclass ElementUniqueAspect or ElementMultiAspect rather than subclassing ElementAspect directly.\n * @public\n */\nexport class ElementAspect extends Entity implements ElementAspectProps {\n /** @internal */\n public static override get className(): string { return \"ElementAspect\"; }\n public element: RelatedElement;\n\n /** @internal */\n constructor(props: ElementAspectProps, iModel: IModelDb) {\n super(props, iModel);\n this.element = RelatedElement.fromJSON(props.element)!;\n }\n\n /** @internal */\n public override toJSON(): ElementAspectProps {\n const val = super.toJSON() as ElementAspectProps;\n val.element = this.element;\n return val;\n }\n\n /** Called before a new ElementAspect is inserted.\n * @note throw an exception to disallow the insert\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onInsert(_arg: OnAspectPropsArg): void { }\n\n /** Called after a new ElementAspect was inserted.\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onInserted(_arg: OnAspectPropsArg): void { }\n\n /** Called before an ElementAspect is updated.\n * @note throw an exception to disallow the update\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onUpdate(_arg: OnAspectPropsArg): void { }\n\n /** Called after an ElementAspect was updated.\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onUpdated(_arg: OnAspectPropsArg): void { }\n\n /** Called before an ElementAspect is deleted.\n * @note throw an exception to disallow the delete\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onDelete(_arg: OnAspectIdArg): void { }\n\n /** Called after an ElementAspect was deleted.\n * @note If you override this method, you must call super.\n * @beta\n */\n protected static onDeleted(_arg: OnAspectIdArg): void { }\n}\n\n/** An Element Unique Aspect is an ElementAspect where there can be only zero or one instance of the Element Aspect class per Element.\n * @public\n */\nexport class ElementUniqueAspect extends ElementAspect {\n /** @internal */\n public static override get className(): string { return \"ElementUniqueAspect\"; }\n}\n\n/** An Element Multi-Aspect is an ElementAspect where there can be **n** instances of the Element Aspect class per Element.\n * @public\n */\nexport class ElementMultiAspect extends ElementAspect {\n /** @internal */\n public static override get className(): string { return \"ElementMultiAspect\"; }\n}\n\n/** A ChannelRootAspect identifies an Element as the root of a *channel* which is a subset of the overall iModel hierarchy that is independently maintained.\n * @note The associated ECClass was added to the BisCore schema in version 1.0.10\n * @public\n */\nexport class ChannelRootAspect extends ElementUniqueAspect {\n /** @internal */\n public static override get className(): string { return \"ChannelRootAspect\"; }\n\n /** The owner of the channel */\n public owner: string;\n\n /** @internal */\n constructor(props: ChannelRootAspectProps, iModel: IModelDb) {\n super(props, iModel);\n this.owner = props.owner;\n }\n\n /** @internal */\n public override toJSON(): ChannelRootAspectProps {\n const val = super.toJSON() as ChannelRootAspectProps;\n val.owner = this.owner;\n return val;\n }\n\n /** Insert a ChannelRootAspect on the specified element. */\n public static insert(iModel: IModelDb, ownerId: Id64String, ownerDescription: string) {\n const props: ChannelRootAspectProps = {\n classFullName: ChannelRootAspect.classFullName,\n element: { id: ownerId },\n owner: ownerDescription,\n };\n iModel.elements.insertAspect(props);\n }\n}\n\n/** An ElementMultiAspect that stores synchronization information for an Element originating from an external source.\n * @note The associated ECClass was added to the BisCore schema in version 1.0.2\n * @public\n */\nexport class ExternalSourceAspect extends ElementMultiAspect implements ExternalSourceAspectProps {\n /** @internal */\n public static override get className(): string { return \"ExternalSourceAspect\"; }\n\n /** An element that scopes the combination of `kind` and `identifier` to uniquely identify the object from the external source. */\n public scope: RelatedElement;\n /** The identifier of the object in the source repository. */\n public identifier: string;\n /** The kind of object within the source repository. */\n public kind: string;\n /** The cryptographic hash (any algorithm) of the source object's content. If defined, it must be guaranteed to change when the source object's content changes. */\n public checksum?: string;\n /** An optional value that is typically a version number or a pseudo version number like last modified time.\n * It will be used by the synchronization process to detect that a source object is unchanged so that computing a cryptographic hash can be avoided.\n * If present, this value must be guaranteed to change when any of the source object's content changes.\n */\n public version?: string;\n /** A place where additional JSON properties can be stored. For example, provenance information or properties relating to the synchronization process. */\n public jsonProperties?: string;\n /** The source of the imported/synchronized object. Should point to an instance of [ExternalSource]($backend). */\n public source?: RelatedElement;\n\n /** @internal */\n constructor(props: ExternalSourceAspectProps, iModel: IModelDb) {\n super(props, iModel);\n this.scope = RelatedElement.fromJSON(props.scope)!;\n this.source = RelatedElement.fromJSON(props.source);\n this.identifier = props.identifier;\n this.kind = props.kind;\n this.checksum = props.checksum;\n this.version = props.version;\n this.jsonProperties = props.jsonProperties;\n }\n\n /** Look up the ElementId of the element that contains an aspect with the specified Scope, Kind, and Identifier\n */\n public static findBySource(iModelDb: IModelDb, scope: Id64String, kind: string, identifier: string): { elementId?: Id64String, aspectId?: Id64String } {\n const sql = `SELECT Element.Id, ECInstanceId FROM ${ExternalSourceAspect.classFullName} WHERE (Scope.Id=:scope AND Kind=:kind AND Identifier=:identifier)`;\n let elementId: Id64String | undefined;\n let aspectId: Id64String | undefined;\n iModelDb.withPreparedStatement(sql, (statement: ECSqlStatement) => {\n statement.bindId(\"scope\", scope);\n statement.bindString(\"kind\", kind);\n statement.bindString(\"identifier\", identifier);\n if (DbResult.BE_SQLITE_ROW === statement.step()) {\n elementId = statement.getValue(0).getId();\n aspectId = statement.getValue(1).getId();\n }\n });\n return { elementId, aspectId };\n }\n\n /** @internal */\n public override toJSON(): ExternalSourceAspectProps {\n const val = super.toJSON() as ExternalSourceAspectProps;\n val.scope = this.scope;\n val.source = this.source;\n val.identifier = this.identifier;\n val.kind = this.kind;\n val.checksum = this.checksum;\n val.version = this.version;\n val.jsonProperties = this.jsonProperties;\n return val;\n }\n}\n\n/** @public */\nexport namespace ExternalSourceAspect { // eslint-disable-line no-redeclare\n /** Standard values for the `Kind` property of `ExternalSourceAspect`.\n * @public\n */\n export enum Kind {\n /** Indicates that the [[ExternalSourceAspect]] is storing [[Element]] provenance */\n Element = \"Element\",\n /** Indicates that the [[ExternalSourceAspect]] is storing [[Relationship]] provenance */\n Relationship = \"Relationship\",\n /** Indicates that the [[ExternalSourceAspect]] is storing *scope* provenance\n * @see [[ExternalSourceAspect.scope]]\n */\n Scope = \"Scope\",\n }\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ElementGraphics.d.ts","sourceRoot":"","sources":["../src/ElementGraphics.ts"],"names":[],"mappings":"AAIA;;GAEG;AAGH,OAAO,EAAE,2BAA2B,EAAe,MAAM,oBAAoB,CAAC;AAE9E,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEtC;;GAEG;AACH,wBAAsB,uBAAuB,CAAC,OAAO,EAAE,2BAA2B,EAAE,MAAM,EAAE,QAAQ,GAAG,OAAO,CAAC,UAAU,GAAG,SAAS,CAAC,CA0BrI"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ElementGraphics.js","sourceRoot":"","sources":["../src/ElementGraphics.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAA2D;AAC3D,oDAA8E;AAI9E;;GAEG;AACI,KAAK,UAAU,uBAAuB,CAAC,OAAoC,EAAE,MAAgB;IAClG,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,QAAQ,CAAC,uBAAuB,CAAC,OAAO,CAAC,CAAC;IAEtE,IAAI,KAAyB,CAAC;IAC9B,QAAQ,MAAM,CAAC,MAAM,EAAE;QACrB,wBAAsC;QACtC;YACE,OAAO,SAAS,CAAC;QACnB;YACE,OAAO,MAAM,CAAC,OAAO,CAAC;QACxB;YACE,KAAK,GAAG,cAAc,CAAC;YACvB,MAAM;QACR;YACE,KAAK,GAAG,8BAA8B,CAAC;YACvC,MAAM;QACR;YACE,KAAK,GAAG,cAAc,OAAO,CAAC,SAAS,YAAY,CAAC;YACpD,MAAM;QACR;YACE,KAAK,GAAG,yBAAyB,OAAO,CAAC,EAAE,GAAG,CAAC;YAC/C,MAAM;KACT;IAED,IAAA,qBAAM,EAAC,SAAS,KAAK,KAAK,CAAC,CAAC;IAC5B,MAAM,IAAI,yBAAW,CAAC,2BAAY,CAAC,UAAU,EAAE,KAAK,CAAC,CAAC;AACxD,CAAC;AA1BD,0DA0BC","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 Tiles\n */\n\nimport { assert, IModelStatus } from \"@itwin/core-bentley\";\nimport { ElementGraphicsRequestProps, IModelError } from \"@itwin/core-common\";\nimport { ElementGraphicsStatus } from \"@bentley/imodeljs-native\";\nimport { IModelDb } from \"./IModelDb\";\n\n/** See [[IModelDb.generateElementGraphics]] and IModelTileRpcImpl.requestElementGraphics.\n * @internal\n */\nexport async function generateElementGraphics(request: ElementGraphicsRequestProps, iModel: IModelDb): Promise<Uint8Array | undefined> {\n const result = await iModel.nativeDb.generateElementGraphics(request);\n\n let error: string | undefined;\n switch (result.status) {\n case ElementGraphicsStatus.NoGeometry:\n case ElementGraphicsStatus.Canceled:\n return undefined;\n case ElementGraphicsStatus.Success:\n return result.content;\n case ElementGraphicsStatus.InvalidJson:\n error = \"Invalid JSON\";\n break;\n case ElementGraphicsStatus.UnknownMajorFormatVersion:\n error = \"Unknown major format version\";\n break;\n case ElementGraphicsStatus.ElementNotFound:\n error = `Element Id ${request.elementId} not found`;\n break;\n case ElementGraphicsStatus.DuplicateRequestId:\n error = `Duplicate request Id \"${request.id}\"`;\n break;\n }\n\n assert(undefined !== error);\n throw new IModelError(IModelStatus.BadRequest, error);\n}\n"]}
|
package/lib/Entity.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"Entity.d.ts","sourceRoot":"","sources":["../src/Entity.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAQ,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,gBAAgB,EAAoB,MAAM,oBAAoB,CAAC;AACrF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sB,EAAE,gBAAyB,IAAI,IAAI,mBAAQ,CAAC,eAAe,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,aAAa,EAAE,IAAI,EAAE,IAAI,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC;IAEvK,4EAA4E;IACrE,MAAM,KAAK,aAAa,KAAa,OAAO,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU,IAAI,IAAI,CAAC,SAAS,EAAE,CAAC,CAAC,CAAC;IAEnG,6EAA6E;IAC7E,IAAW,aAAa,KAAa,OAAO,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC;IAEvE,gBAAgB;IACT,MAAM,KAAK,mBAAmB,KAAe,OAAO,EAAE,CAAC,CAAC,CAAC;CACjE;AAhED,wBAgEC","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 Schema\n */\n\nimport { Id64, Id64String } from \"@itwin/core-bentley\";\nimport { EntityProps, PropertyCallback, PropertyMetaData } from \"@itwin/core-common\";\nimport { IModelDb } from \"./IModelDb\";\nimport { Schema } from \"./Schema\";\n\n/** Base class for all Entities in an iModel. Every subclass of Entity handles one BIS class.\n * @public\n */\nexport class Entity implements EntityProps {\n /** The Schema that defines this class. */\n public static schema: typeof Schema;\n\n private get _ctor(): typeof Entity { return this.constructor as typeof Entity; }\n\n /** The name of the BIS class associated with this class.\n * @note Every subclass of Entity **MUST** override this method to identify its BIS class.\n * Failure to do so will ordinarily result in an error when the class is registered, since there may only\n * be one JavaScript class for a given BIS class (usually the errant class will collide with its superclass.)\n */\n public static get className(): string { return \"Entity\"; }\n\n /** When working with an Entity it can be useful to set property values directly, bypassing the compiler's type checking.\n * This property makes such code slightly less tedious to read and write.\n * @internal\n */\n public get asAny(): any { return this; }\n\n /** The name of the BIS Schema that defines this class */\n public get schemaName(): string { return this._ctor.schema.schemaName; }\n\n /** The name of the BIS class associated with this class. */\n public get className(): string { return this._ctor.className; }\n\n /** The [[IModelDb]] that contains this Entity */\n public iModel: IModelDb;\n\n /** The Id of this Entity. May be invalid if the Entity has not yet been saved in the database. */\n public id: Id64String;\n\n /** @internal */\n constructor(props: EntityProps, iModel: IModelDb) {\n this.iModel = iModel;\n this.id = Id64.fromJSON(props.id);\n // copy all auto-handled properties from input to the object being constructed\n this.forEachProperty((propName: string, meta: PropertyMetaData) => (this as any)[propName] = meta.createProperty((props as any)[propName]), false);\n }\n\n /** @internal */\n public toJSON(): EntityProps {\n const val: any = {};\n val.classFullName = this.classFullName;\n if (Id64.isValid(this.id))\n val.id = this.id;\n this.forEachProperty((propName: string) => val[propName] = (this as any)[propName], false);\n return val;\n }\n\n /** Call a function for each property of this Entity.\n * @param func The callback to be invoked on each property\n * @param includeCustom If true (default), include custom-handled properties in the iteration. Otherwise, skip custom-handled properties.\n * @note Custom-handled properties are core properties that have behavior enforced by C++ handlers.\n */\n public forEachProperty(func: PropertyCallback, includeCustom: boolean = true) { IModelDb.forEachMetaData(this.iModel, this.classFullName, true, func, includeCustom); }\n\n /** Get the full BIS class name of this Entity in the form \"schema:class\" */\n public static get classFullName(): string { return `${this.schema.schemaName}:${this.className}`; }\n\n /** Get the full BIS class name of this Entity in the form \"schema:class\". */\n public get classFullName(): string { return this._ctor.classFullName; }\n\n /** @internal */\n public static get protectedOperations(): string[] { return []; }\n}\n\n/** Parameter type that can accept both abstract constructor types and non-abstract constructor types for `instanceof` to test.\n * @public\n */\nexport type EntityClassType<T> = Function & { prototype: T };\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ExportGraphics.d.ts","sourceRoot":"","sources":["../src/ExportGraphics.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,QAAQ,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C,KAAsB,EAAE,KAAa;QACvD,IAAI,CAAC,KAAK,CAAC,wBAAwB,CAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;QACxD,IAAI,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,IAAI,KAAK,GAAG,KAAK,CAAC,KAAK,CAAC,MAAM;YACzD,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC;QACtC,IAAI,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,KAAK,IAAI,KAAK,GAAG,KAAK,CAAC,KAAK,CAAC,MAAM;YACzD,IAAI,CAAC,KAAK,CAAC,uBAAuB,CAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;QACzD,IAAI,IAAI,CAAC,MAAM,IAAI,KAAK,CAAC,MAAM,IAAI,KAAK,GAAG,KAAK,CAAC,MAAM,CAAC,MAAM;YAC5D,IAAI,CAAC,MAAM,CAAC,wBAAwB,CAAC,KAAK,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IAC9D,CAAC;CAEF;AA5ID,8DA4IC","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 iModels\r\n */\r\n\r\nimport { Id64Array, Id64String } from \"@itwin/core-bentley\";\r\nimport { IndexedPolyface, Polyface, PolyfaceData, PolyfaceVisitor } from \"@itwin/core-geometry\";\r\nimport { GeometryClass } from \"@itwin/core-common\";\r\n\r\n/** A collection of line segments, suitable for direct use with graphics APIs.\r\n * The structure of this data matches GL_LINES in OpenGL.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportGraphicsLines {\r\n /** Zero-based vertex indices, every two indices represent a line segment */\r\n indices: Int32Array;\r\n /** Vertices for these lines, laid out in the pattern XYZXYZ */\r\n points: Float64Array;\r\n}\r\n\r\n/** Info provided to ExportLinesFunction about linework graphics.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportLinesInfo {\r\n /** The element ID for the element the graphics originated from */\r\n elementId: Id64String;\r\n /** ID for the [SubCategory]($core-backend) for these graphics */\r\n subCategory: Id64String;\r\n /** The color and transparency for these graphics, laid out in TBGR format, see [ColorDef]($core-common) */\r\n color: number;\r\n /** GeometryClass for these graphics */\r\n geometryClass: GeometryClass;\r\n /** The linework for these graphics */\r\n lines: ExportGraphicsLines;\r\n}\r\n\r\n/** A callback function that receives generated line graphics.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport type ExportLinesFunction = (info: ExportLinesInfo) => void;\r\n\r\n/** A triangulated mesh with unified indices, suitable for direct use with graphics APIs.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportGraphicsMesh {\r\n /** Zero-based vertex indices, every three indices represent a triangle */\r\n indices: Int32Array;\r\n /** Vertices for this mesh, laid out in the pattern XYZXYZ */\r\n points: Float64Array;\r\n /** Normals for this mesh, laid out in the pattern XYZXYZ */\r\n normals: Float32Array;\r\n /** Parameters (uvs) for this mesh, laid out in the pattern XYXY */\r\n params: Float32Array;\r\n /** If true, clients should assume both sides of the mesh are visible and not cull backfaces. */\r\n isTwoSided: boolean;\r\n}\r\n\r\n/** Info provided to ExportGraphicsFunction about graphics.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportGraphicsInfo {\r\n /** The element ID for the element the graphics originated from */\r\n elementId: Id64String;\r\n /** ID for the [SubCategory]($core-backend) for these graphics */\r\n subCategory: Id64String;\r\n /** The color and transparency for these graphics, laid out in TBGR format, see [ColorDef]($core-common) */\r\n color: number;\r\n /** GeometryClass for these graphics */\r\n geometryClass: GeometryClass;\r\n /** If defined, ID for the [RenderMaterialElement]($core-backend) for these graphics */\r\n materialId?: Id64String;\r\n /** If defined, ID for the [Texture]($core-backend) for these graphics */\r\n textureId?: Id64String;\r\n /** The mesh for these graphics */\r\n mesh: ExportGraphicsMesh;\r\n}\r\n\r\n/** Information about the base display properties when a [GeometryPart]($core-backend) was\r\n * referenced. This is intended to be used with [IModelDb.exportPartGraphics]($core-backend).\r\n * * If two ExportPartInstanceInfo have the same ExportPartDisplayInfos, they will result in the\r\n * same graphics (with a different transform).\r\n * * If two ExportPartInstanceInfo have different ExportPartDisplayInfos, they may result in different\r\n * graphics.\r\n * @public\r\n */\r\nexport interface ExportPartDisplayInfo {\r\n categoryId: Id64String;\r\n subCategoryId: Id64String;\r\n geometryClass: GeometryClass;\r\n materialId: Id64String;\r\n elmTransparency: number;\r\n lineColor: number;\r\n}\r\n\r\n/** Information about references to [GeometryPart]($core-backend) elements found during\r\n * a call to [IModelDb.exportGraphics]($core-backend).\r\n * See [IModelDb.exportPartGraphics]($core-backend) for the intended use case.\r\n * @public\r\n */\r\nexport interface ExportPartInstanceInfo {\r\n /** ID for the [GeometryPart]($core-backend) */\r\n partId: Id64String;\r\n /** ID for the element that contained the reference to the [GeometryPart]($core-backend) */\r\n partInstanceId: Id64String;\r\n /** The base display properties when the [GeometryPart]($core-backend) was referenced. */\r\n displayProps: ExportPartDisplayInfo;\r\n /** A row-major storage 4x3 transform for this instance.\r\n * See export-gltf under test-apps in the iModel.js monorepo for a working reference.\r\n */\r\n transform?: Float64Array;\r\n}\r\n\r\n/** A callback function that receives generated graphics.\r\n * See [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport type ExportGraphicsFunction = (info: ExportGraphicsInfo) => void;\r\n\r\n/** Parameters for [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportGraphicsOptions {\r\n /** The source elements for the exported graphics */\r\n elementIdArray: Id64Array;\r\n /** A function to call for each unique element ID, color and texture combination */\r\n onGraphics: ExportGraphicsFunction;\r\n /** An optional function to call if line graphics are desired. */\r\n onLineGraphics?: ExportLinesFunction;\r\n /** If supplied, any references to [GeometryPart]($core-backend) elements found will be\r\n * recorded in this array. In this case, graphics that would result from the GeometryPart\r\n * will not be supplied via onGraphics. See [IModelDb.exportPartGraphics]($core-backend)\r\n */\r\n partInstanceArray?: ExportPartInstanceInfo[];\r\n /** Max distance from a face to the original geometry, see [StrokeOptions]($core-geometry) */\r\n chordTol?: number;\r\n /** Max angle difference in radians for approximated face, see [StrokeOptions]($core-geometry) */\r\n angleTol?: number;\r\n /** Max length of any edge in generated faces, see [StrokeOptions]($core-geometry) */\r\n maxEdgeLength?: number;\r\n /** The longest dimension of a line style's largest component must be at least this size in order for\r\n * exportGraphics to evaluate and generate its graphics. If undefined, this defaults to 0.1.\r\n * Line styles can evaluate to 3D geometry that clients expect to receive from exportGraphics, but they\r\n * can also generate gigabytes of mesh data when line styles with small components are applied to long\r\n * line strings.\r\n */\r\n minLineStyleComponentSize?: number;\r\n /** Max distance between mesh vertices for them to be collapsed.\r\n * Meshes stored in GeometryStreams are unaffected by StrokeOptions settings. If decimationTol is undefined,\r\n * they are output from exportGraphics without any reduction in quality and can be too detailed for\r\n * some uses. However, decimation is a destructive operation that can introduce gaps and other visual\r\n * anomalies so it is important to choose an appropriate setting for your use case.\r\n */\r\n decimationTol?: number;\r\n /** BRep features with bounding boxes smaller than this size will not generate graphics.\r\n * This option can be used to ignore expensive details from [BRepEntity.DataProps]($core-common)\r\n * like screws and screw holes.\r\n */\r\n minBRepFeatureSize?: number;\r\n}\r\n\r\n/** Info provided to ExportPartFunction about graphics.\r\n * See [IModelDb.exportPartGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportPartInfo {\r\n /** The color and transparency for these graphics, laid out in TBGR format, see [ColorDef]($core-common) */\r\n color: number;\r\n /** GeometryClass for these graphics */\r\n geometryClass: GeometryClass;\r\n /** If defined, ID for the [RenderMaterialElement]($core-backend) for these graphics */\r\n materialId?: Id64String;\r\n /** If defined, ID for the [Texture]($core-backend) for these graphics */\r\n textureId?: Id64String;\r\n /** The mesh for these graphics */\r\n mesh: ExportGraphicsMesh;\r\n}\r\n\r\n/** A callback function that receives generated graphics for a [GeometryPart]($core-backend).\r\n * See [IModelDb.exportPartGraphics]($core-backend)\r\n * @public\r\n */\r\nexport type ExportPartFunction = (info: ExportPartInfo) => void;\r\n\r\n/** Info provided to ExportPartFunction about line graphics.\r\n * See [IModelDb.exportPartGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportPartLinesInfo {\r\n /** The color and transparency for these graphics, laid out in TBGR format, see [ColorDef]($core-common) */\r\n color: number;\r\n /** GeometryClass for these graphics */\r\n geometryClass: GeometryClass;\r\n /** The linework for these graphics */\r\n lines: ExportGraphicsLines;\r\n}\r\n\r\n/** A callback function that receives generated line graphics for a [GeometryPart]($core-backend).\r\n * See [IModelDb.exportPartGraphics]($core-backend)\r\n * @public\r\n */\r\nexport type ExportPartLinesFunction = (info: ExportPartLinesInfo) => void;\r\n\r\n/** Parameters for [IModelDb.exportPartGraphics]($core-backend)\r\n * @public\r\n */\r\nexport interface ExportPartGraphicsOptions {\r\n /** The ID for the source [GeometryPart]($core-backend) */\r\n elementId: Id64String;\r\n /** The base display properties to use for generating the graphics. This should come from an\r\n * ExportPartInstanceProps generated by [IModelDb.exportGraphics]($core-backend)\r\n */\r\n displayProps: ExportPartDisplayInfo;\r\n /** A function to call for each unique color and texture combination. */\r\n onPartGraphics: ExportPartFunction;\r\n /** An optional function to call if line graphics are desired. */\r\n onPartLineGraphics?: ExportPartLinesFunction;\r\n /** Max distance from a face to the original geometry, see [StrokeOptions]($core-geometry) */\r\n chordTol?: number;\r\n /** Max angle difference in radians for approximated face, see [StrokeOptions]($core-geometry) */\r\n angleTol?: number;\r\n /** Max length of any edge in generated faces, see [StrokeOptions]($core-geometry) */\r\n maxEdgeLength?: number;\r\n /** The longest dimension of a line style's largest component must be at least this size in order for\r\n * exportGraphics to evaluate and generate its graphics. If undefined, this defaults to 0.1.\r\n * Line styles can evaluate to 3D geometry that clients expect to receive from exportGraphics, but they\r\n * can also generate gigabytes of mesh data when line styles with small components are applied to long\r\n * line strings.\r\n */\r\n minLineStyleComponentSize?: number;\r\n /** Max distance between mesh vertices for them to be collapsed.\r\n * Meshes stored in GeometryStreams are unaffected by StrokeOptions settings. If decimationTol is undefined,\r\n * they are output from exportGraphics without any reduction in quality and can be too detailed for\r\n * some uses. However, decimation is a destructive operation that can introduce gaps and other visual\r\n * anomalies so it is important to choose an appropriate setting for your use case.\r\n */\r\n decimationTol?: number;\r\n /** BRep features with bounding boxes smaller than this size will not generate graphics.\r\n * This option can be used to ignore expensive details from [BRepEntity.DataProps]($core-common)\r\n * like screws and screw holes.\r\n */\r\n minBRepFeatureSize?: number;\r\n}\r\n\r\n/** Provides utility functions for working with data generated by [IModelDb.exportGraphics]($core-backend)\r\n * @public\r\n */\r\nexport namespace ExportGraphics {\r\n /** Test if ExportPartDisplayInfos have exactly the same values.\r\n * @public\r\n */\r\n export function arePartDisplayInfosEqual(lhs: ExportPartDisplayInfo, rhs: ExportPartDisplayInfo): boolean {\r\n if (lhs.categoryId !== rhs.categoryId) return false;\r\n if (lhs.subCategoryId !== rhs.subCategoryId) return false;\r\n if (lhs.materialId !== rhs.materialId) return false;\r\n if (lhs.elmTransparency !== rhs.elmTransparency) return false;\r\n if (lhs.lineColor !== rhs.lineColor) return false;\r\n return true;\r\n }\r\n\r\n /**\r\n * Convert an ExportGraphicsMesh to an IndexedPolyface usable by the geometry API.\r\n * @note The resulting IndexedPolyface may have duplicate points, normals and params. If problematic, call [PolyfaceData.compress]($core-geometry)\r\n * @public\r\n */\r\n export function convertToIndexedPolyface(mesh: ExportGraphicsMesh): IndexedPolyface {\r\n const polyface = IndexedPolyface.create(true, true, false, mesh.isTwoSided);\r\n\r\n const p: Float64Array = mesh.points;\r\n for (let i = 0; i < p.length; i += 3)\r\n polyface.data.point.pushXYZ(p[i], p[i + 1], p[i + 2]);\r\n\r\n const n: Float32Array = mesh.normals;\r\n for (let i = 0; i < n.length; i += 3)\r\n polyface.data.normal!.pushXYZ(n[i], n[i + 1], n[i + 2]);\r\n\r\n const uv: Float32Array = mesh.params;\r\n for (let i = 0; i < uv.length; i += 2)\r\n polyface.data.param!.pushXY(uv[i], uv[i + 1]);\r\n\r\n const indices = mesh.indices;\r\n const addIndex = (idx: number) => {\r\n polyface.addPointIndex(idx, true);\r\n polyface.addNormalIndex(idx);\r\n polyface.addParamIndex(idx);\r\n };\r\n for (let i = 0; i < indices.length; i += 3) {\r\n addIndex(indices[i]);\r\n addIndex(indices[i + 1]);\r\n addIndex(indices[i + 2]);\r\n polyface.terminateFacet(false);\r\n }\r\n\r\n return polyface;\r\n }\r\n}\r\n/**\r\n * * Iterator to walk the facets of an ExportGraphicsMesh and present them to the world as if visiting a Polyface.\r\n * * Because the ExportGraphicsMesh has limited data:\r\n * * There is no auxData in this visitor.\r\n * * There is no color in this visitor.\r\n * * All edgeVisible are true.\r\n * @public\r\n */\r\nexport class ExportGraphicsMeshVisitor extends PolyfaceData implements PolyfaceVisitor {\r\n private _currentFacetIndex: number;\r\n private _nextFacetIndex: number;\r\n private _numWrap: number;\r\n private _polyface: ExportGraphicsMesh;\r\n // to be called from static factory method that validates the polyface ...\r\n private constructor(facets: ExportGraphicsMesh, numWrap: number) {\r\n super(facets.normals.length > 0, facets.params.length > 0, false, facets.isTwoSided);\r\n this._polyface = facets;\r\n this._numWrap = numWrap;\r\n\r\n this._nextFacetIndex = 0;\r\n this._currentFacetIndex = -1;\r\n this.twoSided = facets.isTwoSided;\r\n this.reset();\r\n }\r\n /** Create a visitor for iterating the facets of `polyface`, with indicated number of points to be added to each facet to produce closed point arrays\r\n * Typical wrap counts are:\r\n * * 0 -- leave the point arrays with \"missing final edge\"\r\n * * 1 -- add point 0 as closure point\r\n * * 2 -- add points 0 and 1 as closure and wrap point. This is useful when vertex visit requires two adjacent vectors, e.g. for cross products.\r\n */\r\n public static create(polyface: ExportGraphicsMesh, numWrap: number): ExportGraphicsMeshVisitor {\r\n return new ExportGraphicsMeshVisitor(polyface, numWrap);\r\n }\r\n /** Reset the iterator to start at the first facet of the polyface. */\r\n public reset(): void {\r\n this.moveToReadIndex(0);\r\n this._nextFacetIndex = 0; // so immediate moveToNextFacet stays here.\r\n }\r\n /** Select a facet by simple index. */\r\n public moveToReadIndex(facetIndex: number): boolean {\r\n if (facetIndex < 0 || 2 + facetIndex * 3 >= this._polyface.indices.length)\r\n return false;\r\n this._currentFacetIndex = facetIndex;\r\n this._nextFacetIndex = facetIndex + 1;\r\n this.point.length = 0;\r\n const points = this.point;\r\n points.length = 0;\r\n this.pointIndex.length = 0;\r\n this.point.length = 0;\r\n this.edgeVisible.length = 0;\r\n const sourcePoints = this._polyface.points;\r\n const indices = this._polyface.indices;\r\n const i0 = 3 * facetIndex;\r\n for (let i = i0; i < i0 + 3; i++) {\r\n const k = 3 * indices[i];\r\n this.pointIndex.push(indices[i]);\r\n this.point.pushXYZ(sourcePoints[k], sourcePoints[k + 1], sourcePoints[k + 2]);\r\n this.edgeVisible.push(true);\r\n }\r\n for (let i = 0; i < this._numWrap; i++) {\r\n this.point.pushFromGrowableXYZArray(this.point, i);\r\n }\r\n\r\n const sourceParams = this._polyface.params;\r\n if (sourceParams.length > 0 && this.paramIndex && this.param) {\r\n this.paramIndex.length = 0;\r\n this.param.length = 0;\r\n for (let i = i0; i < i0 + 3; i++) {\r\n const k = 2 * indices[i];\r\n this.paramIndex.push(indices[i]);\r\n this.param.pushXY(sourceParams[k], sourceParams[k + 1]);\r\n }\r\n for (let i = 0; i < this._numWrap; i++) {\r\n this.param.pushFromGrowableXYArray(this.param, i);\r\n }\r\n }\r\n\r\n const sourceNormals = this._polyface.normals;\r\n if (sourceNormals.length > 0 && this.normalIndex && this.normal) {\r\n this.normalIndex.length = 0;\r\n this.normal.length = 0;\r\n for (let i = i0; i < i0 + 3; i++) {\r\n const k = 3 * indices[i];\r\n this.normalIndex.push(indices[i]);\r\n this.normal.pushXYZ(sourceNormals[k], sourceNormals[k + 1], sourceNormals[k + 2]);\r\n }\r\n for (let i = 0; i < this._numWrap; i++) {\r\n this.normal.pushFromGrowableXYZArray(this.normal, i);\r\n }\r\n }\r\n return true;\r\n }\r\n public moveToNextFacet(): boolean {\r\n return this.moveToReadIndex(this._nextFacetIndex);\r\n }\r\n /** Set the number of vertices to replicate in visitor arrays. */\r\n public setNumWrap(numWrap: number): void { this._numWrap = numWrap; }\r\n\r\n /** Return the index (in the client polyface) of the current facet */\r\n public currentReadIndex(): number { return this._currentFacetIndex; }\r\n /** Return the point index of vertex i within the currently loaded facet */\r\n public clientPointIndex(i: number): number { return this.pointIndex[i]; }\r\n /** Return the param index of vertex i within the currently loaded facet.\r\n * Use the artificial paramIndex, which matches pointIndex.\r\n */\r\n public clientParamIndex(i: number): number { return this.paramIndex ? this.paramIndex[i] : -1; }\r\n /** Return the normal index of vertex i within the currently loaded facet.\r\n * Use the artificial paramIndex, which matches pointIndex.\r\n */\r\n public clientNormalIndex(i: number): number { return this.normalIndex ? this.normalIndex[i] : -1; }\r\n /** Return the color index of vertex i within the currently loaded facet */\r\n public clientColorIndex(_i: number): number { return 1; }\r\n /** Return the aux data index of vertex i within the currently loaded facet */\r\n public clientAuxIndex(_i: number): number { return -1; }\r\n\r\n /** return the client polyface */\r\n public clientPolyface(): Polyface { return (undefined as unknown) as Polyface; }\r\n /** clear the contents of all arrays. Use this along with transferDataFrom methods to build up new facets */\r\n public clearArrays(): void {\r\n if (this.point !== undefined)\r\n this.point.length = 0;\r\n if (this.param !== undefined)\r\n this.param.length = 0;\r\n if (this.normal !== undefined)\r\n this.normal.length = 0;\r\n // ignore color and aux -- they never exist.\r\n }\r\n /** transfer interpolated data from the other visitor.\r\n * * all data values are interpolated at `fraction` between `other` values at index0 and index1.\r\n */\r\n public pushInterpolatedDataFrom(other: PolyfaceVisitor, index0: number, fraction: number, index1: number): void {\r\n this.point.pushInterpolatedFromGrowableXYZArray(other.point, index0, fraction, index1);\r\n if (this.param && other.param && index0 < other.param.length && index1 < other.param.length)\r\n this.param.pushInterpolatedFromGrowableXYArray(other.param, index0, fraction, index1);\r\n if (this.normal && other.normal && index0 < other.normal.length && index1 < other.normal.length)\r\n this.normal.pushInterpolatedFromGrowableXYZArray(other.normal, index0, fraction, index1);\r\n }\r\n /** transfer data from a specified index of the other visitor as new data in this visitor. */\r\n public pushDataFrom(other: PolyfaceVisitor, index: number): void {\r\n this.point.pushFromGrowableXYZArray(other.point, index);\r\n if (this.color && other.color && index < other.color.length)\r\n this.color.push(other.color[index]);\r\n if (this.param && other.param && index < other.param.length)\r\n this.param.pushFromGrowableXYArray(other.param, index);\r\n if (this.normal && other.normal && index < other.normal.length)\r\n this.normal.pushFromGrowableXYZArray(other.normal, index);\r\n }\r\n\r\n}\r\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ExternalSource.d.ts","sourceRoot":"","sources":["../src/ExternalSource.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC/C,OAAO,EACQ,IAAI,EAAiB,6BAA6B,EAAE,4BAA4B,EAAE,mBAAmB,EAClH,8BAA8B,EAC/B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,2BAA2B,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACjE,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,sCAAsC,EAAE,4BAA4B,EAAE,MAAM,0BAA0B,CAAC;AAEhH;;;GAGG;AACH,qBAAa,cAAe,SAAQ,2BAA2B;IAC7D,wDAAwD;IACjD,UAAU,CAAC,EAAE,4BAA4B,CAAC;IACjD,2EAA2E;IACpE,aAAa,CAAC,EAAE,MAAM,CAAC;IAC9B,8EAA8E;IACvE,gBAAgB,CAAC,EAAE,MAAM,CAAC;IACjC,gBAAgB;IACh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------------------------------\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 Elements\r\n */\r\n\r\nimport { Id64String } from \"@itwin/core-bentley\";\r\nimport { Point3d } from \"@itwin/core-geometry\";\r\nimport {\r\n BisCodeSpec, Code, CodeScopeSpec, ExternalSourceAttachmentProps, ExternalSourceAttachmentRole, ExternalSourceProps, IModel, RelatedElement,\r\n SynchronizationConfigLinkProps,\r\n} from \"@itwin/core-common\";\r\nimport { InformationReferenceElement, UrlLink } from \"./Element\";\r\nimport { IModelDb } from \"./IModelDb\";\r\nimport { ExternalSourceAttachmentAttachesSource, ExternalSourceIsInRepository } from \"./NavigationRelationship\";\r\n\r\n/** An ExternalSource refers to an 'information container' found in a repository. In some cases, the container is the entire repository.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.13\r\n * @beta\r\n */\r\nexport class ExternalSource extends InformationReferenceElement {\r\n /** The repository that contains this ExternalSource. */\r\n public repository?: ExternalSourceIsInRepository;\r\n /** The name of the iModel Connecter that processed this ExternalSource. */\r\n public connectorName?: string;\r\n /** The version of the iModel Connecter that processed this ExternalSource. */\r\n public connectorVersion?: string;\r\n /** @internal */\r\n public static override get className(): string { return \"ExternalSource\"; }\r\n /** @internal */\r\n public constructor(props: ExternalSourceProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n if (props.repository) this.repository = new ExternalSourceIsInRepository(RelatedElement.idFromJson(props.repository));\r\n }\r\n /** @internal */\r\n public override toJSON(): ExternalSourceProps { // This override only specializes the return type\r\n return super.toJSON() as ExternalSourceProps; // Entity.toJSON takes care of auto-handled properties\r\n }\r\n /** The [[CodeSpec]] for ExternalSource elements is not automatically created, so this method ensures that it exists. */\r\n public static ensureCodeSpec(iModelDb: IModelDb): Id64String {\r\n try {\r\n const codeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.externalSource);\r\n return codeSpec.id;\r\n } catch (e) {\r\n return iModelDb.codeSpecs.insert(BisCodeSpec.externalSource, CodeScopeSpec.Type.Repository);\r\n }\r\n }\r\n /** Create a Code for an ExternalSource element given a name that is meant to be unique within the scope of the iModel.\r\n * @param iModelDb The IModelDb\r\n * @param codeValue The ExternalSource name\r\n * @see [[ensureCodeSpec]]\r\n */\r\n public static createCode(iModelDb: IModelDb, codeValue: string): Code {\r\n const codeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.externalSource);\r\n return new Code({ spec: codeSpec.id, scope: IModel.rootSubjectId, value: codeValue });\r\n }\r\n}\r\n\r\n/** Attachment of an ExternalSource\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.13\r\n * @beta\r\n */\r\nexport class ExternalSourceAttachment extends InformationReferenceElement {\r\n /** The [[ExternalSource]] that is attached by this ExternalSourceAttachment. */\r\n public attaches?: ExternalSourceAttachmentAttachesSource;\r\n /** Specifies whether the attached [[ExternalSource]] provides context or models a part of the whole. */\r\n public role?: ExternalSourceAttachmentRole;\r\n /** The translation or offset in global coordinates of the attached [[ExternalSource]] relative to the ExternalSource that attaches it. */\r\n public translation?: Point3d;\r\n /** The Yaw angle (in degrees) of the attached [[ExternalSource]] relative to the ExternalSource that attaches it. */\r\n public yaw?: number;\r\n /** The Pitch angle (in degrees) of the attached [[ExternalSource]] relative to the ExternalSource that attaches it. */\r\n public pitch?: number;\r\n /** The Roll angle (in degrees) of the attached [[ExternalSource]] relative to the ExternalSource that attaches it. */\r\n public roll?: number;\r\n /** The scale of the attached [[ExternalSource]] relative to the ExternalSource that attaches it. */\r\n public scale?: Point3d;\r\n /** @internal */\r\n public static override get className(): string { return \"ExternalSourceAttachment\"; }\r\n /** @internal */\r\n public constructor(props: ExternalSourceAttachmentProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n if (props.attaches) this.attaches = new ExternalSourceAttachmentAttachesSource(RelatedElement.idFromJson(props.attaches));\r\n if (props.translation) this.translation = Point3d.fromJSON(props.translation);\r\n if (props.scale) this.scale = Point3d.fromJSON(props.scale);\r\n }\r\n /** @internal */\r\n public override toJSON(): ExternalSourceAttachmentProps { // This override only specializes the return type\r\n return super.toJSON() as ExternalSourceAttachmentProps; // Entity.toJSON takes care of auto-handled properties\r\n }\r\n /** The [[CodeSpec]] for ExternalSourceAttachment elements is not automatically created, so this method ensures that it exists. */\r\n public static ensureCodeSpec(iModelDb: IModelDb): Id64String {\r\n try {\r\n const codeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.externalSourceAttachment);\r\n return codeSpec.id;\r\n } catch (e) {\r\n return iModelDb.codeSpecs.insert(BisCodeSpec.externalSourceAttachment, CodeScopeSpec.Type.ParentElement);\r\n }\r\n }\r\n /** Create a Code for an ExternalSourceAttachment element given a name that is meant to be unique within the scope of its parent [[ExternalSource]].\r\n * @param iModelDb The IModelDb\r\n * @param scopeElementId The parent ExternalSource\r\n * @param codeValue The ExternalSourceAttachment name\r\n * @see [[ensureCodeSpec]]\r\n */\r\n public static createCode(iModelDb: IModelDb, scopeElementId: Id64String, codeValue: string): Code {\r\n const codeSpec = iModelDb.codeSpecs.getByName(BisCodeSpec.externalSourceAttachment);\r\n return new Code({ spec: codeSpec.id, scope: scopeElementId, value: codeValue });\r\n }\r\n}\r\n\r\n/** A group of ExternalSources that are collectively a source of information for one or more elements.\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.13\r\n * @beta\r\n */\r\nexport class ExternalSourceGroup extends ExternalSource {\r\n /** @internal */\r\n public static override get className(): string { return \"ExternalSourceGroup\"; }\r\n /** @internal */\r\n public constructor(props: ExternalSourceProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n }\r\n}\r\n\r\n/** Link to the Configuration for an iModel Synchronization Job\r\n * @note The associated ECClass was added to the BisCore schema in version 1.0.13\r\n * @beta\r\n */\r\nexport class SynchronizationConfigLink extends UrlLink {\r\n /** Date/Time of last successful run of this synchronization configuration */\r\n public lastSuccessfulRun?: string;\r\n /** @internal */\r\n public static override get className(): string { return \"SynchronizationConfigLink\"; }\r\n /** @internal */\r\n public constructor(props: SynchronizationConfigLinkProps, iModel: IModelDb) {\r\n super(props, iModel);\r\n }\r\n /** @internal */\r\n public override toJSON(): SynchronizationConfigLinkProps { // This override only specializes the return type\r\n return super.toJSON() as SynchronizationConfigLinkProps; // Entity.toJSON takes care of auto-handled properties\r\n }\r\n}\r\n\r\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"GeometrySummary.d.ts","sourceRoot":"","sources":["../src/GeometrySummary.ts"],"names":[],"mappings":"AAYA,OAAO,EACwE,2BAA2B,EAEzG,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAqZtC,gBAAgB;AAChB,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,2BAA2B,EAAE,MAAM,EAAE,QAAQ,GAAG,MAAM,CAGxG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"GeometrySummary.js","sourceRoot":"","sources":["../src/GeometrySummary.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;;;AAE/F,sDAAwF;AACxF,wDAK8B;AAC9B,oDAG4B;AAC5B,uCAAoE;AAQpE,uBAAuB;AAEvB,yDAAyD;AACzD,MAAM,iBAAiB;IAUrB,YAAmB,OAAoC,EAAE,MAAgB;QATlE,cAAS,GAAG,sCAAwB,CAAC,KAAK,CAAC;QAC3C,qBAAgB,GAAG,KAAK,CAAC;QAEzB,qBAAgB,GAAG,KAAK,CAAC;QAO9B,IAAI,CAAC,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;QACrC,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,MAAM,IAAI,GAAG,OAAO,CAAC,OAAO,CAAC;QAC7B,IAAI,SAAS,KAAK,IAAI,EAAE;YACtB,IAAI,CAAC,SAAS,GAAG,SAAS,KAAK,IAAI,CAAC,iBAAiB,CAAC,CAAC,CAAC,IAAI,CAAC,iBAAi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AM,2BAA2B,GAAgC,KAAoC,CAAC;gBACtG,MAAM,IAAI,GAAG,2BAA2B,CAAC,IAAI,CAAC;gBAC9C,OAAO,GAAG,GAAG,OAAO;yBACH,KAAK,CAAC,WAAW,EAAE;oBACxB,IAAI,CAAC,UAAU,EAAE,CAAC;gBAC9B,OAAO,OAAO,CAAC;SAClB;IACH,CAAC;IAEM,wBAAwB,CAAC,MAAuB;QACrD,IAAI,OAAO,GAAW,EAAE,CAAC;QACzB,QAAQ,MAAM,CAAC,mBAAmB,EAAE;YAClC,KAAK,MAAM;gBACT,MAAM,IAAI,GAAS,MAAc,CAAC;gBAClC,OAAO,GAAG,GAAG,OAAO,aAAa,IAAI,CAAC,OAAO,EAAE,CAAC;gBAChD,MAAM;YACR,KAAK,MAAM;gBACT,MAAM,IAAI,GAAS,MAAc,CAAC;gBAClC,OAAO,GAAG,GAAG,OAAO,YAAY,IAAI,CAAC,UAAU,EAAE,CAAC;gBAClD,MAAM;SACT;QAED,OAAO,GAAG,OAAO;mBACF,MAAM,CAAC,sBAAsB,EAAE,CAAC,MAAM;kBACvC,MAAM,CAAC,eAAe,EAAE,EAAE,CAAC;IAC3C,CAAC;CACF;AAED,gBAAgB;AAChB,SAAgB,yBAAyB,CAAC,OAAoC,EAAE,MAAgB;IAC9F,MAAM,SAAS,GAAG,IAAI,iBAAiB,CAAC,OAAO,EAAE,MAAM,CAAC,CAAC;IACzD,OAAO,SAAS,CAAC,iBAAiB,EAAE,CAAC;AACvC,CAAC;AAHD,8DAGC","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\nimport { BentleyError, Id64Array, Id64String, IModelStatus } from \"@itwin/core-bentley\";\nimport {\n AkimaCurve3d, AnyGeometryQuery, Arc3d, BezierCurveBase, Box, BSplineCurve3d, Cone, CurveChainWithDistanceIndex, CurveCollection, CurvePrimitive, IModelJson,\n InterpolationCurve3d,\n LinearSweep, LineSegment3d, LineString3d, Loop, Path, Range3d, RotationalSweep, RuledSweep, SolidPrimitive, Sphere, TorusPipe, Transform,\n TransitionSpiral3d, UVSelect,\n} from \"@itwin/core-geometry\";\nimport {\n BRepEntity, GeometricElement3dProps, GeometryParams, GeometryStreamIterator, GeometrySummaryRequestProps, GeometrySummaryVerbosity, ImagePrimitive,\n IModelError, TextStringPrimitive,\n} from \"@itwin/core-common\";\nimport { Element, GeometricElement, GeometryPart } from \"./Element\";\nimport { IModelDb } from \"./IModelDb\";\n\ninterface ElementGeom {\n iterator: GeometryStreamIterator;\n geometricElement?: GeometricElement;\n}\n\n// cspell:ignore earlin\n\n/** Generates an array of GeometryStreamResponseProps. */\nclass ResponseGenerator {\n public verbosity = GeometrySummaryVerbosity.Basic;\n public includePlacement = false;\n public includePartReferences?: \"2d\" | \"3d\";\n public verboseSymbology = false;\n public elementIds: Id64Array;\n public iModel: IModelDb;\n\n public get wantSquish() { return GeometrySummaryVerbosity.Full !== this.verbosity; }\n\n public constructor(request: GeometrySummaryRequestProps, iModel: IModelDb) {\n this.elementIds = request.elementIds;\n this.iModel = iModel;\n const opts = request.options;\n if (undefined !== opts) {\n this.verbosity = undefined !== opts.geometryVerbosity ? opts.geometryVerbosity : GeometrySummaryVerbosity.Basic;\n this.includePlacement = true === opts.includePlacement;\n this.includePartReferences = opts.includePartReferences;\n this.verboseSymbology = true === opts.verboseSymbology;\n }\n }\n\n public generateSummaries(): string {\n const summaries: string[] = [];\n for (const elementId of this.elementIds)\n summaries.push(this.generateSummary(elementId));\n\n return summaries.join(\"\\n\");\n }\n\n public generateSummary(id: Id64String): string {\n let lines = [`[Geometry Summary for Element ${id}]`];\n try {\n const geom = this.getElementGeom(id);\n if (undefined === geom)\n throw new IModelError(IModelStatus.NoGeometry, \"Element is neither a geometric element nor a geometry part\");\n\n if (undefined !== geom.geometricElement)\n lines.push(this.summarizeElement(geom.geometricElement));\n else if (undefined !== this.includePartReferences)\n lines.push(this.summarizePartReferences(id, \"2d\" === this.includePartReferences)); // NB: Hideously inefficient if more than one element's summary was requested.\n\n let curGeomParams: GeometryParams | undefined;\n let curLocalRange: Range3d | undefined;\n for (const entry of geom.iterator) {\n if (this.verboseSymbology && (undefined === curGeomParams || !curGeomParams.isEquivalent(entry.geomParams))) {\n lines.push(`Symbology: ${this.stringify(entry.geomParams)}`);\n curGeomParams = entry.geomParams.clone();\n }\n\n if (undefined !== entry.localRange && (undefined === curLocalRange || !curLocalRange.isAlmostEqual(entry.localRange))) {\n lines.push(this.summarizeRange3d(entry.localRange));\n curLocalRange = entry.localRange;\n }\n\n const prim = entry.primitive;\n switch (prim.type) {\n case \"textString\":\n case \"image\":\n this.summarizePrimitive(lines, prim);\n break;\n case \"brep\":\n this.summarizeBRep(lines, prim.brep);\n break;\n case \"geometryQuery\":\n this.summarizeGeometryQuery(lines, prim.geometry);\n break;\n case \"partReference\":\n lines.push(this.summarizePartReference(prim.part.id, prim.part.toLocal));\n break;\n }\n }\n } catch (err) {\n lines = lines.slice(0, 1);\n lines.push(`ERROR: ${BentleyError.getErrorMessage(err)}`);\n }\n\n return lines.filter((line) => line !== \"\").join(\"\\n\");\n }\n\n public summarizeElement(elem: GeometricElement): string {\n const lines: string[] = [];\n lines.push(`(${elem.is2d() ? \"2D\" : \"3D\"}) Category: ${elem.category}`);\n lines.push(`Model: ${elem.model}`);\n if (this.includePlacement) {\n lines.push(`Range: ${this.stringify(elem.calculateRange3d())}`);\n lines.push(`Transform: ${this.stringify(elem.getPlacementTransform())}`);\n }\n\n return lines.join(\"\\n\");\n }\n\n public summarizePartReferences(id: Id64String, is2d: boolean): string {\n const refIds = this.iModel.nativeDb.findGeometryPartReferences([id], is2d);\n return `Part references (${refIds.length}): ${refIds.join()}`;\n }\n\n public getElementGeom(id: Id64String): ElementGeom | undefined {\n const elem = this.iModel.elements.getElement<Element>({ id, wantGeometry: true });\n let iterator: GeometryStreamIterator | undefined;\n let geometricElement: GeometricElement | undefined;\n if (elem instanceof GeometricElement) {\n geometricElement = elem;\n if (geometricElement.is2d())\n iterator = GeometryStreamIterator.fromGeometricElement2d(geometricElement);\n else\n iterator = GeometryStreamIterator.fromGeometricElement3d(geometricElement as GeometricElement3dProps);\n } else if (elem instanceof GeometryPart) {\n iterator = GeometryStreamIterator.fromGeometryPart(elem);\n }\n\n return undefined !== iterator ? { iterator, geometricElement } : undefined;\n }\n\n public summarizeRange3d(range: Range3d): string {\n return `SubGraphicRange: ${this.stringify(range)}`;\n }\n\n public summarizePrimitive(lines: string[], primitive: TextStringPrimitive | ImagePrimitive): void {\n const summary = primitive.type;\n if (GeometrySummaryVerbosity.Basic >= this.verbosity) {\n lines.push(summary);\n return;\n }\n\n const json = this.stringify(primitive.type === \"textString\" ? primitive.textString : primitive.image);\n if (GeometrySummaryVerbosity.Detailed >= this.verbosity) {\n lines.push(`${summary}: ${json}`);\n return;\n }\n\n lines.push(`${summary}:`);\n lines.push(json);\n }\n\n public summarizeBRep(lines: string[], brep: BRepEntity.DataProps): void {\n const summary = \"brep\";\n if (GeometrySummaryVerbosity.Basic >= this.verbosity) {\n lines.push(summary);\n return;\n }\n\n const json = this.stringify({ type: brep.type, transform: brep.transform, faceSymbology: brep.faceSymbology });\n if (GeometrySummaryVerbosity.Detailed >= this.verbosity) {\n lines.push(`${summary}: ${json}`);\n return;\n }\n\n lines.push(`${summary}:`);\n lines.push(json);\n }\n\n public summarizePartReference(partId: string, partToLocal?: Transform): string {\n let line = `part id: ${partId}`;\n if (undefined !== partToLocal)\n line = `${line} transform: ${this.stringify(partToLocal)}`;\n\n return line;\n }\n\n public summarizeGeometryQuery(lines: string[], query: AnyGeometryQuery): void {\n switch (this.verbosity) {\n case GeometrySummaryVerbosity.Detailed:\n lines.push(this.summarizeGeometryQueryDetailed(query));\n break;\n case GeometrySummaryVerbosity.Full:\n lines.push(this.summarizeGeometryQueryFull(query));\n break;\n default:\n lines.push(this.summarizeGeometryQueryBasic(query));\n break;\n }\n }\n\n public summarizeGeometryQueryBasic(query: AnyGeometryQuery): string {\n switch (query.geometryCategory) {\n case \"solid\":\n return query.solidPrimitiveType;\n case \"curvePrimitive\":\n return query.curvePrimitiveType;\n case \"curveCollection\":\n return query.curveCollectionType;\n default:\n return query.geometryCategory;\n }\n }\n\n public summarizeGeometryQueryFull(query: AnyGeometryQuery): string {\n return this.geometryQueryToJson(query);\n }\n\n public geometryQueryToJson(query: AnyGeometryQuery): string {\n try {\n const json = IModelJson.Writer.toIModelJson(query);\n const str = JSON.stringify(json);\n return this.wantSquish ? this.squish(str) : str;\n } catch (err) {\n return BentleyError.getErrorMessage(err);\n }\n }\n\n // Earlin likes to put tons of whitespace + newlines into his JSON. Remove it.\n public squish(str: string): string {\n return str.replace(/\\s+/g, \"\");\n }\n\n public stringify(obj: object): string {\n const json = JSON.stringify(obj);\n return this.wantSquish ? this.squish(json) : json;\n }\n\n public summarizeGeometryQueryDetailed(query: AnyGeometryQuery): string {\n let summary = `${this.summarizeGeometryQueryBasic(query)}: `;\n switch (query.geometryCategory) {\n case \"solid\":\n return summary + this.summarizeSolidPrimitive(query);\n case \"curvePrimitive\":\n return summary + this.summarizeCurvePrimitive(query);\n case \"curveCollection\":\n return summary + this.summarizeCurveCollection(query);\n case \"pointCollection\":\n return `${summary} numPoints: ${query.points.length}`;\n case \"bsurf\":\n return `${summary}'\n ' poleDimension: ${query.poleDimension}'\n ' numPolesTotal: ${query.numPolesTotal()}'\n ' degree[U,V]: ${JSON.stringify([query.degreeUV(UVSelect.uDirection), query.degreeUV(UVSelect.VDirection)])}'\n ' order[U,V]: ${JSON.stringify([query.orderUV(UVSelect.uDirection), query.orderUV(UVSelect.VDirection)])}'\n ' numSpan[U,V]: ${JSON.stringify([query.numSpanUV(UVSelect.uDirection), query.numSpanUV(UVSelect.VDirection)])}'\n ' numPoles[U,V]: ${JSON.stringify([query.numPolesUV(UVSelect.uDirection), query.numPolesUV(UVSelect.VDirection)])}'\n ' poleStep[U,V]: ${JSON.stringify([query.poleStepUV(UVSelect.uDirection), query.poleStepUV(UVSelect.VDirection)])}`;\n case \"polyface\": {\n const data = query.data;\n summary = `${summary} pointCount: ${data.point.length}'\n ' pointIndexCount: ${data.pointIndex.length}`;\n if (query.twoSided)\n summary = `${summary} (two-sided)`;\n if (undefined !== data.normal)\n summary = `${summary} normalCount: ${data.normal.length}`;\n if (undefined !== data.param)\n summary = `${summary} paramCount: ${data.param.length}`;\n if (undefined !== data.color)\n summary = `${summary} colorCount: ${data.color.length}`;\n\n return summary;\n }\n case \"point\":\n return summary + this.geometryQueryToJson(query);\n }\n }\n\n public summarizeSolidPrimitive(solid: SolidPrimitive): string {\n const summary: string = solid.capped ? \" capped\" : \" uncapped\";\n switch (solid.solidPrimitiveType) {\n case \"box\":\n const box: Box = (solid as Box);\n return `${summary}'\n ' baseOrigin: ${JSON.stringify(box.getBaseOrigin().toJSON())}'\n ' topOrigin: ${JSON.stringify(box.getTopOrigin().toJSON())}'\n ' baseX: ${box.getBaseX()}'\n ' baseY: ${box.getBaseY()}`;\n case \"cone\":\n const cone: Cone = solid as Cone;\n return `${summary}'\n ' baseCenterPoint: ${JSON.stringify(cone.getCenterA())}'\n ' topCenterPoint: ${JSON.stringify(cone.getCenterB())}'\n ' baseCenterRadius: ${JSON.stringify(cone.getRadiusA())}'\n ' topCenterRadius: ${JSON.stringify(cone.getRadiusB())}`;\n case \"sphere\":\n const sphere: Sphere = solid as Sphere;\n return `${summary}'\n ' centerPoint: ${JSON.stringify(sphere.cloneCenter().toJSON())}'\n ' radius: ${JSON.stringify(sphere.trueSphereRadius())}`;\n case \"linearSweep\":\n const linearSweep: LinearSweep = solid as LinearSweep;\n return `${summary}'\n ' vector: ${linearSweep.cloneSweepVector().toJSON()}'\n ' curves${this.summarizeCurveCollection(linearSweep.getCurvesRef())}`;\n case \"rotationalSweep\":\n const rotationalSweep: RotationalSweep = solid as RotationalSweep;\n const axis = rotationalSweep.cloneAxisRay();\n return `${summary}'\n ' center: ${axis.origin.toJSON()}'\n ' axis: ${JSON.stringify(axis.direction.toJSON())}'\n ' sweepAngle: ${rotationalSweep.getSweep().degrees}`;\n case \"ruledSweep\":\n const ruledSweep: RuledSweep = solid as RuledSweep;\n const summarizedCollection = ruledSweep.cloneContours().map((curveCollection) => this.summarizeCurveCollection(curveCollection));\n return `${summary}'\n ' isClosedVolume${ruledSweep.isClosedVolume}'\n ' contours: ${JSON.stringify(summarizedCollection)}`;\n case \"torusPipe\":\n const torusPipe: TorusPipe = solid as TorusPipe;\n const vectorX = torusPipe.cloneVectorX();\n const vectorY = torusPipe.cloneVectorY();\n const sweep = torusPipe.getSweepAngle();\n if (torusPipe.getIsReversed()) {\n vectorY.scaleInPlace(-1.0);\n sweep.setRadians(-sweep.radians);\n }\n return `${summary}'\n ' center: ${torusPipe.cloneCenter().toJSON()}'\n ' xyVectors: ${JSON.stringify([vectorX.toJSON(), vectorY.toJSON()])}'\n ' majorRadius: ${torusPipe.getMajorRadius()}'\n ' minorRadius: ${torusPipe.getMinorRadius()}'\n ' sweepAngle: ${sweep.degrees}`;\n }\n }\n\n public summarizeCurvePrimitive(curve: CurvePrimitive): string {\n let summary: string = \"\";\n const writer = new IModelJson.Writer();\n switch (curve.curvePrimitiveType) {\n case \"arc\":\n const arc: Arc3d = curve as Arc3d;\n summary = `${summary} center: ${JSON.stringify(arc.center.toJSON())}`;\n if (undefined !== arc.circularRadius)\n summary = `${summary} radius: ${arc.circularRadius()}`;\n summary = `${summary}'\n ' vectorX:${arc.vector0.toJSON()}'\n ' vectorY:${arc.vector90.toJSON()}'\n ' sweepStartEnd [${arc.sweep.startDegrees}, ${arc.sweep.endDegrees}]`\n + ` curveLength: ${curve.curveLength()}`;\n return summary;\n case \"lineSegment\":\n const lineSegment: LineSegment3d = curve as LineSegment3d;\n summary = `${summary} points: ${JSON.stringify(lineSegment.toJSON())}`;\n summary = `${summary} curveLength: ${curve.curveLength()}`;\n return summary;\n case \"lineString\":\n const lineString: LineString3d = curve as LineString3d;\n summary = `${summary} pointCount: ${lineString.numPoints()}'\n ' curveLength: ${curve.curveLength()}`;\n return summary;\n case \"bsplineCurve\":\n const bsplineCurve: BSplineCurve3d = curve as BSplineCurve3d;\n summary = `${summary}'\n ' curveOrder: ${bsplineCurve.order}'\n ' controlPointsCount: ${bsplineCurve.numPoles}'\n ' curveLength: ${curve.curveLength()}`;\n return summary;\n case \"interpolationCurve\":\n const interpolationCurve: InterpolationCurve3d = curve as InterpolationCurve3d;\n const interpolationProps = interpolationCurve.cloneProps();\n summary = `${summary}'\n ' curveOrder: ${interpolationProps.order}'\n ' controlPointsCount: ${interpolationProps.fitPoints.length}`;\n return summary;\n case \"akimaCurve\":\n const akimaCurve: AkimaCurve3d = curve as AkimaCurve3d;\n const akimaProps = akimaCurve.cloneProps();\n summary = `${summary}'\n ' controlPointsCount: ${akimaProps.fitPoints.length}`;\n return summary;\n case \"bezierCurve\":\n const bezierCurve: BezierCurveBase = curve as BezierCurveBase;\n summary = `${summary}'\n ' curveOrder: ${bezierCurve.order}'\n ' controlPointsCount: ${bezierCurve.numPoles}'\n ' curveLength: ${curve.curveLength()}`;\n return summary;\n case \"transitionSpiral\":\n const transitionSpiral: TransitionSpiral3d = curve as TransitionSpiral3d;\n const json = writer.handleTransitionSpiral(transitionSpiral);\n summary = summary + JSON.stringify(json);\n return summary;\n case \"curveChainWithDistanceIndex\":\n const curveChainWithDistanceIndex: CurveChainWithDistanceIndex = curve as CurveChainWithDistanceIndex;\n const path = curveChainWithDistanceIndex.path;\n summary = `${summary}'\n ' curveLength: ${curve.curveLength()}'\n ' isOpen: ${path.isOpenPath}`;\n return summary;\n }\n }\n\n public summarizeCurveCollection(curves: CurveCollection): string {\n let summary: string = \"\";\n switch (curves.curveCollectionType) {\n case \"loop\":\n const loop: Loop = curves as Loop;\n summary = `${summary} isInner: ${loop.isInner}`;\n break;\n case \"path\":\n const path: Path = curves as Path;\n summary = `${summary} isOpen: ${path.isOpenPath}`;\n break;\n }\n\n return `${summary}'\n ' numCurves: ${curves.collectCurvePrimitives().length}'\n ' boundary: ${curves.dgnBoundaryType()}`;\n }\n}\n\n/** @internal */\nexport function generateGeometrySummaries(request: GeometrySummaryRequestProps, iModel: IModelDb): string {\n const generator = new ResponseGenerator(request, iModel);\n return generator.generateSummaries();\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"IModelCloneContext.d.ts","sourceRoot":"","sources":["../src/IModelCloneContext.ts"],"names":[],"mappings":"AAIA;;GAEG;AACH,OAAO,EAAQ,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAA2B,YAAY,EAA4C,MAAM,oBAAoB,CAAC;AACrH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAE1D,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AAGtC;;GAEG;AACH,qBAAa,kBAAkB;IAC7B,2BAA2B;IAC3B,SAAgB,QAAQ,EAAE,QAAQ,CAAC;IACnC,2BAA2B;IAC3B,SAAgB,QAAQ,EAAE,QAAQ,CAAC;IACnC,gCAAgC;IAChC,OAAO,CAAC,cAAc,CAA+B;IAErD;;;OAGG;gBACgB,QAAQ,EAAE,QAAQ,EAAE,QAAQ,CAAC,EAAE,QAAQ;IAM1D,sIAAsI;IACtI,IAAW,gBAAgB,IAAI,OAAO,CAA4C;IAElF,4EAA4E;IACrE,OAAO,IAAI,IAAI;IAEtB;;OAEG;IACI,IAAI,CAAC,cAAc,EAAE,MAAM,GAAG,IAAI;IAEzC;;;;OAIG;IACI,aAAa,CAAC,kBAAkB,EAAE,MAAM,EAAE,kBAAkB,EAAE,MAAM,GAAG,IAAI;IAMlF,uFAAuF;IAChF,iBAAiB,CAAC,mBAAmB,EAAE,MAAM,EAAE,mBAAmB,EAAE,MAAM,GAAG,IAAI;IAIxF,2FAA2F;IACpF,YAAY,CAAC,QAAQ,EAAE,UAAU,EA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C,eAAe,CAAC,CAAC,YAAoB,EAAE,IAAsB,EAAE,EAAE;YAC7E,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,KAAM,aAAqB,CAAC,YAAY,CAAC,CAAC,EAAE;gBAC9E,kBAA0B,CAAC,YAAY,CAAC,GAAG,4BAAc,CAAC,IAAI,CAAC;aACjE;QACH,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC,sDAAsD;QACjE,IAAI,IAAI,CAAC,gBAAgB,EAAE;YACzB,kHAAkH;YAClH,kBAAkB,CAAC,cAAc,GAAG,aAAa,CAAC,cAAc,CAAC;YACjE,IAAI,2BAAa,CAAC,IAAI,CAAC,UAAU,KAAK,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,OAAO,CAAC,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE;gBAC7G,kBAAkB,CAAC,IAAI,CAAC,KAAK,GAAG,oBAAM,CAAC,aAAa,CAAC;aACtD;SACF;QACD,MAAM,OAAO,GAAQ,IAAI,CAAC,QAAQ,CAAC,UAAU,CAAiB,aAAa,CAAC,aAAa,CAAC,CAAC,CAAC,iEAAiE;QAC7J,OAAO,CAAC,QAAQ,CAAC,IAAI,EAAE,aAAa,EAAE,kBAAkB,CAAC,CAAC;QAC1D,OAAO,kBAAkB,CAAC;IAC5B,CAAC;CACF;AApID,gDAoIC","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 iModels\r\n */\r\nimport { Id64, Id64String } from \"@itwin/core-bentley\";\r\nimport { CodeScopeSpec, CodeSpec, ElementProps, IModel, PropertyMetaData, RelatedElement } from \"@itwin/core-common\";\r\nimport { IModelJsNative } from \"@bentley/imodeljs-native\";\r\nimport { SubCategory } from \"./Category\";\r\nimport { Element } from \"./Element\";\r\nimport { IModelDb } from \"./IModelDb\";\r\nimport { IModelHost } from \"./IModelHost\";\r\n\r\n/** The context for transforming a *source* Element to a *target* Element and remapping internal identifiers to the target iModel.\r\n * @beta\r\n */\r\nexport class IModelCloneContext {\r\n /** The source IModelDb. */\r\n public readonly sourceDb: IModelDb;\r\n /** The target IModelDb. */\r\n public readonly targetDb: IModelDb;\r\n /** The native import context */\r\n private _nativeContext: IModelJsNative.ImportContext;\r\n\r\n /** Construct a new IModelCloneContext.\r\n * @param sourceDb The source IModelDb.\r\n * @param targetDb If provided the target IModelDb. If not provided, the source and target are the same IModelDb.\r\n */\r\n public constructor(sourceDb: IModelDb, targetDb?: IModelDb) {\r\n this.sourceDb = sourceDb;\r\n this.targetDb = (undefined !== targetDb) ? targetDb : sourceDb;\r\n this._nativeContext = new IModelHost.platform.ImportContext(this.sourceDb.nativeDb, this.targetDb.nativeDb);\r\n }\r\n\r\n /** Returns `true` if this context is for transforming between 2 iModels and `false` if it for transforming within the same iModel. */\r\n public get isBetweenIModels(): boolean { return this.sourceDb !== this.targetDb; }\r\n\r\n /** Dispose any native resources associated with this IModelCloneContext. */\r\n public dispose(): void { this._nativeContext.dispose(); }\r\n\r\n /** Debugging aid that dumps the Id remapping details and other information to the specified output file.\r\n * @internal\r\n */\r\n public dump(outputFileName: string): void { this._nativeContext.dump(outputFileName); }\r\n\r\n /** Add a rule that remaps the specified source [CodeSpec]($common) to the specified target [CodeSpec]($common).\r\n * @param sourceCodeSpecName The name of the CodeSpec from the source iModel.\r\n * @param targetCodeSpecName The name of the CodeSpec from the target iModel.\r\n * @throws [[IModelError]] if either CodeSpec could not be found.\r\n */\r\n public remapCodeSpec(sourceCodeSpecName: string, targetCodeSpecName: string): void {\r\n const sourceCodeSpec: CodeSpec = this.sourceDb.codeSpecs.getByName(sourceCodeSpecName);\r\n const targetCodeSpec: CodeSpec = this.targetDb.codeSpecs.getByName(targetCodeSpecName);\r\n this._nativeContext.addCodeSpecId(sourceCodeSpec.id, targetCodeSpec.id);\r\n }\r\n\r\n /** Add a rule that remaps the specified source class to the specified target class. */\r\n public remapElementClass(sourceClassFullName: string, targetClassFullName: string): void {\r\n this._nativeContext.addClass(sourceClassFullName, targetClassFullName);\r\n }\r\n\r\n /** Add a rule that remaps the specified source Element to the specified target Element. */\r\n public remapElement(sourceId: Id64String, targetId: Id64String): void {\r\n this._nativeContext.addElementId(sourceId, targetId);\r\n }\r\n\r\n /** Remove a rule that remaps the specified source Element. */\r\n public removeElement(sourceId: Id64String): void {\r\n this._nativeContext.removeElementId(sourceId);\r\n }\r\n\r\n /** Look up a target CodeSpecId from the source CodeSpecId.\r\n * @returns the target CodeSpecId or [Id64.invalid]($bentley) if a mapping not found.\r\n */\r\n public findTargetCodeSpecId(sourceId: Id64String): Id64String {\r\n if (Id64.invalid === sourceId) {\r\n return Id64.invalid;\r\n }\r\n return this._nativeContext.findCodeSpecId(sourceId);\r\n }\r\n\r\n /** Look up a target ElementId from the source ElementId.\r\n * @returns the target ElementId or [Id64.invalid]($bentley) if a mapping not found.\r\n */\r\n public findTargetElementId(sourceElementId: Id64String): Id64String {\r\n if (Id64.invalid === sourceElementId) {\r\n return Id64.invalid;\r\n }\r\n return this._nativeContext.findElementId(sourceElementId);\r\n }\r\n\r\n /** Filter out geometry entries in the specified SubCategory from GeometryStreams in the target iModel.\r\n * @note It is not possible to filter out a *default* SubCategory. A request to do so will be ignored.\r\n * @see [SubCategory.isDefaultSubCategory]($backend)\r\n */\r\n public filterSubCategory(sourceSubCategoryId: Id64String): void {\r\n const sourceSubCategory = this.sourceDb.elements.tryGetElement<SubCategory>(sourceSubCategoryId, SubCategory);\r\n if (sourceSubCategory && !sourceSubCategory.isDefaultSubCategory) {\r\n this._nativeContext.filterSubCategoryId(sourceSubCategoryId);\r\n }\r\n }\r\n\r\n /** Returns `true` if there are any SubCategories being filtered. */\r\n public get hasSubCategoryFilter(): boolean {\r\n return this._nativeContext.hasSubCategoryFilter();\r\n }\r\n\r\n /** Returns `true` if this SubCategory is being filtered. */\r\n public isSubCategoryFiltered(subCategoryId: Id64String): boolean {\r\n return this._nativeContext.isSubCategoryFiltered(subCategoryId);\r\n }\r\n\r\n /** Import the specified font from the source iModel into the target iModel.\r\n * @internal\r\n */\r\n public importFont(sourceFontNumber: number): void {\r\n this._nativeContext.importFont(sourceFontNumber);\r\n }\r\n\r\n /** Import a single CodeSpec from the source iModel into the target iModel.\r\n * @internal\r\n */\r\n public importCodeSpec(sourceCodeSpecId: Id64String): void {\r\n this._nativeContext.importCodeSpec(sourceCodeSpecId);\r\n }\r\n\r\n /** Clone the specified source Element into ElementProps for the target iModel.\r\n * @internal\r\n */\r\n public cloneElement(sourceElement: Element, cloneOptions?: IModelJsNative.CloneElementOptions): ElementProps {\r\n const targetElementProps: ElementProps = this._nativeContext.cloneElement(sourceElement.id, cloneOptions);\r\n // Ensure that all NavigationProperties in targetElementProps have a defined value so \"clearing\" changes will be part of the JSON used for update\r\n sourceElement.forEachProperty((propertyName: string, meta: PropertyMetaData) => {\r\n if ((meta.isNavigation) && (undefined === (sourceElement as any)[propertyName])) {\r\n (targetElementProps as any)[propertyName] = RelatedElement.none;\r\n }\r\n }, false); // exclude custom because C++ has already handled them\r\n if (this.isBetweenIModels) {\r\n // The native C++ cloneElement strips off federationGuid, want to put it back if transformation is between iModels\r\n targetElementProps.federationGuid = sourceElement.federationGuid;\r\n if (CodeScopeSpec.Type.Repository === this.targetDb.codeSpecs.getById(targetElementProps.code.spec).scopeType) {\r\n targetElementProps.code.scope = IModel.rootSubjectId;\r\n }\r\n }\r\n const jsClass: any = this.sourceDb.getJsClass<typeof Element>(sourceElement.classFullName); // declared as \"any\" so we can call the protected onCloned method\r\n jsClass.onCloned(this, sourceElement, targetElementProps);\r\n return targetElementProps;\r\n }\r\n}\r\n"]}
|