@itwin/core-common 5.0.0-dev.106 → 5.0.0-dev.109

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/lib/cjs/CatalogIModel.d.ts +152 -0
  2. package/lib/cjs/CatalogIModel.d.ts.map +1 -0
  3. package/lib/cjs/CatalogIModel.js +30 -0
  4. package/lib/cjs/CatalogIModel.js.map +1 -0
  5. package/lib/cjs/CesiumIonAssets.d.ts +23 -0
  6. package/lib/cjs/CesiumIonAssets.d.ts.map +1 -0
  7. package/lib/cjs/CesiumIonAssets.js +32 -0
  8. package/lib/cjs/CesiumIonAssets.js.map +1 -0
  9. package/lib/cjs/ITwinCoreErrors.d.ts +87 -8
  10. package/lib/cjs/ITwinCoreErrors.d.ts.map +1 -1
  11. package/lib/cjs/ITwinCoreErrors.js +74 -12
  12. package/lib/cjs/ITwinCoreErrors.js.map +1 -1
  13. package/lib/cjs/TerrainSettings.d.ts +0 -12
  14. package/lib/cjs/TerrainSettings.d.ts.map +1 -1
  15. package/lib/cjs/TerrainSettings.js +3 -15
  16. package/lib/cjs/TerrainSettings.js.map +1 -1
  17. package/lib/cjs/core-common.d.ts +2 -0
  18. package/lib/cjs/core-common.d.ts.map +1 -1
  19. package/lib/cjs/core-common.js +2 -0
  20. package/lib/cjs/core-common.js.map +1 -1
  21. package/lib/esm/CatalogIModel.d.ts +152 -0
  22. package/lib/esm/CatalogIModel.d.ts.map +1 -0
  23. package/lib/esm/CatalogIModel.js +27 -0
  24. package/lib/esm/CatalogIModel.js.map +1 -0
  25. package/lib/esm/CesiumIonAssets.d.ts +23 -0
  26. package/lib/esm/CesiumIonAssets.d.ts.map +1 -0
  27. package/lib/esm/CesiumIonAssets.js +29 -0
  28. package/lib/esm/CesiumIonAssets.js.map +1 -0
  29. package/lib/esm/ITwinCoreErrors.d.ts +87 -8
  30. package/lib/esm/ITwinCoreErrors.d.ts.map +1 -1
  31. package/lib/esm/ITwinCoreErrors.js +73 -11
  32. package/lib/esm/ITwinCoreErrors.js.map +1 -1
  33. package/lib/esm/TerrainSettings.d.ts +0 -12
  34. package/lib/esm/TerrainSettings.d.ts.map +1 -1
  35. package/lib/esm/TerrainSettings.js +1 -13
  36. package/lib/esm/TerrainSettings.js.map +1 -1
  37. package/lib/esm/core-common.d.ts +2 -0
  38. package/lib/esm/core-common.d.ts.map +1 -1
  39. package/lib/esm/core-common.js +2 -0
  40. package/lib/esm/core-common.js.map +1 -1
  41. package/package.json +6 -6
@@ -0,0 +1,152 @@
1
+ /** @packageDocumentation
2
+ * @module NativeApp
3
+ */
4
+ import { Id64String, ITwinError } from "@itwin/core-bentley";
5
+ import { LocalFileName } from "./ChangesetProps";
6
+ import { IModelConnectionProps, SnapshotOpenOptions } from "./IModel";
7
+ /**
8
+ * Errors produced by the [[CatalogIModel]] API.
9
+ * @beta
10
+ */
11
+ export declare namespace CatalogError {
12
+ const scope = "itwin-Catalog";
13
+ type Key = "invalid-seed-catalog" | "manifest-missing";
14
+ /** Determine whether an error object is a CatalogError */
15
+ function isError(error: unknown, key?: Key): error is ITwinError;
16
+ /** Instantiate and throw a CatalogError */
17
+ function throwError<T extends ITwinError>(key: Key, e: Omit<T, "name" | "iTwinErrorId">): never;
18
+ }
19
+ /** A "catalog iModel" is an [[IModel]] containing elements (e.g., component definitions) that are intended to be copied into another iModel by applications.
20
+ * They can be stored in [BlobContainer]($backend)s managed by a "reference data service" that uses [semantic versioning](https://semver.org/), much like [WorkspaceDb]($backend)s.
21
+ * @see [CatalogDb]($backend) to interact with catalog iModels on the backend
22
+ * @see [CatalogConnection]($frontend) to interact with catalog iModels on the frontend.
23
+ * @beta
24
+ */
25
+ export declare namespace CatalogIModel {
26
+ /** Metadata describing a catalog iModel.
27
+ * @note Only the [[catalogName]] field is required, and users may add additional fields for their own purposes.
28
+ * @note The manifest is stored inside of the CatalogIModel, so it is versioned along with the rest of the catalog's contents.
29
+ * @beta
30
+ */
31
+ interface Manifest {
32
+ /** The iTwinId for the Catalog */
33
+ readonly iTwinId?: Id64String;
34
+ /**
35
+ * The name of the Catalog to be shown in user interfaces. Organizations should attempt to make this name informative enough
36
+ * so that uses may refer to it in conversations. It should also be unique enough that there's no confusion when it appears in
37
+ * lists of catalogs.
38
+ * @note it is possible and valid to change the catalogName between versions of a CatalogIModel (e.g. incorporating a date).
39
+ */
40
+ readonly catalogName: string;
41
+ /** A description of the contents of this catalog to help users understand its purpose and appropriate usage. */
42
+ readonly description?: string;
43
+ /** The name of the person to contact with questions about this catalog */
44
+ readonly contactName?: string;
45
+ /** The name of the person who last modified this catalog. */
46
+ lastEditedBy?: string;
47
+ }
48
+ /** Arguments for creating a new [BlobContainer]($backend) that holds (versions of) a CatalogIModel. */
49
+ interface CreateNewContainerArgs {
50
+ /** supplies the iTwinId for the new container */
51
+ readonly iTwinId: Id64String;
52
+ /** metadata stored with the new container */
53
+ readonly metadata: {
54
+ /** a "name" for the Catalog container. Should be long enough to be unique, but this is not enforced. */
55
+ label: string;
56
+ /** Optional human-readable explanation of the information held in the container. This will be displayed in the administrator RBAC panel, and on usage reports. */
57
+ description?: string;
58
+ /** optional properties for the container */
59
+ json?: {
60
+ [key: string]: any;
61
+ };
62
+ };
63
+ /** The manifest to be stored in the catalog */
64
+ readonly manifest: Manifest;
65
+ /** The name for the CatalogIModel database within the container. May not contain a version. Default is "catalog-db" */
66
+ readonly dbName?: string;
67
+ /** version for the catalog created [[localCatalogFile]]. Defaults to "0.0.0" */
68
+ readonly version?: string;
69
+ /** A filename on the local computer of the "seed" CatalogIModel to be uploaded into the new container */
70
+ readonly localCatalogFile: LocalFileName;
71
+ }
72
+ /** Properties of a newly created container created from [[CatalogIModel.CreateNewContainerArgs]]. Most importantly, this holds the ContainerId of the new container. */
73
+ interface NewContainerProps {
74
+ /** The ContainerId of the new container (usually a [Guid]($bentley)). Applications should store this value to access the container via the CatalogIModel apis. */
75
+ readonly containerId: string;
76
+ /** the uri of the BlobContainer service where the new container resides. */
77
+ readonly baseUri: string;
78
+ /** name of the blob storage provider. */
79
+ readonly provider: "azure" | "google";
80
+ }
81
+ /** Properties to identify a specific CatalogIModel within a container. */
82
+ interface NameAndVersion {
83
+ /** The name of the catalog database. Defaults to "catalog-db" for CatalogIModels stored in cloud containers. */
84
+ readonly dbName?: string;
85
+ /** The range of acceptable versions of the database of the specified [[dbName]].
86
+ * If not present, defaults to the newest available version.
87
+ */
88
+ readonly version?: VersionRange;
89
+ }
90
+ /** Arguments to open an existing version of a CatalogIModel. */
91
+ interface OpenArgs extends NameAndVersion, SnapshotOpenOptions {
92
+ /** The ContainerId of the cloud container. If not present, dbName is the name of a file on the local computer. */
93
+ containerId?: string;
94
+ /** If true, attempt to synchronize the container with any changes in the cloud. Since this automatically happens the first time a
95
+ * container is accessed within a session, this is usually not necessary except for tests.
96
+ */
97
+ syncWithCloud?: boolean;
98
+ /** Start a prefetch operation on the CatalogIModel as it is opened. */
99
+ prefetch?: boolean;
100
+ }
101
+ /** Arguments to create a new version of a CatalogIModel from (a copy of) an existing version in a cloud container. */
102
+ interface CreateNewVersionArgs {
103
+ /** The id of cloud container. */
104
+ readonly containerId: string;
105
+ /** the source version of the CatalogIModel, from which the new version will copied. */
106
+ readonly fromDb: NameAndVersion;
107
+ /** The type of version increment to apply to the source version. */
108
+ readonly versionType: "major" | "minor" | "patch" | "premajor" | "preminor" | "prepatch" | "prerelease";
109
+ /** For prerelease versions, a string that becomes part of the version name. */
110
+ readonly identifier?: string;
111
+ }
112
+ /** A [semver string](https://github.com/npm/node-semver?tab=readme-ov-file#ranges) describing a range of acceptable [[CatalogIModel]]s,
113
+ * e.g., ">=1.2.7 <1.3.0".
114
+ */
115
+ type VersionRange = string;
116
+ /** The name of the ipc channel for [[IpcMethods]]
117
+ * @internal
118
+ */
119
+ type IpcChannel = "catalogIModel/ipc";
120
+ /** @internal */
121
+ interface IpcMethods {
122
+ /** create a new container from the BlobContainerService for holding a CatalogIModel. Also uploads the seed file */
123
+ createNewContainer(args: CreateNewContainerArgs): Promise<NewContainerProps>;
124
+ /** Acquire the write lock for a CatalogIModel container. */
125
+ acquireWriteLock(args: {
126
+ containerId: string;
127
+ username: string;
128
+ }): Promise<void>;
129
+ /** Release the write lock for a CatalogIModel container. */
130
+ releaseWriteLock(args: {
131
+ containerId: string;
132
+ abandon?: true;
133
+ }): Promise<void>;
134
+ /** create a new version of a CatalogIModel from an existing version. */
135
+ createNewVersion(args: CreateNewVersionArgs): Promise<{
136
+ oldDb: NameAndVersion;
137
+ newDb: NameAndVersion;
138
+ }>;
139
+ /** Attempt to open a CatalogIModel readonly*/
140
+ openReadonly(args: OpenArgs): Promise<IModelConnectionProps>;
141
+ /** Attempt to open a CatalogIModel for editing */
142
+ openEditable(args: OpenArgs): Promise<IModelConnectionProps>;
143
+ /** Get the manifest and version number for an open CatalogConnection. */
144
+ getInfo(key: string): Promise<{
145
+ manifest?: CatalogIModel.Manifest;
146
+ version: string;
147
+ }>;
148
+ /** Update the manifest stored in an open EditableCatalog */
149
+ updateCatalogManifest(key: string, manifest: CatalogIModel.Manifest): Promise<void>;
150
+ }
151
+ }
152
+ //# sourceMappingURL=CatalogIModel.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CatalogIModel.d.ts","sourceRoot":"","sources":["../../src/CatalogIModel.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,qBAAqB,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAEtE;;;GAGG;AACH,yBAAiB,YAAY,CAAC;IACrB,MAAM,KAAK,kBAAkB,CAAC;IAErC,KAAY,GAAG,GACb,sBAAsB,GACtB,kBAAkB,CAAC;IAErB,0DAA0D;IAC1D,SAAgB,OAAO,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,CAAC,EAAE,GAAG,GA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,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAA;SAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;QACjF,4DAA4D;QAC5D,gBAAgB,CAAC,IAAI,EAAE;YAAE,WAAW,EAAE,MAAM,CAAC;YAAC,OAAO,CAAC,EAAE,IAAI,CAAA;SAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;QAC/E,wEAAwE;QACxE,gBAAgB,CAAC,IAAI,EAAE,oBAAoB,GAAG,OAAO,CAAC;YAAE,KAAK,EAAE,cAAc,CAAC;YAAC,KAAK,EAAE,cAAc,CAAA;SAAE,CAAC,CAAC;QACxG,8CAA8C;QAC9C,YAAY,CAAC,IAAI,EAAE,QAAQ,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAAC;QAC7D,kDAAkD;QAClD,YAAY,CAAC,IAAI,EAAE,QAAQ,GAAG,OAAO,CAAC,qBAAqB,CAAC,CAAC;QAC7D,yEAAyE;QACzE,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;YAAE,QAAQ,CAAC,EAAE,aAAa,CAAC,QAAQ,CAAC;YAAC,OAAO,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QACtF,4DAA4D;QAC5D,qBAAqB,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,EAAE,aAAa,CAAC,QAAQ,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;KACrF;CACF"}
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ /*---------------------------------------------------------------------------------------------
3
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
4
+ * See LICENSE.md in the project root for license terms and full copyright notice.
5
+ *--------------------------------------------------------------------------------------------*/
6
+ /** @packageDocumentation
7
+ * @module NativeApp
8
+ */
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ exports.CatalogError = void 0;
11
+ const core_bentley_1 = require("@itwin/core-bentley");
12
+ /**
13
+ * Errors produced by the [[CatalogIModel]] API.
14
+ * @beta
15
+ */
16
+ var CatalogError;
17
+ (function (CatalogError) {
18
+ CatalogError.scope = "itwin-Catalog";
19
+ /** Determine whether an error object is a CatalogError */
20
+ function isError(error, key) {
21
+ return core_bentley_1.ITwinError.isError(error, CatalogError.scope, key);
22
+ }
23
+ CatalogError.isError = isError;
24
+ /** Instantiate and throw a CatalogError */
25
+ function throwError(key, e) {
26
+ core_bentley_1.ITwinError.throwError({ ...e, iTwinErrorId: { scope: CatalogError.scope, key } });
27
+ }
28
+ CatalogError.throwError = throwError;
29
+ })(CatalogError || (exports.CatalogError = CatalogError = {}));
30
+ //# sourceMappingURL=CatalogIModel.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CatalogIModel.js","sourceRoot":"","sources":["../../src/CatalogIModel.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAA6D;AAI7D;;;GAGG;AACH,IAAiB,YAAY,CAgB5B;AAhBD,WAAiB,YAAY;IACd,kBAAK,GAAG,eAAe,CAAC;IAMrC,0DAA0D;IAC1D,SAAgB,OAAO,CAAC,KAAc,EAAE,GAAS;QAC/C,OAAO,yBAAU,CAAC,OAAO,CAAa,KAAK,EAAE,aAAA,KAAK,EAAE,GAAG,CAAC,CAAC;IAC3D,CAAC;IAFe,oBAAO,UAEtB,CAAA;IAED,2CAA2C;IAC3C,SAAgB,UAAU,CAAuB,GAAQ,EAAE,CAAmC;QAC5F,yBAAU,CAAC,UAAU,CAAa,EAAE,GAAG,CAAC,EAAE,YAAY,EAAE,EAAE,KAAK,EAAL,aAAA,KAAK,EAAE,GAAG,EAAE,EAAE,CAAC,CAAC;IAC5E,CAAC;IAFe,uBAAU,aAEzB,CAAA;AACH,CAAC,EAhBgB,YAAY,4BAAZ,YAAY,QAgB5B","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 NativeApp\n */\n\nimport { Id64String, ITwinError } from \"@itwin/core-bentley\";\nimport { LocalFileName } from \"./ChangesetProps\";\nimport { IModelConnectionProps, SnapshotOpenOptions } from \"./IModel\";\n\n/**\n * Errors produced by the [[CatalogIModel]] API.\n * @beta\n */\nexport namespace CatalogError {\n export const scope = \"itwin-Catalog\";\n\n export type Key =\n \"invalid-seed-catalog\" |\n \"manifest-missing\";\n\n /** Determine whether an error object is a CatalogError */\n export function isError(error: unknown, key?: Key): error is ITwinError {\n return ITwinError.isError<ITwinError>(error, scope, key);\n }\n\n /** Instantiate and throw a CatalogError */\n export function throwError<T extends ITwinError>(key: Key, e: Omit<T, \"name\" | \"iTwinErrorId\">): never {\n ITwinError.throwError<ITwinError>({ ...e, iTwinErrorId: { scope, key } });\n }\n}\n\n/** A \"catalog iModel\" is an [[IModel]] containing elements (e.g., component definitions) that are intended to be copied into another iModel by applications.\n * They can be stored in [BlobContainer]($backend)s managed by a \"reference data service\" that uses [semantic versioning](https://semver.org/), much like [WorkspaceDb]($backend)s.\n * @see [CatalogDb]($backend) to interact with catalog iModels on the backend\n * @see [CatalogConnection]($frontend) to interact with catalog iModels on the frontend.\n * @beta\n */\nexport namespace CatalogIModel {\n\n /** Metadata describing a catalog iModel.\n * @note Only the [[catalogName]] field is required, and users may add additional fields for their own purposes.\n * @note The manifest is stored inside of the CatalogIModel, so it is versioned along with the rest of the catalog's contents.\n * @beta\n */\n export interface Manifest {\n /** The iTwinId for the Catalog */\n readonly iTwinId?: Id64String;\n\n /**\n * The name of the Catalog to be shown in user interfaces. Organizations should attempt to make this name informative enough\n * so that uses may refer to it in conversations. It should also be unique enough that there's no confusion when it appears in\n * lists of catalogs.\n * @note it is possible and valid to change the catalogName between versions of a CatalogIModel (e.g. incorporating a date).\n */\n readonly catalogName: string;\n /** A description of the contents of this catalog to help users understand its purpose and appropriate usage. */\n readonly description?: string;\n /** The name of the person to contact with questions about this catalog */\n readonly contactName?: string;\n /** The name of the person who last modified this catalog. */\n lastEditedBy?: string;\n }\n\n /** Arguments for creating a new [BlobContainer]($backend) that holds (versions of) a CatalogIModel. */\n export interface CreateNewContainerArgs {\n /** supplies the iTwinId for the new container */\n readonly iTwinId: Id64String;\n /** metadata stored with the new container */\n readonly metadata: {\n /** a \"name\" for the Catalog container. Should be long enough to be unique, but this is not enforced. */\n label: string;\n /** Optional human-readable explanation of the information held in the container. This will be displayed in the administrator RBAC panel, and on usage reports. */\n description?: string;\n /** optional properties for the container */\n json?: { [key: string]: any };\n }\n\n /** The manifest to be stored in the catalog */\n readonly manifest: Manifest;\n /** The name for the CatalogIModel database within the container. May not contain a version. Default is \"catalog-db\" */\n readonly dbName?: string,\n /** version for the catalog created [[localCatalogFile]]. Defaults to \"0.0.0\" */\n readonly version?: string;\n /** A filename on the local computer of the \"seed\" CatalogIModel to be uploaded into the new container */\n readonly localCatalogFile: LocalFileName;\n }\n\n /** Properties of a newly created container created from [[CatalogIModel.CreateNewContainerArgs]]. Most importantly, this holds the ContainerId of the new container. */\n export interface NewContainerProps {\n /** The ContainerId of the new container (usually a [Guid]($bentley)). Applications should store this value to access the container via the CatalogIModel apis. */\n readonly containerId: string;\n /** the uri of the BlobContainer service where the new container resides. */\n readonly baseUri: string;\n /** name of the blob storage provider. */\n readonly provider: \"azure\" | \"google\";\n }\n\n /** Properties to identify a specific CatalogIModel within a container. */\n export interface NameAndVersion {\n /** The name of the catalog database. Defaults to \"catalog-db\" for CatalogIModels stored in cloud containers. */\n readonly dbName?: string;\n /** The range of acceptable versions of the database of the specified [[dbName]].\n * If not present, defaults to the newest available version.\n */\n readonly version?: VersionRange;\n }\n\n /** Arguments to open an existing version of a CatalogIModel. */\n export interface OpenArgs extends NameAndVersion, SnapshotOpenOptions {\n /** The ContainerId of the cloud container. If not present, dbName is the name of a file on the local computer. */\n containerId?: string;\n /** If true, attempt to synchronize the container with any changes in the cloud. Since this automatically happens the first time a\n * container is accessed within a session, this is usually not necessary except for tests.\n */\n syncWithCloud?: boolean;\n /** Start a prefetch operation on the CatalogIModel as it is opened. */\n prefetch?: boolean;\n }\n\n /** Arguments to create a new version of a CatalogIModel from (a copy of) an existing version in a cloud container. */\n export interface CreateNewVersionArgs {\n /** The id of cloud container. */\n readonly containerId: string;\n /** the source version of the CatalogIModel, from which the new version will copied. */\n readonly fromDb: NameAndVersion;\n /** The type of version increment to apply to the source version. */\n readonly versionType: \"major\" | \"minor\" | \"patch\" | \"premajor\" | \"preminor\" | \"prepatch\" | \"prerelease\";\n /** For prerelease versions, a string that becomes part of the version name. */\n readonly identifier?: string;\n }\n\n /** A [semver string](https://github.com/npm/node-semver?tab=readme-ov-file#ranges) describing a range of acceptable [[CatalogIModel]]s,\n * e.g., \">=1.2.7 <1.3.0\".\n */\n export type VersionRange = string;\n\n /** The name of the ipc channel for [[IpcMethods]]\n * @internal\n */\n export type IpcChannel = \"catalogIModel/ipc\";\n\n /** @internal */\n export interface IpcMethods {\n /** create a new container from the BlobContainerService for holding a CatalogIModel. Also uploads the seed file */\n createNewContainer(args: CreateNewContainerArgs): Promise<NewContainerProps>;\n /** Acquire the write lock for a CatalogIModel container. */\n acquireWriteLock(args: { containerId: string, username: string }): Promise<void>;\n /** Release the write lock for a CatalogIModel container. */\n releaseWriteLock(args: { containerId: string, abandon?: true }): Promise<void>;\n /** create a new version of a CatalogIModel from an existing version. */\n createNewVersion(args: CreateNewVersionArgs): Promise<{ oldDb: NameAndVersion, newDb: NameAndVersion }>;\n /** Attempt to open a CatalogIModel readonly*/\n openReadonly(args: OpenArgs): Promise<IModelConnectionProps>;\n /** Attempt to open a CatalogIModel for editing */\n openEditable(args: OpenArgs): Promise<IModelConnectionProps>;\n /** Get the manifest and version number for an open CatalogConnection. */\n getInfo(key: string): Promise<{ manifest?: CatalogIModel.Manifest, version: string }>;\n /** Update the manifest stored in an open EditableCatalog */\n updateCatalogManifest(key: string, manifest: CatalogIModel.Manifest): Promise<void>;\n }\n}\n"]}
@@ -0,0 +1,23 @@
1
+ /** @packageDocumentation
2
+ * @module DisplayStyles
3
+ */
4
+ /** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing global terrain data.
5
+ * These values are appropriate to use with [[TerrainSettings.dataSource]] when [[TerrainSettings.providerName]] is set to "CesiumWorldTerrain".
6
+ * You may alternatively use the Id of any ion asset to which you have access.
7
+ * @see [[TerrainSettings.fromCesiumIonAsset]] to create TerrainSettings that obtain terrain from a specified ion asset.
8
+ * @public
9
+ */
10
+ export declare enum CesiumTerrainAssetId {
11
+ /** Default [global 3d terrain](https://cesium.com/platform/cesium-ion/content/cesium-world-terrain/). */
12
+ Default = "1",
13
+ /** Global 3d terrain that includes [bathymetry](https://cesium.com/platform/cesium-ion/content/cesium-world-bathymetry/) (seafloor) terrain. */
14
+ Bathymetry = "2426648"
15
+ }
16
+ /** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing data not covered by [[CesiumTerrainAssetId]].
17
+ * @beta
18
+ */
19
+ export declare enum CesiumIonAssetId {
20
+ /** [Cesium OSM Buildings](https://cesium.com/platform/cesium-ion/content/cesium-osm-buildings/). */
21
+ OSMBuildings = "96188"
22
+ }
23
+ //# sourceMappingURL=CesiumIonAssets.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CesiumIonAssets.d.ts","sourceRoot":"","sources":["../../src/CesiumIonAssets.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH;;;;;GAKG;AACH,oBAAY,oBAAoB;IAC9B,yGAAyG;IACzG,OAAO,MAAM;IACb,gJAAgJ;IAChJ,UAAU,YAAY;CACvB;AAED;;GAEG;AACH,oBAAY,gBAAgB;IAC1B,oGAAoG;IACpG,YAAY,UAAU;CACvB"}
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ /*---------------------------------------------------------------------------------------------
3
+ * Copyright (c) Bentley Systems, Incorporated. All rights reserved.
4
+ * See LICENSE.md in the project root for license terms and full copyright notice.
5
+ *--------------------------------------------------------------------------------------------*/
6
+ /** @packageDocumentation
7
+ * @module DisplayStyles
8
+ */
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ exports.CesiumIonAssetId = exports.CesiumTerrainAssetId = void 0;
11
+ /** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing global terrain data.
12
+ * These values are appropriate to use with [[TerrainSettings.dataSource]] when [[TerrainSettings.providerName]] is set to "CesiumWorldTerrain".
13
+ * You may alternatively use the Id of any ion asset to which you have access.
14
+ * @see [[TerrainSettings.fromCesiumIonAsset]] to create TerrainSettings that obtain terrain from a specified ion asset.
15
+ * @public
16
+ */
17
+ var CesiumTerrainAssetId;
18
+ (function (CesiumTerrainAssetId) {
19
+ /** Default [global 3d terrain](https://cesium.com/platform/cesium-ion/content/cesium-world-terrain/). */
20
+ CesiumTerrainAssetId["Default"] = "1";
21
+ /** Global 3d terrain that includes [bathymetry](https://cesium.com/platform/cesium-ion/content/cesium-world-bathymetry/) (seafloor) terrain. */
22
+ CesiumTerrainAssetId["Bathymetry"] = "2426648";
23
+ })(CesiumTerrainAssetId || (exports.CesiumTerrainAssetId = CesiumTerrainAssetId = {}));
24
+ /** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing data not covered by [[CesiumTerrainAssetId]].
25
+ * @beta
26
+ */
27
+ var CesiumIonAssetId;
28
+ (function (CesiumIonAssetId) {
29
+ /** [Cesium OSM Buildings](https://cesium.com/platform/cesium-ion/content/cesium-osm-buildings/). */
30
+ CesiumIonAssetId["OSMBuildings"] = "96188";
31
+ })(CesiumIonAssetId || (exports.CesiumIonAssetId = CesiumIonAssetId = {}));
32
+ //# sourceMappingURL=CesiumIonAssets.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CesiumIonAssets.js","sourceRoot":"","sources":["../../src/CesiumIonAssets.ts"],"names":[],"mappings":";AACA;;;+FAG+F;AAC/F;;GAEG;;;AAEH;;;;;GAKG;AACH,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,yGAAyG;IACzG,qCAAa,CAAA;IACb,gJAAgJ;IAChJ,8CAAsB,CAAA;AACxB,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B;AAED;;GAEG;AACH,IAAY,gBAGX;AAHD,WAAY,gBAAgB;IAC1B,oGAAoG;IACpG,0CAAsB,CAAA;AACxB,CAAC,EAHW,gBAAgB,gCAAhB,gBAAgB,QAG3B","sourcesContent":["\n/*---------------------------------------------------------------------------------------------\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 DisplayStyles\n */\n\n/** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing global terrain data.\n * These values are appropriate to use with [[TerrainSettings.dataSource]] when [[TerrainSettings.providerName]] is set to \"CesiumWorldTerrain\".\n * You may alternatively use the Id of any ion asset to which you have access.\n * @see [[TerrainSettings.fromCesiumIonAsset]] to create TerrainSettings that obtain terrain from a specified ion asset.\n * @public\n */\nexport enum CesiumTerrainAssetId {\n /** Default [global 3d terrain](https://cesium.com/platform/cesium-ion/content/cesium-world-terrain/). */\n Default = \"1\",\n /** Global 3d terrain that includes [bathymetry](https://cesium.com/platform/cesium-ion/content/cesium-world-bathymetry/) (seafloor) terrain. */\n Bathymetry = \"2426648\",\n}\n\n/** Ids of [Cesium ion assets](https://cesium.com/platform/cesium-ion/content/) providing data not covered by [[CesiumTerrainAssetId]].\n * @beta\n */\nexport enum CesiumIonAssetId {\n /** [Cesium OSM Buildings](https://cesium.com/platform/cesium-ion/content/cesium-osm-buildings/). */\n OSMBuildings = \"96188\",\n}\n"]}
@@ -2,17 +2,96 @@
2
2
  * @module iModels
3
3
  */
4
4
  import { ITwinError } from "@itwin/core-bentley";
5
- /** An error originating from the [[ChannelControl]] interface.
5
+ /**
6
+ * An error originating from the [SQLiteDb]($backend) API.
6
7
  * @beta
7
8
  */
8
- export interface ChannelError extends ITwinError {
9
+ export interface SqliteError extends ITwinError {
10
+ /** The name of the database for this problem. */
11
+ dbName: string;
12
+ }
13
+ /** @beta */
14
+ export declare namespace SqliteError {
15
+ const scope = "itwin-Sqlite";
16
+ type Key = "already-open" | "incompatible-version" | "invalid-versions-property" | "readonly";
17
+ /** Determine whether an error object is a SqliteError */
18
+ function isError(error: unknown, key?: Key): error is SqliteError;
19
+ /** Instantiate and throw a SqliteError */
20
+ function throwError(key: Key, message: string, dbName: string): never;
21
+ }
22
+ /**
23
+ * An error originating from the [CloudSqlite]($backend) API.
24
+ * @beta
25
+ */
26
+ export interface CloudSqliteError extends ITwinError {
27
+ /** The name of the database that generated the error */
28
+ readonly dbName?: string;
29
+ /** The name of the container associated with the error */
30
+ readonly containerId?: string;
31
+ }
32
+ /** @beta */
33
+ export declare namespace CloudSqliteError {
34
+ const scope = "itwin-CloudSqlite";
35
+ type Key = "already-published" | "copy-error" | "invalid-name" | "no-version-available" | "not-a-function" | "service-not-available" |
36
+ /** The write lock cannot be acquired because it is currently held by somebody else.
37
+ * @see WriteLockHeld for details
38
+ */
39
+ "write-lock-held" |
40
+ /** The write lock on a container is not held, but is required for this operation */
41
+ "write-lock-not-held";
42
+ /** thrown when an attempt to acquire the write lock for a container fails because the lock is already held by somebody else ("write-lock-held"). */
43
+ interface WriteLockHeld extends CloudSqliteError {
44
+ /** @internal */
45
+ errorNumber: number;
46
+ /** moniker of user currently holding container's lock */
47
+ lockedBy: string;
48
+ /** time the lock expires */
49
+ expires: string;
50
+ }
51
+ /** Determine whether an error object is a CloudSqliteError */
52
+ function isError<T extends CloudSqliteError>(error: unknown, key?: Key): error is T;
53
+ /** Instantiate and throw a CloudSqliteError */
54
+ function throwError<T extends CloudSqliteError>(key: Key, e: Omit<T, "name" | "iTwinErrorId">): never;
55
+ }
56
+ /** Errors thrown by the [ViewStore]($backend) API.
57
+ * @beta
58
+ */
59
+ export interface ViewStoreError extends ITwinError {
60
+ /** The name of the ViewStore that generated the error */
61
+ viewStoreName?: string;
62
+ }
63
+ /** @beta */
64
+ export declare namespace ViewStoreError {
65
+ const scope = "itwin-ViewStore";
66
+ type Key = "invalid-value" | "invalid-member" | "no-owner" | "not-found" | "not-unique" | "group-error";
67
+ /** Determine whether an error object is a ViewStoreError */
68
+ function isError<T extends ViewStoreError>(error: unknown, key?: Key): error is T;
69
+ /** Instantiate and throw a ViewStoreError */
70
+ function throwError<T extends ViewStoreError>(key: Key, e: Omit<T, "name" | "iTwinErrorId">): never;
71
+ }
72
+ /**
73
+ * Errors thrown by the [Workspace]($backend) APIs.
74
+ * @beta
75
+ */
76
+ export declare namespace WorkspaceError {
77
+ const scope = "itwin-Workspace";
78
+ type Key = "already-exists" | "container-exists" | "does-not-exist" | "invalid-name" | "no-cloud-container" | "load-error" | "load-errors" | "resource-exists" | "too-large" | "write-error";
79
+ /** Determine whether an error object is a WorkspaceError */
80
+ function isError<T extends ITwinError>(error: unknown, key?: Key): error is T;
81
+ function throwError<T extends ITwinError>(key: Key, e: Omit<T, "name" | "iTwinErrorId">): never;
82
+ }
83
+ /** Errors originating from the [ChannelControl]($backend) interface.
84
+ * @beta
85
+ */
86
+ export interface ChannelControlError extends ITwinError {
9
87
  /** The channel key that caused the error. */
10
88
  readonly channelKey: string;
11
89
  }
12
90
  /** @beta */
13
- export declare namespace ChannelError {
14
- const scope = "itwin-channel-errors";
15
- /** The set of keys identifying the different kinds of `ChannelError`s */
91
+ export declare namespace ChannelControlError {
92
+ /** the ITwinError scope for `ChannelControlError`s. */
93
+ const scope = "itwin-ChannelControl";
94
+ /** Keys that identify `ChannelControlError`s */
16
95
  type Key =
17
96
  /** an attempt to create a channel within an existing channel */
18
97
  "may-not-nest" |
@@ -20,9 +99,9 @@ export declare namespace ChannelError {
20
99
  "not-allowed" |
21
100
  /** the root channel already exists */
22
101
  "root-exists";
23
- /** Instantiate and throw a ChannelError */
102
+ /** Instantiate and throw a ChannelControlError */
24
103
  function throwError(key: Key, message: string, channelKey: string): never;
25
- /** Determine whether an error object is a ChannelError */
26
- function isError(error: unknown, key?: Key): error is ChannelError;
104
+ /** Determine whether an error object is a ChannelControlError */
105
+ function isError(error: unknown, key?: Key): error is ChannelControlError;
27
106
  }
28
107
  //# sourceMappingURL=ITwinCoreErrors.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ITwinCoreErrors.d.ts","sourceRoot":"","sources":["../../src/ITwinCoreErrors.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;GAEG;AACH,MAAM,WAAW,YAAa,SAAQ,UAAU;IAC9C,6CAA6C;IAC7C,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;CAC7B;AAED,YAAY;AACZ,yBAAiB,YAAY,CAAC;IAErB,MAAM,KAAK,yBAAyB,CAAC;IAE5C,yEAAyE;IACzE,KAAY,GAAG;IACb,gEAAgE;IAChE,cAAc;IACd,yDAAyD;IACzD,aAAa;IACb,sCAAsC;IACtC,aAAa,CAAC;IAEhB,2CAA2C;IAC3C,SAAgB,UAAU,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,KAAK,CAE/E;IACD,0DAA0D;IAC1D,SAAgB,OAAO,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,CAAC,EAAE,GAAG,GAAG,KAAK,IAAI,YAAY,CAExE;CACF"}
1
+ {"version":3,"file":"ITwinCoreErrors.d.ts","sourceRoot":"","sources":["../../src/ITwinCoreErrors.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEjD;;;GAGG;AACH,MAAM,WAAW,WAAY,SAAQ,UAAU;IAC7C,iDAAiD;IACjD,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,YAAY;AACZ,yBAAiB,WAAW,CAAC;IACpB,MAAM,KAAK,iBAAiB,CAAC;IACpC,KAAY,GAAG,GACb,cAAc,GACd,sBAAsB,GACt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mBAAmB,CAAC;IACnC,uDAAuD;IAChD,MAAM,KAAK,yBAAyB,CAAC;IAE5C,gDAAgD;IAChD,KAAY,GAAG;IACb,gEAAgE;IAChE,cAAc;IACd,yDAAyD;IACzD,aAAa;IACb,sCAAsC;IACtC,aAAa,CAAC;IAEhB,kDAAkD;IAClD,SAAgB,UAAU,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,KAAK,CAE/E;IACD,iEAAiE;IACjE,SAAgB,OAAO,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,CAAC,EAAE,GAAG,GAAG,KAAK,IAAI,mBAAmB,CAE/E;CACF"}
@@ -7,22 +7,84 @@
7
7
  * @module iModels
8
8
  */
9
9
  Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.ChannelError = void 0;
10
+ exports.ChannelControlError = exports.WorkspaceError = exports.ViewStoreError = exports.CloudSqliteError = exports.SqliteError = void 0;
11
11
  const core_bentley_1 = require("@itwin/core-bentley");
12
12
  /** @beta */
13
- var ChannelError;
14
- (function (ChannelError) {
15
- // the scope for all `ChannelError`s.
16
- ChannelError.scope = "itwin-channel-errors";
17
- /** Instantiate and throw a ChannelError */
13
+ var SqliteError;
14
+ (function (SqliteError) {
15
+ SqliteError.scope = "itwin-Sqlite";
16
+ /** Determine whether an error object is a SqliteError */
17
+ function isError(error, key) {
18
+ return core_bentley_1.ITwinError.isError(error, SqliteError.scope, key) && typeof error.dbName === "string";
19
+ }
20
+ SqliteError.isError = isError;
21
+ /** Instantiate and throw a SqliteError */
22
+ function throwError(key, message, dbName) {
23
+ core_bentley_1.ITwinError.throwError({ iTwinErrorId: { scope: SqliteError.scope, key }, message, dbName });
24
+ }
25
+ SqliteError.throwError = throwError;
26
+ })(SqliteError || (exports.SqliteError = SqliteError = {}));
27
+ /** @beta */
28
+ var CloudSqliteError;
29
+ (function (CloudSqliteError) {
30
+ CloudSqliteError.scope = "itwin-CloudSqlite";
31
+ /** Determine whether an error object is a CloudSqliteError */
32
+ function isError(error, key) {
33
+ return core_bentley_1.ITwinError.isError(error, CloudSqliteError.scope, key);
34
+ }
35
+ CloudSqliteError.isError = isError;
36
+ /** Instantiate and throw a CloudSqliteError */
37
+ function throwError(key, e) {
38
+ core_bentley_1.ITwinError.throwError({ ...e, iTwinErrorId: { scope: CloudSqliteError.scope, key } });
39
+ }
40
+ CloudSqliteError.throwError = throwError;
41
+ })(CloudSqliteError || (exports.CloudSqliteError = CloudSqliteError = {}));
42
+ /** @beta */
43
+ var ViewStoreError;
44
+ (function (ViewStoreError) {
45
+ ViewStoreError.scope = "itwin-ViewStore";
46
+ /** Determine whether an error object is a ViewStoreError */
47
+ function isError(error, key) {
48
+ return core_bentley_1.ITwinError.isError(error, ViewStoreError.scope, key);
49
+ }
50
+ ViewStoreError.isError = isError;
51
+ /** Instantiate and throw a ViewStoreError */
52
+ function throwError(key, e) {
53
+ core_bentley_1.ITwinError.throwError({ ...e, iTwinErrorId: { scope: ViewStoreError.scope, key } });
54
+ }
55
+ ViewStoreError.throwError = throwError;
56
+ })(ViewStoreError || (exports.ViewStoreError = ViewStoreError = {}));
57
+ /**
58
+ * Errors thrown by the [Workspace]($backend) APIs.
59
+ * @beta
60
+ */
61
+ var WorkspaceError;
62
+ (function (WorkspaceError) {
63
+ WorkspaceError.scope = "itwin-Workspace";
64
+ /** Determine whether an error object is a WorkspaceError */
65
+ function isError(error, key) {
66
+ return core_bentley_1.ITwinError.isError(error, WorkspaceError.scope, key);
67
+ }
68
+ WorkspaceError.isError = isError;
69
+ function throwError(key, e) {
70
+ core_bentley_1.ITwinError.throwError({ ...e, iTwinErrorId: { key, scope: WorkspaceError.scope } });
71
+ }
72
+ WorkspaceError.throwError = throwError;
73
+ })(WorkspaceError || (exports.WorkspaceError = WorkspaceError = {}));
74
+ /** @beta */
75
+ var ChannelControlError;
76
+ (function (ChannelControlError) {
77
+ /** the ITwinError scope for `ChannelControlError`s. */
78
+ ChannelControlError.scope = "itwin-ChannelControl";
79
+ /** Instantiate and throw a ChannelControlError */
18
80
  function throwError(key, message, channelKey) {
19
- core_bentley_1.ITwinError.throwError({ iTwinErrorId: { scope: ChannelError.scope, key }, message, channelKey });
81
+ core_bentley_1.ITwinError.throwError({ iTwinErrorId: { scope: ChannelControlError.scope, key }, message, channelKey });
20
82
  }
21
- ChannelError.throwError = throwError;
22
- /** Determine whether an error object is a ChannelError */
83
+ ChannelControlError.throwError = throwError;
84
+ /** Determine whether an error object is a ChannelControlError */
23
85
  function isError(error, key) {
24
- return core_bentley_1.ITwinError.isError(error, ChannelError.scope, key) && typeof error.channelKey === "string";
86
+ return core_bentley_1.ITwinError.isError(error, ChannelControlError.scope, key) && typeof error.channelKey === "string";
25
87
  }
26
- ChannelError.isError = isError;
27
- })(ChannelError || (exports.ChannelError = ChannelError = {}));
88
+ ChannelControlError.isError = isError;
89
+ })(ChannelControlError || (exports.ChannelControlError = ChannelControlError = {}));
28
90
  //# sourceMappingURL=ITwinCoreErrors.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ITwinCoreErrors.js","sourceRoot":"","sources":["../../src/ITwinCoreErrors.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAiD;AAUjD,YAAY;AACZ,IAAiB,YAAY,CAqB5B;AArBD,WAAiB,YAAY;IAC3B,qCAAqC;IACxB,kBAAK,GAAG,sBAAsB,CAAC;IAW5C,2CAA2C;IAC3C,SAAgB,UAAU,CAAC,GAAQ,EAAE,OAAe,EAAE,UAAkB;QACtE,yBAAU,CAAC,UAAU,CAAe,EAAE,YAAY,EAAE,EAAE,KAAK,EAAL,aAAA,KAAK,EAAE,GAAG,EAAE,EAAE,OAAO,EAAE,UAAU,EAAE,CAAC,CAAC;IAC7F,CAAC;IAFe,uBAAU,aAEzB,CAAA;IACD,0DAA0D;IAC1D,SAAgB,OAAO,CAAC,KAAc,EAAE,GAAS;QAC/C,OAAO,yBAAU,CAAC,OAAO,CAAe,KAAK,EAAE,aAAA,KAAK,EAAE,GAAG,CAAC,IAAI,OAAO,KAAK,CAAC,UAAU,KAAK,QAAQ,CAAC;IACrG,CAAC;IAFe,oBAAO,UAEtB,CAAA;AACH,CAAC,EArBgB,YAAY,4BAAZ,YAAY,QAqB5B","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 iModels\n */\n\nimport { ITwinError } from \"@itwin/core-bentley\";\n\n/** An error originating from the [[ChannelControl]] interface.\n * @beta\n */\nexport interface ChannelError extends ITwinError {\n /** The channel key that caused the error. */\n readonly channelKey: string;\n}\n\n/** @beta */\nexport namespace ChannelError {\n // the scope for all `ChannelError`s.\n export const scope = \"itwin-channel-errors\";\n\n /** The set of keys identifying the different kinds of `ChannelError`s */\n export type Key =\n /** an attempt to create a channel within an existing channel */\n \"may-not-nest\" |\n /** an attempt to use a channel that was not \"allowed\" */\n \"not-allowed\" |\n /** the root channel already exists */\n \"root-exists\";\n\n /** Instantiate and throw a ChannelError */\n export function throwError(key: Key, message: string, channelKey: string): never {\n ITwinError.throwError<ChannelError>({ iTwinErrorId: { scope, key }, message, channelKey });\n }\n /** Determine whether an error object is a ChannelError */\n export function isError(error: unknown, key?: Key): error is ChannelError {\n return ITwinError.isError<ChannelError>(error, scope, key) && typeof error.channelKey === \"string\";\n }\n}\n"]}
1
+ {"version":3,"file":"ITwinCoreErrors.js","sourceRoot":"","sources":["../../src/ITwinCoreErrors.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAEH,sDAAiD;AAWjD,YAAY;AACZ,IAAiB,WAAW,CAiB3B;AAjBD,WAAiB,WAAW;IACb,iBAAK,GAAG,cAAc,CAAC;IAOpC,yDAAyD;IACzD,SAAgB,OAAO,CAAC,KAAc,EAAE,GAAS;QAC/C,OAAO,yBAAU,CAA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,8BAAU,aAEzB,CAAA;IACD,iEAAiE;IACjE,SAAgB,OAAO,CAAC,KAAc,EAAE,GAAS;QAC/C,OAAO,yBAAU,CAAC,OAAO,CAAsB,KAAK,EAAE,oBAAA,KAAK,EAAE,GAAG,CAAC,IAAI,OAAO,KAAK,CAAC,UAAU,KAAK,QAAQ,CAAC;IAC5G,CAAC;IAFe,2BAAO,UAEtB,CAAA;AACH,CAAC,EArBgB,mBAAmB,mCAAnB,mBAAmB,QAqBnC","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 iModels\n */\n\nimport { ITwinError } from \"@itwin/core-bentley\";\n\n/**\n * An error originating from the [SQLiteDb]($backend) API.\n * @beta\n */\nexport interface SqliteError extends ITwinError {\n /** The name of the database for this problem. */\n dbName: string;\n}\n\n/** @beta */\nexport namespace SqliteError {\n export const scope = \"itwin-Sqlite\";\n export type Key =\n \"already-open\" |\n \"incompatible-version\" |\n \"invalid-versions-property\" |\n \"readonly\";\n\n /** Determine whether an error object is a SqliteError */\n export function isError(error: unknown, key?: Key): error is SqliteError {\n return ITwinError.isError<SqliteError>(error, scope, key) && typeof error.dbName === \"string\";\n }\n\n /** Instantiate and throw a SqliteError */\n export function throwError(key: Key, message: string, dbName: string): never {\n ITwinError.throwError<SqliteError>({ iTwinErrorId: { scope, key }, message, dbName });\n }\n}\n\n/**\n * An error originating from the [CloudSqlite]($backend) API.\n * @beta\n */\nexport interface CloudSqliteError extends ITwinError {\n /** The name of the database that generated the error */\n readonly dbName?: string;\n /** The name of the container associated with the error */\n readonly containerId?: string;\n}\n\n/** @beta */\nexport namespace CloudSqliteError {\n export const scope = \"itwin-CloudSqlite\";\n export type Key =\n \"already-published\" |\n \"copy-error\" |\n \"invalid-name\" |\n \"no-version-available\" |\n \"not-a-function\" |\n \"service-not-available\" |\n /** The write lock cannot be acquired because it is currently held by somebody else.\n * @see WriteLockHeld for details\n */\n \"write-lock-held\" |\n /** The write lock on a container is not held, but is required for this operation */\n \"write-lock-not-held\";\n\n /** thrown when an attempt to acquire the write lock for a container fails because the lock is already held by somebody else (\"write-lock-held\"). */\n export interface WriteLockHeld extends CloudSqliteError {\n /** @internal */\n errorNumber: number;\n /** moniker of user currently holding container's lock */\n lockedBy: string;\n /** time the lock expires */\n expires: string;\n }\n\n /** Determine whether an error object is a CloudSqliteError */\n export function isError<T extends CloudSqliteError>(error: unknown, key?: Key): error is T {\n return ITwinError.isError<T>(error, scope, key);\n }\n\n /** Instantiate and throw a CloudSqliteError */\n export function throwError<T extends CloudSqliteError>(key: Key, e: Omit<T, \"name\" | \"iTwinErrorId\">): never {\n ITwinError.throwError<CloudSqliteError>({ ...e, iTwinErrorId: { scope, key } });\n }\n}\n\n/** Errors thrown by the [ViewStore]($backend) API.\n * @beta\n */\nexport interface ViewStoreError extends ITwinError {\n /** The name of the ViewStore that generated the error */\n viewStoreName?: string;\n}\n\n/** @beta */\nexport namespace ViewStoreError {\n export const scope = \"itwin-ViewStore\";\n export type Key =\n \"invalid-value\" |\n \"invalid-member\" |\n \"no-owner\" |\n \"not-found\" |\n \"not-unique\" |\n \"group-error\";\n\n /** Determine whether an error object is a ViewStoreError */\n export function isError<T extends ViewStoreError>(error: unknown, key?: Key): error is T {\n return ITwinError.isError<T>(error, scope, key);\n }\n\n /** Instantiate and throw a ViewStoreError */\n export function throwError<T extends ViewStoreError>(key: Key, e: Omit<T, \"name\" | \"iTwinErrorId\">): never {\n ITwinError.throwError<ViewStoreError>({ ...e, iTwinErrorId: { scope, key } });\n }\n}\n\n/**\n * Errors thrown by the [Workspace]($backend) APIs.\n * @beta\n */\nexport namespace WorkspaceError {\n export const scope = \"itwin-Workspace\";\n export type Key =\n \"already-exists\" |\n \"container-exists\" |\n \"does-not-exist\" |\n \"invalid-name\" |\n \"no-cloud-container\" |\n \"load-error\" |\n \"load-errors\" |\n \"resource-exists\" |\n \"too-large\" |\n \"write-error\";\n\n /** Determine whether an error object is a WorkspaceError */\n export function isError<T extends ITwinError>(error: unknown, key?: Key): error is T {\n return ITwinError.isError<T>(error, scope, key);\n }\n\n export function throwError<T extends ITwinError>(key: Key, e: Omit<T, \"name\" | \"iTwinErrorId\">): never {\n ITwinError.throwError<ITwinError>({ ...e, iTwinErrorId: { key, scope } });\n }\n}\n\n\n/** Errors originating from the [ChannelControl]($backend) interface.\n * @beta\n */\nexport interface ChannelControlError extends ITwinError {\n /** The channel key that caused the error. */\n readonly channelKey: string;\n}\n\n/** @beta */\nexport namespace ChannelControlError {\n /** the ITwinError scope for `ChannelControlError`s. */\n export const scope = \"itwin-ChannelControl\";\n\n /** Keys that identify `ChannelControlError`s */\n export type Key =\n /** an attempt to create a channel within an existing channel */\n \"may-not-nest\" |\n /** an attempt to use a channel that was not \"allowed\" */\n \"not-allowed\" |\n /** the root channel already exists */\n \"root-exists\";\n\n /** Instantiate and throw a ChannelControlError */\n export function throwError(key: Key, message: string, channelKey: string): never {\n ITwinError.throwError<ChannelControlError>({ iTwinErrorId: { scope, key }, message, channelKey });\n }\n /** Determine whether an error object is a ChannelControlError */\n export function isError(error: unknown, key?: Key): error is ChannelControlError {\n return ITwinError.isError<ChannelControlError>(error, scope, key) && typeof error.channelKey === \"string\";\n }\n}\n"]}
@@ -2,18 +2,6 @@
2
2
  * @module DisplayStyles
3
3
  */
4
4
  import { BackgroundMapProps } from "./BackgroundMapSettings";
5
- /** Ids of [Cesium ION assets](https://cesium.com/platform/cesium-ion/content/) providing global terrain data.
6
- * These values are appropriate to use with [[TerrainSettings.dataSource]] when [[TerrainSettings.providerName]] is set to "CesiumWorldTerrain".
7
- * You may alternatively use the Id of any ION asset to which you have access.
8
- * @see [[TerrainSettings.fromCesiumIonAsset]] to create TerrainSettings that obtain terrain from a specified ION asset.
9
- * @public
10
- */
11
- export declare enum CesiumTerrainAssetId {
12
- /** Default [global 3d terrain](https://cesium.com/platform/cesium-ion/content/cesium-world-terrain/). */
13
- Default = "1",
14
- /** Global 3d terrain that includes [bathymetry](https://cesium.com/platform/cesium-ion/content/cesium-world-bathymetry/) (seafloor) terrain. */
15
- Bathymetry = "2426648"
16
- }
17
5
  /** JSON representation of the settings of the terrain applied to background map display by a [[DisplayStyle]].
18
6
  * @see [[DisplayStyleSettingsProps]]
19
7
  * @see [[BackgroundMapProps]]
@@ -1 +1 @@
1
- {"version":3,"file":"TerrainSettings.d.ts","sourceRoot":"","sources":["../../src/TerrainSettings.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAE7D;;;;;GAKG;AACH,oBAAY,oBAAoB;IAC9B,yGAAyG;IACzG,OAAO,MAAM;IACb,gJAAgJ;IAChJ,UAAU,YAAY;CACvB;AAED;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;OAIG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,8IAA8I;IAC9I,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,8FAA8F;IAC9F,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,0HAA0H;IAC1H,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mGAAmG;IACnG,gBAAgB,CAAC,EAAE,uBAAuB,CAAC;IAC3C;;OAEG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED;;;;GAIG;AACH,oBAAY,uBAAuB;IACjC,sHAAsH;IACtH,QAAQ,IAAI;IACZ,0GAA0G;IAC1G,KAAK,IAAI;IACT,yGAAyG;IACzG,MAAM,IAAI;CACX;AAED;;GAEG;AACH,qBAAa,eAAe;IAC1B,OAAO,CAAC,aAAa,CAAmB;IACxC;;OAEG;IACH,SAAgB,YAAY,EAAE,MAAM,CAAC;IACrC;;;;OAIG;IACH,SAAgB,UAAU,EAAE,MAAM,CAAC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AAE,eAAe,GAAG,OAAO;IAK9C,mFAAmF;IAC5E,UAAU,CAAC,IAAI,CAAC,EAAE,kBAAkB,GAAG,OAAO;IAIrD;;;OAGG;IACI,KAAK,CAAC,YAAY,CAAC,EAAE,YAAY,GAAG,eAAe;CAgB3D"}
@@ -7,20 +7,8 @@
7
7
  * @module DisplayStyles
8
8
  */
9
9
  Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.TerrainSettings = exports.TerrainHeightOriginMode = exports.CesiumTerrainAssetId = void 0;
11
- /** Ids of [Cesium ION assets](https://cesium.com/platform/cesium-ion/content/) providing global terrain data.
12
- * These values are appropriate to use with [[TerrainSettings.dataSource]] when [[TerrainSettings.providerName]] is set to "CesiumWorldTerrain".
13
- * You may alternatively use the Id of any ION asset to which you have access.
14
- * @see [[TerrainSettings.fromCesiumIonAsset]] to create TerrainSettings that obtain terrain from a specified ION asset.
15
- * @public
16
- */
17
- var CesiumTerrainAssetId;
18
- (function (CesiumTerrainAssetId) {
19
- /** Default [global 3d terrain](https://cesium.com/platform/cesium-ion/content/cesium-world-terrain/). */
20
- CesiumTerrainAssetId["Default"] = "1";
21
- /** Global 3d terrain that includes [bathymetry](https://cesium.com/platform/cesium-ion/content/cesium-world-bathymetry/) (seafloor) terrain. */
22
- CesiumTerrainAssetId["Bathymetry"] = "2426648";
23
- })(CesiumTerrainAssetId || (exports.CesiumTerrainAssetId = CesiumTerrainAssetId = {}));
10
+ exports.TerrainSettings = exports.TerrainHeightOriginMode = void 0;
11
+ const CesiumIonAssets_1 = require("./CesiumIonAssets");
24
12
  /** Correction modes for terrain height
25
13
  * @see [[TerrainProps]]
26
14
  * @public
@@ -100,7 +88,7 @@ class TerrainSettings {
100
88
  * one of those defined by [[CesiumTerrainAssetId]].
101
89
  * @note You must ensure your Cesium ION account has access to the specified asset.
102
90
  */
103
- static fromCesiumIonAsset(assetId = CesiumTerrainAssetId.Default, options) {
91
+ static fromCesiumIonAsset(assetId = CesiumIonAssets_1.CesiumTerrainAssetId.Default, options) {
104
92
  return TerrainSettings.fromJSON({
105
93
  ...options,
106
94
  dataSource: assetId,