@itwin/core-common 5.0.0-dev.65 → 5.0.0-dev.67
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -1
- package/lib/cjs/ChangesetProps.d.ts +1 -1
- package/lib/cjs/ChangesetProps.js.map +1 -1
- package/lib/cjs/Image.d.ts +15 -0
- package/lib/cjs/Image.d.ts.map +1 -1
- package/lib/cjs/Image.js +7 -0
- package/lib/cjs/Image.js.map +1 -1
- package/lib/cjs/MassProperties.d.ts +2 -0
- package/lib/cjs/MassProperties.d.ts.map +1 -1
- package/lib/cjs/MassProperties.js.map +1 -1
- package/lib/cjs/rpc/IModelReadRpcInterface.js +1 -1
- package/lib/cjs/rpc/IModelReadRpcInterface.js.map +1 -1
- package/lib/esm/ChangesetProps.d.ts +1 -1
- package/lib/esm/ChangesetProps.js.map +1 -1
- package/lib/esm/Image.d.ts +15 -0
- package/lib/esm/Image.d.ts.map +1 -1
- package/lib/esm/Image.js +6 -0
- package/lib/esm/Image.js.map +1 -1
- package/lib/esm/MassProperties.d.ts +2 -0
- package/lib/esm/MassProperties.d.ts.map +1 -1
- package/lib/esm/MassProperties.js.map +1 -1
- package/lib/esm/rpc/IModelReadRpcInterface.js +1 -1
- package/lib/esm/rpc/IModelReadRpcInterface.js.map +1 -1
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
# Change Log - @itwin/core-common
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Tue, 18 Feb 2025 17:30:07 GMT and should not be manually modified.
|
|
4
|
+
|
|
5
|
+
## 4.10.7
|
|
6
|
+
Tue, 18 Feb 2025 17:27:03 GMT
|
|
7
|
+
|
|
8
|
+
### Updates
|
|
9
|
+
|
|
10
|
+
- Update ECSql reader api to support no stat and error code.
|
|
4
11
|
|
|
5
12
|
## 4.10.6
|
|
6
13
|
Fri, 24 Jan 2025 08:02:40 GMT
|
|
@@ -81,7 +81,7 @@ export interface ChangesetProps {
|
|
|
81
81
|
size: number;
|
|
82
82
|
}
|
|
83
83
|
/** Properties of a changeset file
|
|
84
|
-
* @
|
|
84
|
+
* @public
|
|
85
85
|
*/
|
|
86
86
|
export interface ChangesetFileProps extends ChangesetProps {
|
|
87
87
|
/** The full pathname of the local file holding this changeset. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChangesetProps.js","sourceRoot":"","sources":["../../src/ChangesetProps.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;;GAGG;;;AAuCH;;;GAGG;AACH,IAAY,aAOX;AAPD,WAAY,aAAa;IACvB,mDAAmD;IACnD,uDAAW,CAAA;IACX,+CAA+C;IAC/C,qDAAU,CAAA;IACV,gEAAgE;IAChE,8DAAwB,CAAA;AAC1B,CAAC,EAPW,aAAa,6BAAb,aAAa,QAOxB","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/**\n * @packageDocumentation\n * @module iModels\n */\n\n/** @public */\nexport type LocalFileName = string;\n/** @public */\nexport type LocalDirName = string;\n\n/** A string that identifies a changeset.\n * @note this string is *not* a Guid. It is generated internally based on the content of the changeset.\n * @public\n * @extensions\n */\nexport type ChangesetId = string;\n\n/** The index of a changeset, assigned by iModelHub.\n * @note 0 means \"before the first changeset.\" Values less than 0 are invalid.\n * @public\n * @extensions\n */\nexport type ChangesetIndex = number;\n\n/** Both the index and Id of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIndexAndId { readonly index: ChangesetIndex, readonly id: ChangesetId }\n\n/** The Id and optionally the index of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIdWithIndex { readonly index?: ChangesetIndex, readonly id: ChangesetId }\n\n/** either changeset index, id, or both\n* @public\n * @extensions\n*/\nexport type ChangesetIndexOrId = ChangesetIndexAndId | { readonly index: ChangesetIndex, readonly id?: never } | { readonly id: ChangesetId, readonly index?: never };\n\n/** Value to indicate whether a changeset contains schema changes or not\n * @public\n * @extensions\n */\nexport enum ChangesetType {\n /** changeset does *not* contain schema changes. */\n Regular = 0,\n /** changeset *does* contain schema changes. */\n Schema = 1,\n /** Schema changeset pushed by iModel with SchemaSync enabled */\n SchemaSync = Schema | 64,\n}\n\n/** Properties of a changeset\n * @public\n */\nexport interface ChangesetProps {\n /** The index (sequence number) from IModelHub for this changeset. Larger index values were pushed later. */\n index: ChangesetIndex;\n /** the ChangesetId */\n id: ChangesetId;\n /** the ChangeSetId of the parent changeset of this changeset */\n parentId: ChangesetId;\n /** The type of changeset */\n changesType: ChangesetType;\n /** The user-supplied description of the work this changeset holds */\n description: string;\n /** The BriefcaseId of the briefcase that created this changeset */\n briefcaseId: number;\n /** The date this changeset was uploaded to the hub */\n pushDate: string;\n /** The identity of the user that created this changeset */\n userCreated: string;\n /** The size, in bytes, of this changeset */\n size: number;\n}\n\n/** Properties of a changeset file\n * @
|
|
1
|
+
{"version":3,"file":"ChangesetProps.js","sourceRoot":"","sources":["../../src/ChangesetProps.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;;GAGG;;;AAuCH;;;GAGG;AACH,IAAY,aAOX;AAPD,WAAY,aAAa;IACvB,mDAAmD;IACnD,uDAAW,CAAA;IACX,+CAA+C;IAC/C,qDAAU,CAAA;IACV,gEAAgE;IAChE,8DAAwB,CAAA;AAC1B,CAAC,EAPW,aAAa,6BAAb,aAAa,QAOxB","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/**\n * @packageDocumentation\n * @module iModels\n */\n\n/** @public */\nexport type LocalFileName = string;\n/** @public */\nexport type LocalDirName = string;\n\n/** A string that identifies a changeset.\n * @note this string is *not* a Guid. It is generated internally based on the content of the changeset.\n * @public\n * @extensions\n */\nexport type ChangesetId = string;\n\n/** The index of a changeset, assigned by iModelHub.\n * @note 0 means \"before the first changeset.\" Values less than 0 are invalid.\n * @public\n * @extensions\n */\nexport type ChangesetIndex = number;\n\n/** Both the index and Id of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIndexAndId { readonly index: ChangesetIndex, readonly id: ChangesetId }\n\n/** The Id and optionally the index of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIdWithIndex { readonly index?: ChangesetIndex, readonly id: ChangesetId }\n\n/** either changeset index, id, or both\n* @public\n * @extensions\n*/\nexport type ChangesetIndexOrId = ChangesetIndexAndId | { readonly index: ChangesetIndex, readonly id?: never } | { readonly id: ChangesetId, readonly index?: never };\n\n/** Value to indicate whether a changeset contains schema changes or not\n * @public\n * @extensions\n */\nexport enum ChangesetType {\n /** changeset does *not* contain schema changes. */\n Regular = 0,\n /** changeset *does* contain schema changes. */\n Schema = 1,\n /** Schema changeset pushed by iModel with SchemaSync enabled */\n SchemaSync = Schema | 64,\n}\n\n/** Properties of a changeset\n * @public\n */\nexport interface ChangesetProps {\n /** The index (sequence number) from IModelHub for this changeset. Larger index values were pushed later. */\n index: ChangesetIndex;\n /** the ChangesetId */\n id: ChangesetId;\n /** the ChangeSetId of the parent changeset of this changeset */\n parentId: ChangesetId;\n /** The type of changeset */\n changesType: ChangesetType;\n /** The user-supplied description of the work this changeset holds */\n description: string;\n /** The BriefcaseId of the briefcase that created this changeset */\n briefcaseId: number;\n /** The date this changeset was uploaded to the hub */\n pushDate: string;\n /** The identity of the user that created this changeset */\n userCreated: string;\n /** The size, in bytes, of this changeset */\n size: number;\n}\n\n/** Properties of a changeset file\n * @public\n */\nexport interface ChangesetFileProps extends ChangesetProps {\n /** The full pathname of the local file holding this changeset. */\n pathname: LocalFileName;\n}\n\n/**\n * A range of changesets\n * @public\n * @extensions\n */\nexport interface ChangesetRange {\n /** index of the first changeset */\n first: ChangesetIndex;\n /** index of last changeset. If undefined, all changesets after first are returned. */\n end?: ChangesetIndex;\n}\n"]}
|
package/lib/cjs/Image.d.ts
CHANGED
|
@@ -83,4 +83,19 @@ export declare class ImageSource {
|
|
|
83
83
|
/** Construct a new ImageSource, which takes ownership of the Uint8Array. */
|
|
84
84
|
constructor(data: Uint8Array | string, format: ImageSourceFormat);
|
|
85
85
|
}
|
|
86
|
+
/** An [[ImageSource]] encoded in binary form as a Jpeg or Png, as opposed to one encoded
|
|
87
|
+
* in string format as an Svg.
|
|
88
|
+
* Only binary ImageSources can be used for [[Texture]]s stored in [[IModelDb]]s.
|
|
89
|
+
* @public
|
|
90
|
+
*/
|
|
91
|
+
export interface BinaryImageSource {
|
|
92
|
+
/** The format in which the [[data]] is encoded. */
|
|
93
|
+
readonly format: ImageSourceFormat.Jpeg | ImageSourceFormat.Png;
|
|
94
|
+
/** The image data encoded according to [[format]]. */
|
|
95
|
+
readonly data: Uint8Array;
|
|
96
|
+
}
|
|
97
|
+
/** Returns true if `source` is a [[BinaryImageSource]].
|
|
98
|
+
* @public
|
|
99
|
+
*/
|
|
100
|
+
export declare function isBinaryImageSource(source: ImageSource): source is BinaryImageSource;
|
|
86
101
|
//# sourceMappingURL=Image.d.ts.map
|
package/lib/cjs/Image.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH;;;;;GAKG;AACH,oBAAY,iBAAiB;IAC3B,uCAAuC;IACvC,IAAI,IAAI;IACR,sCAAsC;IACtC,GAAG,IAAI;IACP,wBAAwB;IACxB,KAAK,IAAI;CACV;AAED;;GAEG;AACH,qBAAa,WAAW;IACtB,sGAAsG;IACtG,SAAgB,IAAI,EAAE,UAAU,CAAC;IACjC,wCAAwC;IACxC,SAAgB,MAAM,EAAE,iBAAiB,CAAC;IAC1C,+BAA+B;IAC/B,SAAgB,KAAK,EAAE,MAAM,CAAC;IAE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iB;IAChC,mDAAmD;IACnD,QAAQ,CAAC,MAAM,EAAE,iBAAiB,CAAC,IAAI,GAAG,iBAAiB,CAAC,GAAG,CAAC;IAChE,sDAAsD;IACtD,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;CAC3B;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,IAAI,iBAAiB,CAEpF"}
|
package/lib/cjs/Image.js
CHANGED
|
@@ -11,6 +11,7 @@ exports.ImageSource = exports.ImageSourceFormat = exports.ImageBuffer = exports.
|
|
|
11
11
|
exports.isPowerOfTwo = isPowerOfTwo;
|
|
12
12
|
exports.nextHighestPowerOfTwo = nextHighestPowerOfTwo;
|
|
13
13
|
exports.isValidImageSourceFormat = isValidImageSourceFormat;
|
|
14
|
+
exports.isBinaryImageSource = isBinaryImageSource;
|
|
14
15
|
/** Format of an [[ImageBuffer]].
|
|
15
16
|
* The format determines how many bytes are allocated for each pixel in the buffer and the semantics of each byte.
|
|
16
17
|
* @see [[ImageBuffer.getNumBytesPerPixel]]
|
|
@@ -135,4 +136,10 @@ class ImageSource {
|
|
|
135
136
|
}
|
|
136
137
|
}
|
|
137
138
|
exports.ImageSource = ImageSource;
|
|
139
|
+
/** Returns true if `source` is a [[BinaryImageSource]].
|
|
140
|
+
* @public
|
|
141
|
+
*/
|
|
142
|
+
function isBinaryImageSource(source) {
|
|
143
|
+
return source.format !== ImageSourceFormat.Svg && source.data instanceof Uint8Array;
|
|
144
|
+
}
|
|
138
145
|
//# sourceMappingURL=Image.js.map
|
package/lib/cjs/Image.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Image.js","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AA8EH,oCAEC;AAMD,sDAMC;AAoBD,4DASC;
|
|
1
|
+
{"version":3,"file":"Image.js","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"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DAAQ,CAAA;IACR,iDAAiD;IACjD,uDAAO,CAAA;IACP;;OAEG;IACH,uDAAO,CAAA;AACT,CAAC,EATW,iBAAiB,iCAAjB,iBAAiB,QAS5B;AAED;;GAEG;AACH,SAAgB,wBAAwB,CAAC,MAAc;IACrD,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,iBAAiB,CAAC,IAAI,CAAC;QAC5B,KAAK,iBAAiB,CAAC,GAAG,CAAC;QAC3B,KAAK,iBAAiB,CAAC,GAAG;YACxB,OAAO,IAAI,CAAC;QACd;YACE,OAAO,KAAK,CAAC;IACjB,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAa,WAAW;IACtB,2CAA2C;IAC3B,IAAI,CAAsB;IAC1C,4BAA4B;IACZ,MAAM,CAAoB;IAE1C,4EAA4E;IAC5E,YAAmB,IAAyB,EAAE,MAAyB;QACrE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;CACF;AAXD,kCAWC;AAcD;;GAEG;AACH,SAAgB,mBAAmB,CAAC,MAAmB;IACrD,OAAO,MAAM,CAAC,MAAM,KAAK,iBAAiB,CAAC,GAAG,IAAI,MAAM,CAAC,IAAI,YAAY,UAAU,CAAC;AACtF,CAAC","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 Rendering\n */\n\n/** Format of an [[ImageBuffer]].\n * The format determines how many bytes are allocated for each pixel in the buffer and the semantics of each byte.\n * @see [[ImageBuffer.getNumBytesPerPixel]]\n * @public\n * @extensions\n */\nexport enum ImageBufferFormat {\n /** RGBA format - 4 bytes per pixel. */\n Rgba = 0,\n /** RGB format - 3 bytes per pixel. */\n Rgb = 2,\n /** 1 byte per pixel. */\n Alpha = 5,\n}\n\n/** Uncompressed rectangular bitmap image data.\n * @public\n */\nexport class ImageBuffer {\n /** Image data in which each pixel occupies 1 or more bytes depending of the [[ImageBufferFormat]]. */\n public readonly data: Uint8Array;\n /** Format of the bytes in the image. */\n public readonly format: ImageBufferFormat;\n /** Width of image in pixels */\n public readonly width: number;\n\n /** Return the number of bytes allocated for each pixel. */\n public get numBytesPerPixel(): number { return ImageBuffer.getNumBytesPerPixel(this.format); }\n\n /** Determine the number of bytes allocated to a single pixel for the specified format. */\n public static getNumBytesPerPixel(format: ImageBufferFormat): number {\n switch (format) {\n case ImageBufferFormat.Alpha: return 1;\n case ImageBufferFormat.Rgb: return 3;\n default: return 4;\n }\n }\n\n /** Get the height of this image in pixels. */\n public get height(): number { return ImageBuffer.computeHeight(this.data, this.format, this.width); }\n\n /** Create a new ImageBuffer.\n * @note The ImageBuffer takes ownership of the input Uint8Array.\n * @param data The uncompressed image bytes. Must be a multiple of the width times the number of bytes per pixel specified by the format.\n * @param format The format of the image.\n * @param width The width of the image in pixels.\n * @returns A new ImageBuffer.\n * @throws Error if the length of the Uint8Array is not appropriate for the specified width and format.\n */\n public static create(data: Uint8Array, format: ImageBufferFormat, width: number): ImageBuffer {\n if (!this.isValidData(data, format, width))\n throw new Error(\"The number of bytes supplied for ImageBuffer do not match its width and format.\");\n\n return new ImageBuffer(data, format, width);\n }\n\n private static isValidData(data: Uint8Array, format: ImageBufferFormat, width: number): boolean {\n const height = this.computeHeight(data, format, width);\n return width > 0 && height > 0 && Math.floor(width) === width && Math.floor(height) === height;\n }\n\n private static computeHeight(data: Uint8Array, format: ImageBufferFormat, width: number): number {\n return data.length / (width * this.getNumBytesPerPixel(format));\n }\n\n private constructor(data: Uint8Array, format: ImageBufferFormat, width: number) {\n this.data = data;\n this.format = format;\n this.width = width;\n }\n}\n\n/** Returns whether the input is a power of two.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function isPowerOfTwo(num: number): boolean {\n return 0 === (num & (num - 1));\n}\n\n/** Returns the first power-of-two value greater than or equal to the input.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function nextHighestPowerOfTwo(num: number): number {\n --num;\n for (let i = 1; i < 32; i <<= 1)\n num = num | num >> i;\n\n return num + 1;\n}\n\n/** The format of an ImageSource.\n * @public\n * @extensions\n */\nexport enum ImageSourceFormat {\n /** Image data is stored with JPEG compression. */\n Jpeg = 0,\n /** Image data is stored with PNG compression. */\n Png = 2,\n /** Image is stored as an Svg stream.\n * @note SVG is only valid for ImageSources in JavaScript. It *may not* be used for persistent textures.\n */\n Svg = 3,\n}\n\n/** Returns true if the numeric `format` value is a valid member of the [[ImageSourceFormat]] enumeration.\n * @public\n */\nexport function isValidImageSourceFormat(format: number): format is ImageSourceFormat {\n switch (format) {\n case ImageSourceFormat.Jpeg:\n case ImageSourceFormat.Png:\n case ImageSourceFormat.Svg:\n return true;\n default:\n return false;\n }\n}\n\n/** Image data encoded and compressed in either Jpeg or Png format.\n * @public\n */\nexport class ImageSource {\n /** The content of the image, compressed */\n public readonly data: Uint8Array | string;\n /** The compression type. */\n public readonly format: ImageSourceFormat;\n\n /** Construct a new ImageSource, which takes ownership of the Uint8Array. */\n public constructor(data: Uint8Array | string, format: ImageSourceFormat) {\n this.data = data;\n this.format = format;\n }\n}\n\n/** An [[ImageSource]] encoded in binary form as a Jpeg or Png, as opposed to one encoded\n * in string format as an Svg.\n * Only binary ImageSources can be used for [[Texture]]s stored in [[IModelDb]]s.\n * @public\n */\nexport interface BinaryImageSource {\n /** The format in which the [[data]] is encoded. */\n readonly format: ImageSourceFormat.Jpeg | ImageSourceFormat.Png;\n /** The image data encoded according to [[format]]. */\n readonly data: Uint8Array;\n}\n\n/** Returns true if `source` is a [[BinaryImageSource]].\n * @public\n */\nexport function isBinaryImageSource(source: ImageSource): source is BinaryImageSource {\n return source.format !== ImageSourceFormat.Svg && source.data instanceof Uint8Array;\n}\n"]}
|
|
@@ -25,6 +25,7 @@ export interface MassPropertiesRequestProps {
|
|
|
25
25
|
}
|
|
26
26
|
/** Information required to request mass properties for each element separately from the front end to the back end.
|
|
27
27
|
* @public
|
|
28
|
+
* @deprecated in 4.11. Use [[MassPropertiesRequestProps]].
|
|
28
29
|
*/
|
|
29
30
|
export interface MassPropertiesPerCandidateRequestProps {
|
|
30
31
|
operations: MassPropertiesOperation[];
|
|
@@ -58,6 +59,7 @@ export interface MassPropertiesResponseProps {
|
|
|
58
59
|
}
|
|
59
60
|
/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.
|
|
60
61
|
* @public
|
|
62
|
+
* @deprecated in 4.11. Use [[MassPropertiesResponseProps]].
|
|
61
63
|
*/
|
|
62
64
|
export interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {
|
|
63
65
|
candidate: Id64String;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MassProperties.d.ts","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC9F,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD;;;GAGG;AACH,oBAAY,uBAAuB;IACjC,wDAAwD;IACxD,iBAAiB,IAAI;IACrB,kEAAkE;IAClE,eAAe,IAAI;IACnB,mDAAmD;IACnD,iBAAiB,IAAI;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,0BAA0B;IACzC,SAAS,EAAE,uBAAuB,CAAC;IACnC,UAAU,CAAC,EAAE,SAAS,CAAC;CACxB;AAED
|
|
1
|
+
{"version":3,"file":"MassProperties.d.ts","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC9F,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD;;;GAGG;AACH,oBAAY,uBAAuB;IACjC,wDAAwD;IACxD,iBAAiB,IAAI;IACrB,kEAAkE;IAClE,eAAe,IAAI;IACnB,mDAAmD;IACnD,iBAAiB,IAAI;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,0BAA0B;IACzC,SAAS,EAAE,uBAAuB,CAAC;IACnC,UAAU,CAAC,EAAE,SAAS,CAAC;CACxB;AAED;;;GAGG;AACH,MAAM,WAAW,sCAAsC;IACrD,UAAU,EAAE,uBAAuB,EAAE,CAAC;IACtC,UAAU,EAAE,iBAAiB,CAAC;CAC/B;AAED;;;GAGG;AACH,MAAM,WAAW,2BAA2B;IAC1C,qGAAqG;IACrG,MAAM,EAAE,aAAa,CAAC;IACtB,oFAAoF;IACpF,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,sJAAsJ;IACtJ,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,0GAA0G;IAC1G,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iKAAiK;IACjK,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,2BAA2B;IAC3B,QAAQ,CAAC,EAAE,QAAQ,CAAC;IACpB,kDAAkD;IAClD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,kDAAkD;IAClD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,kDAAkD;IAClD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,yBAAyB;IACzB,OAAO,CAAC,EAAE,QAAQ,CAAC;CACpB;AAED;;;GAGG;AACH,MAAM,WAAW,uCAAwC,SAAQ,2BAA2B;IAC1F,SAAS,EAAE,UAAU,CAAC;CACvB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MassProperties.js","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAKH;;;GAGG;AACH,IAAY,uBAOX;AAPD,WAAY,uBAAuB;IACjC,wDAAwD;IACxD,+FAAqB,CAAA;IACrB,kEAAkE;IAClE,2FAAmB,CAAA;IACnB,mDAAmD;IACnD,+FAAqB,CAAA;AACvB,CAAC,EAPW,uBAAuB,uCAAvB,uBAAuB,QAOlC","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 Geometry\n */\n\nimport { BentleyStatus, CompressedId64Set, Id64Array, Id64String } from \"@itwin/core-bentley\";\nimport { XYZProps } from \"@itwin/core-geometry\";\n\n/** Specify whether to accumulate volumes, areas, or lengths for the supplied elements.\n * @public\n * @extensions\n */\nexport enum MassPropertiesOperation {\n /** Return lengths for open paths and planar regions. */\n AccumulateLengths = 0,\n /** Return areas and perimeters for solid and surface geometry. */\n AccumulateAreas = 1,\n /** Return volumes and areas for solid geometry. */\n AccumulateVolumes = 2,\n}\n\n/** Information required to request mass properties for elements from the front end to the back end.\n * @public\n * @extensions\n */\nexport interface MassPropertiesRequestProps {\n operation: MassPropertiesOperation;\n candidates?: Id64Array;\n}\n\n/** Information required to request mass properties for each element separately from the front end to the back end.\n * @public\n */\nexport interface MassPropertiesPerCandidateRequestProps {\n operations: MassPropertiesOperation[];\n candidates: CompressedId64Set;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation.\n * @public\n * @extensions\n */\nexport interface MassPropertiesResponseProps {\n /** Success if requested [[MassPropertiesOperation]] could be evaluated for the specified elements */\n status: BentleyStatus;\n /** Volume of solids when [[MassPropertiesOperation.AccumulateVolumes]] requested */\n volume?: number;\n /** Surface area of solids and surfaces when [[MassPropertiesOperation.AccumulateVolumes]] or [[MassPropertiesOperation.AccumulateAreas]] requested */\n area?: number;\n /** Perimeter of surfaces and planar regions when [[MassPropertiesOperation.AccumulateAreas]] requested */\n perimeter?: number;\n /** Length of curves or perimeter of planar regions when [[MassPropertiesOperation.AccumulateAreas]] or [[MassPropertiesOperation.AccumulateLength]] requested */\n length?: number;\n /** Centroid of geometry */\n centroid?: XYZProps;\n /** Product of inertia with respect to xy plane */\n ixy?: number;\n /** Product of inertia with respect to xz plane */\n ixz?: number;\n /** Product of inertia with respect to yz plane */\n iyz?: number;\n /** Moments of inertia */\n moments?: XYZProps;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.\n * @public\n */\nexport interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {\n candidate: Id64String;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"MassProperties.js","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;AAKH;;;GAGG;AACH,IAAY,uBAOX;AAPD,WAAY,uBAAuB;IACjC,wDAAwD;IACxD,+FAAqB,CAAA;IACrB,kEAAkE;IAClE,2FAAmB,CAAA;IACnB,mDAAmD;IACnD,+FAAqB,CAAA;AACvB,CAAC,EAPW,uBAAuB,uCAAvB,uBAAuB,QAOlC","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 Geometry\n */\n\nimport { BentleyStatus, CompressedId64Set, Id64Array, Id64String } from \"@itwin/core-bentley\";\nimport { XYZProps } from \"@itwin/core-geometry\";\n\n/** Specify whether to accumulate volumes, areas, or lengths for the supplied elements.\n * @public\n * @extensions\n */\nexport enum MassPropertiesOperation {\n /** Return lengths for open paths and planar regions. */\n AccumulateLengths = 0,\n /** Return areas and perimeters for solid and surface geometry. */\n AccumulateAreas = 1,\n /** Return volumes and areas for solid geometry. */\n AccumulateVolumes = 2,\n}\n\n/** Information required to request mass properties for elements from the front end to the back end.\n * @public\n * @extensions\n */\nexport interface MassPropertiesRequestProps {\n operation: MassPropertiesOperation;\n candidates?: Id64Array;\n}\n\n/** Information required to request mass properties for each element separately from the front end to the back end.\n * @public\n * @deprecated in 4.11. Use [[MassPropertiesRequestProps]].\n */\nexport interface MassPropertiesPerCandidateRequestProps {\n operations: MassPropertiesOperation[];\n candidates: CompressedId64Set;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation.\n * @public\n * @extensions\n */\nexport interface MassPropertiesResponseProps {\n /** Success if requested [[MassPropertiesOperation]] could be evaluated for the specified elements */\n status: BentleyStatus;\n /** Volume of solids when [[MassPropertiesOperation.AccumulateVolumes]] requested */\n volume?: number;\n /** Surface area of solids and surfaces when [[MassPropertiesOperation.AccumulateVolumes]] or [[MassPropertiesOperation.AccumulateAreas]] requested */\n area?: number;\n /** Perimeter of surfaces and planar regions when [[MassPropertiesOperation.AccumulateAreas]] requested */\n perimeter?: number;\n /** Length of curves or perimeter of planar regions when [[MassPropertiesOperation.AccumulateAreas]] or [[MassPropertiesOperation.AccumulateLength]] requested */\n length?: number;\n /** Centroid of geometry */\n centroid?: XYZProps;\n /** Product of inertia with respect to xy plane */\n ixy?: number;\n /** Product of inertia with respect to xz plane */\n ixz?: number;\n /** Product of inertia with respect to yz plane */\n iyz?: number;\n /** Moments of inertia */\n moments?: XYZProps;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.\n * @public\n * @deprecated in 4.11. Use [[MassPropertiesResponseProps]].\n */\nexport interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {\n candidate: Id64String;\n}\n"]}
|
|
@@ -72,7 +72,7 @@ class IModelReadRpcInterface extends RpcInterface_1.RpcInterface {
|
|
|
72
72
|
async cancelSnap(_iModelToken, _sessionId) { return this.forward(arguments); }
|
|
73
73
|
async getGeometryContainment(_iModelToken, _props) { return this.forward(arguments); }
|
|
74
74
|
async getMassProperties(_iModelToken, _props) { return this.forward(arguments); }
|
|
75
|
-
async getMassPropertiesPerCandidate(_iModelToken, _props) { return this.forward(arguments); }
|
|
75
|
+
async getMassPropertiesPerCandidate(_iModelToken, _props) { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated
|
|
76
76
|
async getIModelCoordinatesFromGeoCoordinates(_iModelToken, _props) { return this.forward(arguments); }
|
|
77
77
|
async getGeoCoordinatesFromIModelCoordinates(_iModelToken, _props) { return this.forward(arguments); }
|
|
78
78
|
async getGeometrySummary(_iModelToken, _props) { return this.forward(arguments); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IModelReadRpcInterface.js","sourceRoot":"","sources":["../../../src/rpc/IModelReadRpcInterface.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;;;;;;;AAoBH,kDAA+C;AAC/C,8CAA2C;AAO3C,sDAA8D;AAC9D,kDAAwD;AACxD,sDAAmD;AAGnD;;;GAGG;AACH,MAAa,sBAAuB,SAAQ,gCAAmB;IACtD,wBAAwB,GAAY,IAAI,CAAC;IAChC,OAAO,GAAG,kBAAkB,CAAC;CAC9C;AAHD,wDAGC;AAwBD;;;;GAIG;AACH,MAAsB,sBAAuB,SAAQ,2BAAY;IAC/D,oEAAoE;IAC7D,MAAM,CAAC,SAAS,KAA6B,OAAO,uBAAU,CAAC,qBAAqB,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC;IAEtH,0FAA0F;IACnF,MAAM,CAAC,mBAAmB,CAAC,KAAsB,IAA4B,OAAO,uBAAU,CAAC,qBAAqB,CAAC,sBAAsB,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;IAE7J,2CAA2C;IACpC,MAAM,CAAU,aAAa,GAAG,wBAAwB,CAAC;IAEhE,6CAA6C;IACtC,MAAM,CAAC,gBAAgB,GAAG,OAAO,CAAC;IAEzC;;;iGAG6F;IAEhF,AAAN,KAAK,CAAC,kBAAkB,CAAC,YAAgC,IAAoC,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;IAC9H,KAAK,CAAC,SAAS,CAAC,YAA4B,EAAE,QAAwB,IAA8B,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CA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CAAC;IACjC,CAAC;IACD,gBAAgB;IACT,KAAK,CAAC,aAAa,CAAC,YAA4B,EAAE,QAAgB,EAAE,SAAkB,EAAE,WAAmB,EAAE,GAAG,KAAY,IAAkB,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;;AAnExL,wDAoEC;AAlDc;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;gEACgE;AAGxH;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;gEAC8F;AAEtJ;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8EAC2E;AAGnI;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;2DACuE;AAE/H;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC4E;AAEpI;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;+DACkF;AAM1I;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;+DACuE;AAG/H;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC6G;AAMrK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC+C;AAEvG;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;sEAC8G;AAEtK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC0G;AAQlK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;oFAC0H","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 RpcInterface\n */\n\nimport { CompressedId64Set, GuidString, Id64String, IModelStatus } from \"@itwin/core-bentley\";\nimport { Range3dProps } from \"@itwin/core-geometry\";\nimport { CodeProps } from \"../Code\";\nimport { DbBlobRequest, DbBlobResponse, DbQueryRequest, DbQueryResponse } from \"../ConcurrentQuery\";\nimport { ElementMeshRequestProps } from \"../ElementMesh\";\nimport { ElementLoadOptions, ElementProps } from \"../ElementProps\";\nimport { EntityQueryParams } from \"../EntityProps\";\nimport { FontMapProps } from \"../Fonts\";\nimport {\n GeoCoordinatesRequestProps, GeoCoordinatesResponseProps, IModelCoordinatesRequestProps, IModelCoordinatesResponseProps,\n} from \"../GeoCoordinateServices\";\nimport { GeometryContainmentRequestProps, GeometryContainmentResponseProps } from \"../GeometryContainment\";\nimport { GeometrySummaryRequestProps } from \"../GeometrySummary\";\nimport { IModelConnectionProps, IModelRpcOpenProps, IModelRpcProps } from \"../IModel\";\nimport {\n MassPropertiesPerCandidateRequestProps, MassPropertiesPerCandidateResponseProps, MassPropertiesRequestProps, MassPropertiesResponseProps,\n} from \"../MassProperties\";\nimport { ModelProps } from \"../ModelProps\";\nimport { RpcInterface } from \"../RpcInterface\";\nimport { RpcManager } from \"../RpcManager\";\nimport { SnapRequestProps, SnapResponseProps } from \"../internal/Snapping\";\nimport { TextureData, TextureLoadProps } from \"../TextureProps\";\nimport {\n CustomViewState3dCreatorOptions, CustomViewState3dProps, HydrateViewStateRequestProps, HydrateViewStateResponseProps, SubCategoryResultRow,\n ViewStateLoadProps, ViewStateProps,\n} from \"../ViewProps\";\nimport { RpcResponseCacheControl } from \"./core/RpcConstants\";\nimport { RpcNotFoundResponse } from \"./core/RpcControl\";\nimport { RpcOperation } from \"./core/RpcOperation\";\nimport { RpcRoutingToken } from \"./core/RpcRoutingToken\";\n\n/** Response if the IModelDb was not found at the backend\n * (if the service has moved)\n * @public\n */\nexport class IModelNotFoundResponse extends RpcNotFoundResponse {\n public isIModelNotFoundResponse: boolean = true;\n public override message = \"iModel not found\";\n}\n\n/** Describes the volume of geometry contained with a [GeometricModel]($backend) as returned by\n * [IModelConnection.Models.queryExtents]($frontend) and [IModelDb.Models.queryExtents]($backend).\n * @public\n */\nexport interface ModelExtentsProps {\n /** The Id of the model, or [Id64.invalid]($bentley) if the input model Id was not a well-formed [Id64String]($bentley). */\n id: Id64String;\n /** The volume of geometry contained within the model.\n * This range will be null (@see [Range3d.isNull]($geometry)) if [[status]] is not [IModelStatus.Success]($bentley) or the model contains no geometry.\n */\n extents: Range3dProps;\n /** A status code indicating what if any error occurred obtaining the model's extents. For example:\n * - [IModelStatus.InvalidId]($bentley) if the input model Id was not a well-formed [Id64String]($bentley);\n * - [IModelStatus.NotFound]($bentley) if no model with the specified Id exists in the [[IModel]];\n * - [IModelStatus.WrongModel]($bentley) if the specified model is not a [GeometricModel]($backend); or\n * - [IModelStatus.Success]($bentley) if the extents were successfully obtained.\n *\n * If `status` is anything other than [IModelStatus.Success]($bentley), [[extents]] will be a null range.\n */\n status: IModelStatus;\n}\n\n/** The RPC interface for reading from an iModel.\n * All operations only require read-only access.\n * This interface is not normally used directly. See IModelConnection for higher-level and more convenient API for accessing iModels from a frontend.\n * @internal\n */\nexport abstract class IModelReadRpcInterface extends RpcInterface {\n /** Returns the IModelReadRpcInterface instance for the frontend. */\n public static getClient(): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface); }\n\n /** Returns the IModelReadRpcInterface instance for a custom RPC routing configuration. */\n public static getClientForRouting(token: RpcRoutingToken): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface, token); }\n\n /** The immutable name of the interface. */\n public static readonly interfaceName = \"IModelReadRpcInterface\";\n\n /** The semantic version of the interface. */\n public static interfaceVersion = \"3.7.0\";\n\n /*===========================================================================================\n NOTE: Any add/remove/change to the methods below requires an update of the interface version.\n NOTE: Please consult the README in this folder for the semantic versioning rules.\n ===========================================================================================*/\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getConnectionProps(_iModelToken: IModelRpcOpenProps): Promise<IModelConnectionProps> { return this.forward(arguments); }\n public async queryRows(_iModelToken: IModelRpcProps, _request: DbQueryRequest): Promise<DbQueryResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async querySubCategories(_iModelToken: IModelRpcProps, _categoryIds: CompressedId64Set): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryAllUsedSpatialSubCategories(_iModelToken: IModelRpcProps): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n public async queryBlob(_iModelToken: IModelRpcProps, _request: DbBlobRequest): Promise<DbBlobResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getModelProps(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelRanges(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<Range3dProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelExtents(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelExtentsProps[]> { return this.forward(arguments); }\n public async queryModelProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ModelProps[]> { return this.forward(arguments); }\n public async getElementProps(_iModelToken: IModelRpcProps, _elementIds: Id64String[]): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryElementProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryEntityIds(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<Id64String[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getClassHierarchy(_iModelToken: IModelRpcProps, _startClassName: string): Promise<string[]> { return this.forward(arguments); }\n public async getAllCodeSpecs(_iModelToken: IModelRpcProps): Promise<any[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getViewStateData(_iModelToken: IModelRpcProps, _viewDefinitionId: string, _options?: ViewStateLoadProps): Promise<ViewStateProps> { return this.forward(arguments); }\n public async readFontJson(_iModelToken: IModelRpcProps): Promise<FontMapProps> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getToolTipMessage(_iModelToken: IModelRpcProps, _elementId: string): Promise<string[]> { return this.forward(arguments); }\n /** @deprecated in 3.x use ViewStore apis. */\n public async getViewThumbnail(_iModelToken: IModelRpcProps, _viewId: string): Promise<Uint8Array> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getDefaultViewId(_iModelToken: IModelRpcProps): Promise<Id64String> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getCustomViewState3dData(_iModelToken: IModelRpcProps, _options: CustomViewState3dCreatorOptions): Promise<CustomViewState3dProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async hydrateViewState(_iModelToken: IModelRpcProps, _options: HydrateViewStateRequestProps): Promise<HydrateViewStateResponseProps> { return this.forward(arguments); }\n public async requestSnap(_iModelToken: IModelRpcProps, _sessionId: string, _props: SnapRequestProps): Promise<SnapResponseProps> { return this.forward(arguments); }\n public async cancelSnap(_iModelToken: IModelRpcProps, _sessionId: string): Promise<void> { return this.forward(arguments); }\n public async getGeometryContainment(_iModelToken: IModelRpcProps, _props: GeometryContainmentRequestProps): Promise<GeometryContainmentResponseProps> { return this.forward(arguments); }\n public async getMassProperties(_iModelToken: IModelRpcProps, _props: MassPropertiesRequestProps): Promise<MassPropertiesResponseProps> { return this.forward(arguments); }\n public async getMassPropertiesPerCandidate(_iModelToken: IModelRpcProps, _props: MassPropertiesPerCandidateRequestProps): Promise<MassPropertiesPerCandidateResponseProps[]> { return this.forward(arguments); }\n public async getIModelCoordinatesFromGeoCoordinates(_iModelToken: IModelRpcProps, _props: IModelCoordinatesRequestProps): Promise<IModelCoordinatesResponseProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getGeoCoordinatesFromIModelCoordinates(_iModelToken: IModelRpcProps, _props: GeoCoordinatesRequestProps): Promise<GeoCoordinatesResponseProps> { return this.forward(arguments); }\n public async getGeometrySummary(_iModelToken: IModelRpcProps, _props: GeometrySummaryRequestProps): Promise<string> { return this.forward(arguments); }\n public async queryTextureData(_iModelToken: IModelRpcProps, _textureLoadProps: TextureLoadProps): Promise<TextureData | undefined> { return this.forward(arguments); }\n public async loadElementProps(_iModelToken: IModelRpcProps, _elementIdentifier: Id64String | GuidString | CodeProps, _options?: ElementLoadOptions): Promise<ElementProps | undefined> {\n return this.forward(arguments);\n }\n public async generateElementMeshes(_iModelToken: IModelRpcProps, _props: ElementMeshRequestProps): Promise<Uint8Array> {\n return this.forward(arguments);\n }\n /** @internal */\n public async callViewStore(_iModelToken: IModelRpcProps, _version: string, _forWrite: boolean, _methodName: string, ..._args: any[]): Promise<any> { return this.forward(arguments); }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"IModelReadRpcInterface.js","sourceRoot":"","sources":["../../../src/rpc/IModelReadRpcInterface.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;AAC/F;;GAEG;;;;;;;;;AAoBH,kDAA+C;AAC/C,8CAA2C;AAO3C,sDAA8D;AAC9D,kDAAwD;AACxD,sDAAmD;AAGnD;;;GAGG;AACH,MAAa,sBAAuB,SAAQ,gCAAmB;IACtD,wBAAwB,GAAY,IAAI,CAAC;IAChC,OAAO,GAAG,kBAAkB,CAAC;CAC9C;AAHD,wDAGC;AAwBD;;;;GAIG;AACH,MAAsB,sBAAuB,SAAQ,2BAAY;IAC/D,oE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,CAAC,sCAAuB,CAAC,SAAS,CAAC;+DACkF;AAM1I;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;+DACuE;AAG/H;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC6G;AAMrK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC+C;AAEvG;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;sEAC8G;AAEtK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;8DAC0G;AAQlK;IADZ,2BAAY,CAAC,oBAAoB,CAAC,sCAAuB,CAAC,SAAS,CAAC;oFAC0H","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 RpcInterface\n */\n\nimport { CompressedId64Set, GuidString, Id64String, IModelStatus } from \"@itwin/core-bentley\";\nimport { Range3dProps } from \"@itwin/core-geometry\";\nimport { CodeProps } from \"../Code\";\nimport { DbBlobRequest, DbBlobResponse, DbQueryRequest, DbQueryResponse } from \"../ConcurrentQuery\";\nimport { ElementMeshRequestProps } from \"../ElementMesh\";\nimport { ElementLoadOptions, ElementProps } from \"../ElementProps\";\nimport { EntityQueryParams } from \"../EntityProps\";\nimport { FontMapProps } from \"../Fonts\";\nimport {\n GeoCoordinatesRequestProps, GeoCoordinatesResponseProps, IModelCoordinatesRequestProps, IModelCoordinatesResponseProps,\n} from \"../GeoCoordinateServices\";\nimport { GeometryContainmentRequestProps, GeometryContainmentResponseProps } from \"../GeometryContainment\";\nimport { GeometrySummaryRequestProps } from \"../GeometrySummary\";\nimport { IModelConnectionProps, IModelRpcOpenProps, IModelRpcProps } from \"../IModel\";\nimport {\n MassPropertiesPerCandidateRequestProps, MassPropertiesPerCandidateResponseProps, MassPropertiesRequestProps, MassPropertiesResponseProps,\n} from \"../MassProperties\";\nimport { ModelProps } from \"../ModelProps\";\nimport { RpcInterface } from \"../RpcInterface\";\nimport { RpcManager } from \"../RpcManager\";\nimport { SnapRequestProps, SnapResponseProps } from \"../internal/Snapping\";\nimport { TextureData, TextureLoadProps } from \"../TextureProps\";\nimport {\n CustomViewState3dCreatorOptions, CustomViewState3dProps, HydrateViewStateRequestProps, HydrateViewStateResponseProps, SubCategoryResultRow,\n ViewStateLoadProps, ViewStateProps,\n} from \"../ViewProps\";\nimport { RpcResponseCacheControl } from \"./core/RpcConstants\";\nimport { RpcNotFoundResponse } from \"./core/RpcControl\";\nimport { RpcOperation } from \"./core/RpcOperation\";\nimport { RpcRoutingToken } from \"./core/RpcRoutingToken\";\n\n/** Response if the IModelDb was not found at the backend\n * (if the service has moved)\n * @public\n */\nexport class IModelNotFoundResponse extends RpcNotFoundResponse {\n public isIModelNotFoundResponse: boolean = true;\n public override message = \"iModel not found\";\n}\n\n/** Describes the volume of geometry contained with a [GeometricModel]($backend) as returned by\n * [IModelConnection.Models.queryExtents]($frontend) and [IModelDb.Models.queryExtents]($backend).\n * @public\n */\nexport interface ModelExtentsProps {\n /** The Id of the model, or [Id64.invalid]($bentley) if the input model Id was not a well-formed [Id64String]($bentley). */\n id: Id64String;\n /** The volume of geometry contained within the model.\n * This range will be null (@see [Range3d.isNull]($geometry)) if [[status]] is not [IModelStatus.Success]($bentley) or the model contains no geometry.\n */\n extents: Range3dProps;\n /** A status code indicating what if any error occurred obtaining the model's extents. For example:\n * - [IModelStatus.InvalidId]($bentley) if the input model Id was not a well-formed [Id64String]($bentley);\n * - [IModelStatus.NotFound]($bentley) if no model with the specified Id exists in the [[IModel]];\n * - [IModelStatus.WrongModel]($bentley) if the specified model is not a [GeometricModel]($backend); or\n * - [IModelStatus.Success]($bentley) if the extents were successfully obtained.\n *\n * If `status` is anything other than [IModelStatus.Success]($bentley), [[extents]] will be a null range.\n */\n status: IModelStatus;\n}\n\n/** The RPC interface for reading from an iModel.\n * All operations only require read-only access.\n * This interface is not normally used directly. See IModelConnection for higher-level and more convenient API for accessing iModels from a frontend.\n * @internal\n */\nexport abstract class IModelReadRpcInterface extends RpcInterface {\n /** Returns the IModelReadRpcInterface instance for the frontend. */\n public static getClient(): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface); }\n\n /** Returns the IModelReadRpcInterface instance for a custom RPC routing configuration. */\n public static getClientForRouting(token: RpcRoutingToken): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface, token); }\n\n /** The immutable name of the interface. */\n public static readonly interfaceName = \"IModelReadRpcInterface\";\n\n /** The semantic version of the interface. */\n public static interfaceVersion = \"3.7.0\";\n\n /*===========================================================================================\n NOTE: Any add/remove/change to the methods below requires an update of the interface version.\n NOTE: Please consult the README in this folder for the semantic versioning rules.\n ===========================================================================================*/\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getConnectionProps(_iModelToken: IModelRpcOpenProps): Promise<IModelConnectionProps> { return this.forward(arguments); }\n public async queryRows(_iModelToken: IModelRpcProps, _request: DbQueryRequest): Promise<DbQueryResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async querySubCategories(_iModelToken: IModelRpcProps, _categoryIds: CompressedId64Set): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryAllUsedSpatialSubCategories(_iModelToken: IModelRpcProps): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n public async queryBlob(_iModelToken: IModelRpcProps, _request: DbBlobRequest): Promise<DbBlobResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getModelProps(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelRanges(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<Range3dProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelExtents(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelExtentsProps[]> { return this.forward(arguments); }\n public async queryModelProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ModelProps[]> { return this.forward(arguments); }\n public async getElementProps(_iModelToken: IModelRpcProps, _elementIds: Id64String[]): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryElementProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryEntityIds(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<Id64String[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getClassHierarchy(_iModelToken: IModelRpcProps, _startClassName: string): Promise<string[]> { return this.forward(arguments); }\n public async getAllCodeSpecs(_iModelToken: IModelRpcProps): Promise<any[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getViewStateData(_iModelToken: IModelRpcProps, _viewDefinitionId: string, _options?: ViewStateLoadProps): Promise<ViewStateProps> { return this.forward(arguments); }\n public async readFontJson(_iModelToken: IModelRpcProps): Promise<FontMapProps> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getToolTipMessage(_iModelToken: IModelRpcProps, _elementId: string): Promise<string[]> { return this.forward(arguments); }\n /** @deprecated in 3.x use ViewStore apis. */\n public async getViewThumbnail(_iModelToken: IModelRpcProps, _viewId: string): Promise<Uint8Array> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getDefaultViewId(_iModelToken: IModelRpcProps): Promise<Id64String> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getCustomViewState3dData(_iModelToken: IModelRpcProps, _options: CustomViewState3dCreatorOptions): Promise<CustomViewState3dProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async hydrateViewState(_iModelToken: IModelRpcProps, _options: HydrateViewStateRequestProps): Promise<HydrateViewStateResponseProps> { return this.forward(arguments); }\n public async requestSnap(_iModelToken: IModelRpcProps, _sessionId: string, _props: SnapRequestProps): Promise<SnapResponseProps> { return this.forward(arguments); }\n public async cancelSnap(_iModelToken: IModelRpcProps, _sessionId: string): Promise<void> { return this.forward(arguments); }\n public async getGeometryContainment(_iModelToken: IModelRpcProps, _props: GeometryContainmentRequestProps): Promise<GeometryContainmentResponseProps> { return this.forward(arguments); }\n public async getMassProperties(_iModelToken: IModelRpcProps, _props: MassPropertiesRequestProps): Promise<MassPropertiesResponseProps> { return this.forward(arguments); }\n public async getMassPropertiesPerCandidate(_iModelToken: IModelRpcProps, _props: MassPropertiesPerCandidateRequestProps): Promise<MassPropertiesPerCandidateResponseProps[]> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getIModelCoordinatesFromGeoCoordinates(_iModelToken: IModelRpcProps, _props: IModelCoordinatesRequestProps): Promise<IModelCoordinatesResponseProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getGeoCoordinatesFromIModelCoordinates(_iModelToken: IModelRpcProps, _props: GeoCoordinatesRequestProps): Promise<GeoCoordinatesResponseProps> { return this.forward(arguments); }\n public async getGeometrySummary(_iModelToken: IModelRpcProps, _props: GeometrySummaryRequestProps): Promise<string> { return this.forward(arguments); }\n public async queryTextureData(_iModelToken: IModelRpcProps, _textureLoadProps: TextureLoadProps): Promise<TextureData | undefined> { return this.forward(arguments); }\n public async loadElementProps(_iModelToken: IModelRpcProps, _elementIdentifier: Id64String | GuidString | CodeProps, _options?: ElementLoadOptions): Promise<ElementProps | undefined> {\n return this.forward(arguments);\n }\n public async generateElementMeshes(_iModelToken: IModelRpcProps, _props: ElementMeshRequestProps): Promise<Uint8Array> {\n return this.forward(arguments);\n }\n /** @internal */\n public async callViewStore(_iModelToken: IModelRpcProps, _version: string, _forWrite: boolean, _methodName: string, ..._args: any[]): Promise<any> { return this.forward(arguments); }\n}\n"]}
|
|
@@ -81,7 +81,7 @@ export interface ChangesetProps {
|
|
|
81
81
|
size: number;
|
|
82
82
|
}
|
|
83
83
|
/** Properties of a changeset file
|
|
84
|
-
* @
|
|
84
|
+
* @public
|
|
85
85
|
*/
|
|
86
86
|
export interface ChangesetFileProps extends ChangesetProps {
|
|
87
87
|
/** The full pathname of the local file holding this changeset. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ChangesetProps.js","sourceRoot":"","sources":["../../src/ChangesetProps.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;;GAGG;AAuCH;;;GAGG;AACH,MAAM,CAAN,IAAY,aAOX;AAPD,WAAY,aAAa;IACvB,mDAAmD;IACnD,uDAAW,CAAA;IACX,+CAA+C;IAC/C,qDAAU,CAAA;IACV,gEAAgE;IAChE,8DAAwB,CAAA;AAC1B,CAAC,EAPW,aAAa,KAAb,aAAa,QAOxB","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/**\n * @packageDocumentation\n * @module iModels\n */\n\n/** @public */\nexport type LocalFileName = string;\n/** @public */\nexport type LocalDirName = string;\n\n/** A string that identifies a changeset.\n * @note this string is *not* a Guid. It is generated internally based on the content of the changeset.\n * @public\n * @extensions\n */\nexport type ChangesetId = string;\n\n/** The index of a changeset, assigned by iModelHub.\n * @note 0 means \"before the first changeset.\" Values less than 0 are invalid.\n * @public\n * @extensions\n */\nexport type ChangesetIndex = number;\n\n/** Both the index and Id of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIndexAndId { readonly index: ChangesetIndex, readonly id: ChangesetId }\n\n/** The Id and optionally the index of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIdWithIndex { readonly index?: ChangesetIndex, readonly id: ChangesetId }\n\n/** either changeset index, id, or both\n* @public\n * @extensions\n*/\nexport type ChangesetIndexOrId = ChangesetIndexAndId | { readonly index: ChangesetIndex, readonly id?: never } | { readonly id: ChangesetId, readonly index?: never };\n\n/** Value to indicate whether a changeset contains schema changes or not\n * @public\n * @extensions\n */\nexport enum ChangesetType {\n /** changeset does *not* contain schema changes. */\n Regular = 0,\n /** changeset *does* contain schema changes. */\n Schema = 1,\n /** Schema changeset pushed by iModel with SchemaSync enabled */\n SchemaSync = Schema | 64,\n}\n\n/** Properties of a changeset\n * @public\n */\nexport interface ChangesetProps {\n /** The index (sequence number) from IModelHub for this changeset. Larger index values were pushed later. */\n index: ChangesetIndex;\n /** the ChangesetId */\n id: ChangesetId;\n /** the ChangeSetId of the parent changeset of this changeset */\n parentId: ChangesetId;\n /** The type of changeset */\n changesType: ChangesetType;\n /** The user-supplied description of the work this changeset holds */\n description: string;\n /** The BriefcaseId of the briefcase that created this changeset */\n briefcaseId: number;\n /** The date this changeset was uploaded to the hub */\n pushDate: string;\n /** The identity of the user that created this changeset */\n userCreated: string;\n /** The size, in bytes, of this changeset */\n size: number;\n}\n\n/** Properties of a changeset file\n * @
|
|
1
|
+
{"version":3,"file":"ChangesetProps.js","sourceRoot":"","sources":["../../src/ChangesetProps.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;;GAGG;AAuCH;;;GAGG;AACH,MAAM,CAAN,IAAY,aAOX;AAPD,WAAY,aAAa;IACvB,mDAAmD;IACnD,uDAAW,CAAA;IACX,+CAA+C;IAC/C,qDAAU,CAAA;IACV,gEAAgE;IAChE,8DAAwB,CAAA;AAC1B,CAAC,EAPW,aAAa,KAAb,aAAa,QAOxB","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/**\n * @packageDocumentation\n * @module iModels\n */\n\n/** @public */\nexport type LocalFileName = string;\n/** @public */\nexport type LocalDirName = string;\n\n/** A string that identifies a changeset.\n * @note this string is *not* a Guid. It is generated internally based on the content of the changeset.\n * @public\n * @extensions\n */\nexport type ChangesetId = string;\n\n/** The index of a changeset, assigned by iModelHub.\n * @note 0 means \"before the first changeset.\" Values less than 0 are invalid.\n * @public\n * @extensions\n */\nexport type ChangesetIndex = number;\n\n/** Both the index and Id of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIndexAndId { readonly index: ChangesetIndex, readonly id: ChangesetId }\n\n/** The Id and optionally the index of a changeset\n * @public\n * @extensions\n */\nexport interface ChangesetIdWithIndex { readonly index?: ChangesetIndex, readonly id: ChangesetId }\n\n/** either changeset index, id, or both\n* @public\n * @extensions\n*/\nexport type ChangesetIndexOrId = ChangesetIndexAndId | { readonly index: ChangesetIndex, readonly id?: never } | { readonly id: ChangesetId, readonly index?: never };\n\n/** Value to indicate whether a changeset contains schema changes or not\n * @public\n * @extensions\n */\nexport enum ChangesetType {\n /** changeset does *not* contain schema changes. */\n Regular = 0,\n /** changeset *does* contain schema changes. */\n Schema = 1,\n /** Schema changeset pushed by iModel with SchemaSync enabled */\n SchemaSync = Schema | 64,\n}\n\n/** Properties of a changeset\n * @public\n */\nexport interface ChangesetProps {\n /** The index (sequence number) from IModelHub for this changeset. Larger index values were pushed later. */\n index: ChangesetIndex;\n /** the ChangesetId */\n id: ChangesetId;\n /** the ChangeSetId of the parent changeset of this changeset */\n parentId: ChangesetId;\n /** The type of changeset */\n changesType: ChangesetType;\n /** The user-supplied description of the work this changeset holds */\n description: string;\n /** The BriefcaseId of the briefcase that created this changeset */\n briefcaseId: number;\n /** The date this changeset was uploaded to the hub */\n pushDate: string;\n /** The identity of the user that created this changeset */\n userCreated: string;\n /** The size, in bytes, of this changeset */\n size: number;\n}\n\n/** Properties of a changeset file\n * @public\n */\nexport interface ChangesetFileProps extends ChangesetProps {\n /** The full pathname of the local file holding this changeset. */\n pathname: LocalFileName;\n}\n\n/**\n * A range of changesets\n * @public\n * @extensions\n */\nexport interface ChangesetRange {\n /** index of the first changeset */\n first: ChangesetIndex;\n /** index of last changeset. If undefined, all changesets after first are returned. */\n end?: ChangesetIndex;\n}\n"]}
|
package/lib/esm/Image.d.ts
CHANGED
|
@@ -83,4 +83,19 @@ export declare class ImageSource {
|
|
|
83
83
|
/** Construct a new ImageSource, which takes ownership of the Uint8Array. */
|
|
84
84
|
constructor(data: Uint8Array | string, format: ImageSourceFormat);
|
|
85
85
|
}
|
|
86
|
+
/** An [[ImageSource]] encoded in binary form as a Jpeg or Png, as opposed to one encoded
|
|
87
|
+
* in string format as an Svg.
|
|
88
|
+
* Only binary ImageSources can be used for [[Texture]]s stored in [[IModelDb]]s.
|
|
89
|
+
* @public
|
|
90
|
+
*/
|
|
91
|
+
export interface BinaryImageSource {
|
|
92
|
+
/** The format in which the [[data]] is encoded. */
|
|
93
|
+
readonly format: ImageSourceFormat.Jpeg | ImageSourceFormat.Png;
|
|
94
|
+
/** The image data encoded according to [[format]]. */
|
|
95
|
+
readonly data: Uint8Array;
|
|
96
|
+
}
|
|
97
|
+
/** Returns true if `source` is a [[BinaryImageSource]].
|
|
98
|
+
* @public
|
|
99
|
+
*/
|
|
100
|
+
export declare function isBinaryImageSource(source: ImageSource): source is BinaryImageSource;
|
|
86
101
|
//# sourceMappingURL=Image.d.ts.map
|
package/lib/esm/Image.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH;;;;;GAKG;AACH,oBAAY,iBAAiB;IAC3B,uCAAuC;IACvC,IAAI,IAAI;IACR,sCAAsC;IACtC,GAAG,IAAI;IACP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3C,SAAgB,IAAI,EAAE,UAAU,GAAG,MAAM,CAAC;IAC1C,4BAA4B;IAC5B,SAAgB,MAAM,EAAE,iBAAiB,CAAC;IAE1C,4EAA4E;gBACzD,IAAI,EAAE,UAAU,GAAG,MAAM,EAAE,MAAM,EAAE,iBAAiB;CAIxE;AAED;;;;GAIG;AACH,MAAM,WAAW,iBAAiB;IAChC,mDAAmD;IACnD,QAAQ,CAAC,MAAM,EAAE,iBAAiB,CAAC,IAAI,GAAG,iBAAiB,CAAC,GAAG,CAAC;IAChE,sDAAsD;IACtD,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAC;CAC3B;AAED;;GAEG;AACH,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,WAAW,GAAG,MAAM,IAAI,iBAAiB,CAEpF"}
|
package/lib/esm/Image.js
CHANGED
|
@@ -127,4 +127,10 @@ export class ImageSource {
|
|
|
127
127
|
this.format = format;
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
|
+
/** Returns true if `source` is a [[BinaryImageSource]].
|
|
131
|
+
* @public
|
|
132
|
+
*/
|
|
133
|
+
export function isBinaryImageSource(source) {
|
|
134
|
+
return source.format !== ImageSourceFormat.Svg && source.data instanceof Uint8Array;
|
|
135
|
+
}
|
|
130
136
|
//# sourceMappingURL=Image.js.map
|
package/lib/esm/Image.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Image.js","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH;;;;;GAKG;AACH,MAAM,CAAN,IAAY,iBAOX;AAPD,WAAY,iBAAiB;IAC3B,uCAAuC;IACvC,yDAAQ,CAAA;IACR,sCAAsC;IACtC,uDAAO,CAAA;IACP,wBAAwB;IACxB,2DAAS,CAAA;AACX,CAAC,EAPW,iBAAiB,KAAjB,iBAAiB,QAO5B;AAED;;GAEG;AACH,MAAM,OAAO,WAAW;IACtB,sGAAsG;IACtF,IAAI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AAO,KAAK,CAAC;IACjB,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAM,OAAO,WAAW;IACtB,2CAA2C;IAC3B,IAAI,CAAsB;IAC1C,4BAA4B;IACZ,MAAM,CAAoB;IAE1C,4EAA4E;IAC5E,YAAmB,IAAyB,EAAE,MAAyB;QACrE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;CACF","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 Rendering\n */\n\n/** Format of an [[ImageBuffer]].\n * The format determines how many bytes are allocated for each pixel in the buffer and the semantics of each byte.\n * @see [[ImageBuffer.getNumBytesPerPixel]]\n * @public\n * @extensions\n */\nexport enum ImageBufferFormat {\n /** RGBA format - 4 bytes per pixel. */\n Rgba = 0,\n /** RGB format - 3 bytes per pixel. */\n Rgb = 2,\n /** 1 byte per pixel. */\n Alpha = 5,\n}\n\n/** Uncompressed rectangular bitmap image data.\n * @public\n */\nexport class ImageBuffer {\n /** Image data in which each pixel occupies 1 or more bytes depending of the [[ImageBufferFormat]]. */\n public readonly data: Uint8Array;\n /** Format of the bytes in the image. */\n public readonly format: ImageBufferFormat;\n /** Width of image in pixels */\n public readonly width: number;\n\n /** Return the number of bytes allocated for each pixel. */\n public get numBytesPerPixel(): number { return ImageBuffer.getNumBytesPerPixel(this.format); }\n\n /** Determine the number of bytes allocated to a single pixel for the specified format. */\n public static getNumBytesPerPixel(format: ImageBufferFormat): number {\n switch (format) {\n case ImageBufferFormat.Alpha: return 1;\n case ImageBufferFormat.Rgb: return 3;\n default: return 4;\n }\n }\n\n /** Get the height of this image in pixels. */\n public get height(): number { return ImageBuffer.computeHeight(this.data, this.format, this.width); }\n\n /** Create a new ImageBuffer.\n * @note The ImageBuffer takes ownership of the input Uint8Array.\n * @param data The uncompressed image bytes. Must be a multiple of the width times the number of bytes per pixel specified by the format.\n * @param format The format of the image.\n * @param width The width of the image in pixels.\n * @returns A new ImageBuffer.\n * @throws Error if the length of the Uint8Array is not appropriate for the specified width and format.\n */\n public static create(data: Uint8Array, format: ImageBufferFormat, width: number): ImageBuffer {\n if (!this.isValidData(data, format, width))\n throw new Error(\"The number of bytes supplied for ImageBuffer do not match its width and format.\");\n\n return new ImageBuffer(data, format, width);\n }\n\n private static isValidData(data: Uint8Array, format: ImageBufferFormat, width: number): boolean {\n const height = this.computeHeight(data, format, width);\n return width > 0 && height > 0 && Math.floor(width) === width && Math.floor(height) === height;\n }\n\n private static computeHeight(data: Uint8Array, format: ImageBufferFormat, width: number): number {\n return data.length / (width * this.getNumBytesPerPixel(format));\n }\n\n private constructor(data: Uint8Array, format: ImageBufferFormat, width: number) {\n this.data = data;\n this.format = format;\n this.width = width;\n }\n}\n\n/** Returns whether the input is a power of two.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function isPowerOfTwo(num: number): boolean {\n return 0 === (num & (num - 1));\n}\n\n/** Returns the first power-of-two value greater than or equal to the input.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function nextHighestPowerOfTwo(num: number): number {\n --num;\n for (let i = 1; i < 32; i <<= 1)\n num = num | num >> i;\n\n return num + 1;\n}\n\n/** The format of an ImageSource.\n * @public\n * @extensions\n */\nexport enum ImageSourceFormat {\n /** Image data is stored with JPEG compression. */\n Jpeg = 0,\n /** Image data is stored with PNG compression. */\n Png = 2,\n /** Image is stored as an Svg stream.\n * @note SVG is only valid for ImageSources in JavaScript. It *may not* be used for persistent textures.\n */\n Svg = 3,\n}\n\n/** Returns true if the numeric `format` value is a valid member of the [[ImageSourceFormat]] enumeration.\n * @public\n */\nexport function isValidImageSourceFormat(format: number): format is ImageSourceFormat {\n switch (format) {\n case ImageSourceFormat.Jpeg:\n case ImageSourceFormat.Png:\n case ImageSourceFormat.Svg:\n return true;\n default:\n return false;\n }\n}\n\n/** Image data encoded and compressed in either Jpeg or Png format.\n * @public\n */\nexport class ImageSource {\n /** The content of the image, compressed */\n public readonly data: Uint8Array | string;\n /** The compression type. */\n public readonly format: ImageSourceFormat;\n\n /** Construct a new ImageSource, which takes ownership of the Uint8Array. */\n public constructor(data: Uint8Array | string, format: ImageSourceFormat) {\n this.data = data;\n this.format = format;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"Image.js","sourceRoot":"","sources":["../../src/Image.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAEH;;;;;GAKG;AACH,MAAM,CAAN,IAAY,iBAOX;AAPD,WAAY,iBAAiB;IAC3B,uCAAuC;IACvC,yDAAQ,CAAA;IACR,sCAAsC;IACtC,uDAAO,CAAA;IACP,wBAAwB;IACxB,2DAAS,CAAA;AACX,CAAC,EAPW,iBAAiB,KAAjB,iBAAiB,QAO5B;AAED;;GAEG;AACH,MAAM,OAAO,WAAW;IACtB,sGAAsG;IACtF,IAAI,CAAa;IACjC,wCAAwC;IACxB,MAAM,CAAoB;IAC1C,+BAA+B;IACf,KAAK,CAAS;IAE9B,2DAA2D;IAC3D,IAAW,gBAAgB,KAAa,OAAO,WAAW,CAAC,mBAAmB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC;IAE9F,0FAA0F;IACnF,MAAM,CAAC,mBAAmB,CAAC,MAAyB;QACzD,QAAQ,MAAM,EAAE,CAAC;YACf,KAAK,iBAAiB,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC;YACvC,KAAK,iBAAiB,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC;YACrC,OAAO,CAAC,CAAC,OAAO,CAAC,CAAC;QACpB,CAAC;IACH,CAAC;IAED,8CAA8C;IAC9C,IAAW,MAAM,KAAa,OAAO,WAAW,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,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AE,GAAG,CAAC;IACN,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,KAAK,CAAC;QAC7B,GAAG,GAAG,GAAG,GAAG,GAAG,IAAI,CAAC,CAAC;IAEvB,OAAO,GAAG,GAAG,CAAC,CAAC;AACjB,CAAC;AAED;;;GAGG;AACH,MAAM,CAAN,IAAY,iBASX;AATD,WAAY,iBAAiB;IAC3B,kDAAkD;IAClD,yDAAQ,CAAA;IACR,iDAAiD;IACjD,uDAAO,CAAA;IACP;;OAEG;IACH,uDAAO,CAAA;AACT,CAAC,EATW,iBAAiB,KAAjB,iBAAiB,QAS5B;AAED;;GAEG;AACH,MAAM,UAAU,wBAAwB,CAAC,MAAc;IACrD,QAAQ,MAAM,EAAE,CAAC;QACf,KAAK,iBAAiB,CAAC,IAAI,CAAC;QAC5B,KAAK,iBAAiB,CAAC,GAAG,CAAC;QAC3B,KAAK,iBAAiB,CAAC,GAAG;YACxB,OAAO,IAAI,CAAC;QACd;YACE,OAAO,KAAK,CAAC;IACjB,CAAC;AACH,CAAC;AAED;;GAEG;AACH,MAAM,OAAO,WAAW;IACtB,2CAA2C;IAC3B,IAAI,CAAsB;IAC1C,4BAA4B;IACZ,MAAM,CAAoB;IAE1C,4EAA4E;IAC5E,YAAmB,IAAyB,EAAE,MAAyB;QACrE,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QACjB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;IACvB,CAAC;CACF;AAcD;;GAEG;AACH,MAAM,UAAU,mBAAmB,CAAC,MAAmB;IACrD,OAAO,MAAM,CAAC,MAAM,KAAK,iBAAiB,CAAC,GAAG,IAAI,MAAM,CAAC,IAAI,YAAY,UAAU,CAAC;AACtF,CAAC","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 Rendering\n */\n\n/** Format of an [[ImageBuffer]].\n * The format determines how many bytes are allocated for each pixel in the buffer and the semantics of each byte.\n * @see [[ImageBuffer.getNumBytesPerPixel]]\n * @public\n * @extensions\n */\nexport enum ImageBufferFormat {\n /** RGBA format - 4 bytes per pixel. */\n Rgba = 0,\n /** RGB format - 3 bytes per pixel. */\n Rgb = 2,\n /** 1 byte per pixel. */\n Alpha = 5,\n}\n\n/** Uncompressed rectangular bitmap image data.\n * @public\n */\nexport class ImageBuffer {\n /** Image data in which each pixel occupies 1 or more bytes depending of the [[ImageBufferFormat]]. */\n public readonly data: Uint8Array;\n /** Format of the bytes in the image. */\n public readonly format: ImageBufferFormat;\n /** Width of image in pixels */\n public readonly width: number;\n\n /** Return the number of bytes allocated for each pixel. */\n public get numBytesPerPixel(): number { return ImageBuffer.getNumBytesPerPixel(this.format); }\n\n /** Determine the number of bytes allocated to a single pixel for the specified format. */\n public static getNumBytesPerPixel(format: ImageBufferFormat): number {\n switch (format) {\n case ImageBufferFormat.Alpha: return 1;\n case ImageBufferFormat.Rgb: return 3;\n default: return 4;\n }\n }\n\n /** Get the height of this image in pixels. */\n public get height(): number { return ImageBuffer.computeHeight(this.data, this.format, this.width); }\n\n /** Create a new ImageBuffer.\n * @note The ImageBuffer takes ownership of the input Uint8Array.\n * @param data The uncompressed image bytes. Must be a multiple of the width times the number of bytes per pixel specified by the format.\n * @param format The format of the image.\n * @param width The width of the image in pixels.\n * @returns A new ImageBuffer.\n * @throws Error if the length of the Uint8Array is not appropriate for the specified width and format.\n */\n public static create(data: Uint8Array, format: ImageBufferFormat, width: number): ImageBuffer {\n if (!this.isValidData(data, format, width))\n throw new Error(\"The number of bytes supplied for ImageBuffer do not match its width and format.\");\n\n return new ImageBuffer(data, format, width);\n }\n\n private static isValidData(data: Uint8Array, format: ImageBufferFormat, width: number): boolean {\n const height = this.computeHeight(data, format, width);\n return width > 0 && height > 0 && Math.floor(width) === width && Math.floor(height) === height;\n }\n\n private static computeHeight(data: Uint8Array, format: ImageBufferFormat, width: number): number {\n return data.length / (width * this.getNumBytesPerPixel(format));\n }\n\n private constructor(data: Uint8Array, format: ImageBufferFormat, width: number) {\n this.data = data;\n this.format = format;\n this.width = width;\n }\n}\n\n/** Returns whether the input is a power of two.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function isPowerOfTwo(num: number): boolean {\n return 0 === (num & (num - 1));\n}\n\n/** Returns the first power-of-two value greater than or equal to the input.\n * @note Floating point inputs are truncated.\n * @public\n */\nexport function nextHighestPowerOfTwo(num: number): number {\n --num;\n for (let i = 1; i < 32; i <<= 1)\n num = num | num >> i;\n\n return num + 1;\n}\n\n/** The format of an ImageSource.\n * @public\n * @extensions\n */\nexport enum ImageSourceFormat {\n /** Image data is stored with JPEG compression. */\n Jpeg = 0,\n /** Image data is stored with PNG compression. */\n Png = 2,\n /** Image is stored as an Svg stream.\n * @note SVG is only valid for ImageSources in JavaScript. It *may not* be used for persistent textures.\n */\n Svg = 3,\n}\n\n/** Returns true if the numeric `format` value is a valid member of the [[ImageSourceFormat]] enumeration.\n * @public\n */\nexport function isValidImageSourceFormat(format: number): format is ImageSourceFormat {\n switch (format) {\n case ImageSourceFormat.Jpeg:\n case ImageSourceFormat.Png:\n case ImageSourceFormat.Svg:\n return true;\n default:\n return false;\n }\n}\n\n/** Image data encoded and compressed in either Jpeg or Png format.\n * @public\n */\nexport class ImageSource {\n /** The content of the image, compressed */\n public readonly data: Uint8Array | string;\n /** The compression type. */\n public readonly format: ImageSourceFormat;\n\n /** Construct a new ImageSource, which takes ownership of the Uint8Array. */\n public constructor(data: Uint8Array | string, format: ImageSourceFormat) {\n this.data = data;\n this.format = format;\n }\n}\n\n/** An [[ImageSource]] encoded in binary form as a Jpeg or Png, as opposed to one encoded\n * in string format as an Svg.\n * Only binary ImageSources can be used for [[Texture]]s stored in [[IModelDb]]s.\n * @public\n */\nexport interface BinaryImageSource {\n /** The format in which the [[data]] is encoded. */\n readonly format: ImageSourceFormat.Jpeg | ImageSourceFormat.Png;\n /** The image data encoded according to [[format]]. */\n readonly data: Uint8Array;\n}\n\n/** Returns true if `source` is a [[BinaryImageSource]].\n * @public\n */\nexport function isBinaryImageSource(source: ImageSource): source is BinaryImageSource {\n return source.format !== ImageSourceFormat.Svg && source.data instanceof Uint8Array;\n}\n"]}
|
|
@@ -25,6 +25,7 @@ export interface MassPropertiesRequestProps {
|
|
|
25
25
|
}
|
|
26
26
|
/** Information required to request mass properties for each element separately from the front end to the back end.
|
|
27
27
|
* @public
|
|
28
|
+
* @deprecated in 4.11. Use [[MassPropertiesRequestProps]].
|
|
28
29
|
*/
|
|
29
30
|
export interface MassPropertiesPerCandidateRequestProps {
|
|
30
31
|
operations: MassPropertiesOperation[];
|
|
@@ -58,6 +59,7 @@ export interface MassPropertiesResponseProps {
|
|
|
58
59
|
}
|
|
59
60
|
/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.
|
|
60
61
|
* @public
|
|
62
|
+
* @deprecated in 4.11. Use [[MassPropertiesResponseProps]].
|
|
61
63
|
*/
|
|
62
64
|
export interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {
|
|
63
65
|
candidate: Id64String;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MassProperties.d.ts","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":"AAIA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAC9F,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAEhD;;;GAGG;AACH,oBAAY,uBAAuB;IACjC,wDAAwD;IACxD,iBAAiB,IAAI;IACrB,kEAAkE;IAClE,eAAe,IAAI;IACnB,mDAAmD;IACnD,iBAAiB,IAAI;CACtB;AAED;;;GAGG;AACH,MAAM,WAAW,0BAA0B;IACzC,SAAS,EAAE,uBAAuB,CAAC;IACnC,UAAU,CAAC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AQ,2BAA2B;IAC1F,SAAS,EAAE,UAAU,CAAC;CACvB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MassProperties.js","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAKH;;;GAGG;AACH,MAAM,CAAN,IAAY,uBAOX;AAPD,WAAY,uBAAuB;IACjC,wDAAwD;IACxD,+FAAqB,CAAA;IACrB,kEAAkE;IAClE,2FAAmB,CAAA;IACnB,mDAAmD;IACnD,+FAAqB,CAAA;AACvB,CAAC,EAPW,uBAAuB,KAAvB,uBAAuB,QAOlC","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 Geometry\n */\n\nimport { BentleyStatus, CompressedId64Set, Id64Array, Id64String } from \"@itwin/core-bentley\";\nimport { XYZProps } from \"@itwin/core-geometry\";\n\n/** Specify whether to accumulate volumes, areas, or lengths for the supplied elements.\n * @public\n * @extensions\n */\nexport enum MassPropertiesOperation {\n /** Return lengths for open paths and planar regions. */\n AccumulateLengths = 0,\n /** Return areas and perimeters for solid and surface geometry. */\n AccumulateAreas = 1,\n /** Return volumes and areas for solid geometry. */\n AccumulateVolumes = 2,\n}\n\n/** Information required to request mass properties for elements from the front end to the back end.\n * @public\n * @extensions\n */\nexport interface MassPropertiesRequestProps {\n operation: MassPropertiesOperation;\n candidates?: Id64Array;\n}\n\n/** Information required to request mass properties for each element separately from the front end to the back end.\n * @public\n */\nexport interface MassPropertiesPerCandidateRequestProps {\n operations: MassPropertiesOperation[];\n candidates: CompressedId64Set;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation.\n * @public\n * @extensions\n */\nexport interface MassPropertiesResponseProps {\n /** Success if requested [[MassPropertiesOperation]] could be evaluated for the specified elements */\n status: BentleyStatus;\n /** Volume of solids when [[MassPropertiesOperation.AccumulateVolumes]] requested */\n volume?: number;\n /** Surface area of solids and surfaces when [[MassPropertiesOperation.AccumulateVolumes]] or [[MassPropertiesOperation.AccumulateAreas]] requested */\n area?: number;\n /** Perimeter of surfaces and planar regions when [[MassPropertiesOperation.AccumulateAreas]] requested */\n perimeter?: number;\n /** Length of curves or perimeter of planar regions when [[MassPropertiesOperation.AccumulateAreas]] or [[MassPropertiesOperation.AccumulateLength]] requested */\n length?: number;\n /** Centroid of geometry */\n centroid?: XYZProps;\n /** Product of inertia with respect to xy plane */\n ixy?: number;\n /** Product of inertia with respect to xz plane */\n ixz?: number;\n /** Product of inertia with respect to yz plane */\n iyz?: number;\n /** Moments of inertia */\n moments?: XYZProps;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.\n * @public\n */\nexport interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {\n candidate: Id64String;\n}\n"]}
|
|
1
|
+
{"version":3,"file":"MassProperties.js","sourceRoot":"","sources":["../../src/MassProperties.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;AAKH;;;GAGG;AACH,MAAM,CAAN,IAAY,uBAOX;AAPD,WAAY,uBAAuB;IACjC,wDAAwD;IACxD,+FAAqB,CAAA;IACrB,kEAAkE;IAClE,2FAAmB,CAAA;IACnB,mDAAmD;IACnD,+FAAqB,CAAA;AACvB,CAAC,EAPW,uBAAuB,KAAvB,uBAAuB,QAOlC","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 Geometry\n */\n\nimport { BentleyStatus, CompressedId64Set, Id64Array, Id64String } from \"@itwin/core-bentley\";\nimport { XYZProps } from \"@itwin/core-geometry\";\n\n/** Specify whether to accumulate volumes, areas, or lengths for the supplied elements.\n * @public\n * @extensions\n */\nexport enum MassPropertiesOperation {\n /** Return lengths for open paths and planar regions. */\n AccumulateLengths = 0,\n /** Return areas and perimeters for solid and surface geometry. */\n AccumulateAreas = 1,\n /** Return volumes and areas for solid geometry. */\n AccumulateVolumes = 2,\n}\n\n/** Information required to request mass properties for elements from the front end to the back end.\n * @public\n * @extensions\n */\nexport interface MassPropertiesRequestProps {\n operation: MassPropertiesOperation;\n candidates?: Id64Array;\n}\n\n/** Information required to request mass properties for each element separately from the front end to the back end.\n * @public\n * @deprecated in 4.11. Use [[MassPropertiesRequestProps]].\n */\nexport interface MassPropertiesPerCandidateRequestProps {\n operations: MassPropertiesOperation[];\n candidates: CompressedId64Set;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation.\n * @public\n * @extensions\n */\nexport interface MassPropertiesResponseProps {\n /** Success if requested [[MassPropertiesOperation]] could be evaluated for the specified elements */\n status: BentleyStatus;\n /** Volume of solids when [[MassPropertiesOperation.AccumulateVolumes]] requested */\n volume?: number;\n /** Surface area of solids and surfaces when [[MassPropertiesOperation.AccumulateVolumes]] or [[MassPropertiesOperation.AccumulateAreas]] requested */\n area?: number;\n /** Perimeter of surfaces and planar regions when [[MassPropertiesOperation.AccumulateAreas]] requested */\n perimeter?: number;\n /** Length of curves or perimeter of planar regions when [[MassPropertiesOperation.AccumulateAreas]] or [[MassPropertiesOperation.AccumulateLength]] requested */\n length?: number;\n /** Centroid of geometry */\n centroid?: XYZProps;\n /** Product of inertia with respect to xy plane */\n ixy?: number;\n /** Product of inertia with respect to xz plane */\n ixz?: number;\n /** Product of inertia with respect to yz plane */\n iyz?: number;\n /** Moments of inertia */\n moments?: XYZProps;\n}\n\n/** Information returned from the back end to the front end holding the result of the mass properties calculation for a single candidate.\n * @public\n * @deprecated in 4.11. Use [[MassPropertiesResponseProps]].\n */\nexport interface MassPropertiesPerCandidateResponseProps extends MassPropertiesResponseProps {\n candidate: Id64String;\n}\n"]}
|
|
@@ -68,7 +68,7 @@ export class IModelReadRpcInterface extends RpcInterface {
|
|
|
68
68
|
async cancelSnap(_iModelToken, _sessionId) { return this.forward(arguments); }
|
|
69
69
|
async getGeometryContainment(_iModelToken, _props) { return this.forward(arguments); }
|
|
70
70
|
async getMassProperties(_iModelToken, _props) { return this.forward(arguments); }
|
|
71
|
-
async getMassPropertiesPerCandidate(_iModelToken, _props) { return this.forward(arguments); }
|
|
71
|
+
async getMassPropertiesPerCandidate(_iModelToken, _props) { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated
|
|
72
72
|
async getIModelCoordinatesFromGeoCoordinates(_iModelToken, _props) { return this.forward(arguments); }
|
|
73
73
|
async getGeoCoordinatesFromIModelCoordinates(_iModelToken, _props) { return this.forward(arguments); }
|
|
74
74
|
async getGeometrySummary(_iModelToken, _props) { return this.forward(arguments); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IModelReadRpcInterface.js","sourceRoot":"","sources":["../../../src/rpc/IModelReadRpcInterface.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;;;;;;;AAoBH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAO3C,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAGnD;;;GAGG;AACH,MAAM,OAAO,sBAAuB,SAAQ,mBAAmB;IACtD,wBAAwB,GAAY,IAAI,CAAC;IAChC,OAAO,GAAG,kBAAkB,CAAC;CAC9C;AAwBD;;;;GAIG;AACH,MAAM,OAAgB,sBAAuB,SAAQ,YAAY;IAC/D,oEAAoE;IAC7D,MAAM,CAAC,SAAS,KAA6B,OAAO,UAAU,CAAC,qBAAqB,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC;IAEtH,0FAA0F;IAC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,CAAC,SAAS,CAAC;8DAC6G;AAMrK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC+C;AAEvG;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;sEAC8G;AAEtK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC0G;AAQlK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;oFAC0H","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 RpcInterface\n */\n\nimport { CompressedId64Set, GuidString, Id64String, IModelStatus } from \"@itwin/core-bentley\";\nimport { Range3dProps } from \"@itwin/core-geometry\";\nimport { CodeProps } from \"../Code\";\nimport { DbBlobRequest, DbBlobResponse, DbQueryRequest, DbQueryResponse } from \"../ConcurrentQuery\";\nimport { ElementMeshRequestProps } from \"../ElementMesh\";\nimport { ElementLoadOptions, ElementProps } from \"../ElementProps\";\nimport { EntityQueryParams } from \"../EntityProps\";\nimport { FontMapProps } from \"../Fonts\";\nimport {\n GeoCoordinatesRequestProps, GeoCoordinatesResponseProps, IModelCoordinatesRequestProps, IModelCoordinatesResponseProps,\n} from \"../GeoCoordinateServices\";\nimport { GeometryContainmentRequestProps, GeometryContainmentResponseProps } from \"../GeometryContainment\";\nimport { GeometrySummaryRequestProps } from \"../GeometrySummary\";\nimport { IModelConnectionProps, IModelRpcOpenProps, IModelRpcProps } from \"../IModel\";\nimport {\n MassPropertiesPerCandidateRequestProps, MassPropertiesPerCandidateResponseProps, MassPropertiesRequestProps, MassPropertiesResponseProps,\n} from \"../MassProperties\";\nimport { ModelProps } from \"../ModelProps\";\nimport { RpcInterface } from \"../RpcInterface\";\nimport { RpcManager } from \"../RpcManager\";\nimport { SnapRequestProps, SnapResponseProps } from \"../internal/Snapping\";\nimport { TextureData, TextureLoadProps } from \"../TextureProps\";\nimport {\n CustomViewState3dCreatorOptions, CustomViewState3dProps, HydrateViewStateRequestProps, HydrateViewStateResponseProps, SubCategoryResultRow,\n ViewStateLoadProps, ViewStateProps,\n} from \"../ViewProps\";\nimport { RpcResponseCacheControl } from \"./core/RpcConstants\";\nimport { RpcNotFoundResponse } from \"./core/RpcControl\";\nimport { RpcOperation } from \"./core/RpcOperation\";\nimport { RpcRoutingToken } from \"./core/RpcRoutingToken\";\n\n/** Response if the IModelDb was not found at the backend\n * (if the service has moved)\n * @public\n */\nexport class IModelNotFoundResponse extends RpcNotFoundResponse {\n public isIModelNotFoundResponse: boolean = true;\n public override message = \"iModel not found\";\n}\n\n/** Describes the volume of geometry contained with a [GeometricModel]($backend) as returned by\n * [IModelConnection.Models.queryExtents]($frontend) and [IModelDb.Models.queryExtents]($backend).\n * @public\n */\nexport interface ModelExtentsProps {\n /** The Id of the model, or [Id64.invalid]($bentley) if the input model Id was not a well-formed [Id64String]($bentley). */\n id: Id64String;\n /** The volume of geometry contained within the model.\n * This range will be null (@see [Range3d.isNull]($geometry)) if [[status]] is not [IModelStatus.Success]($bentley) or the model contains no geometry.\n */\n extents: Range3dProps;\n /** A status code indicating what if any error occurred obtaining the model's extents. For example:\n * - [IModelStatus.InvalidId]($bentley) if the input model Id was not a well-formed [Id64String]($bentley);\n * - [IModelStatus.NotFound]($bentley) if no model with the specified Id exists in the [[IModel]];\n * - [IModelStatus.WrongModel]($bentley) if the specified model is not a [GeometricModel]($backend); or\n * - [IModelStatus.Success]($bentley) if the extents were successfully obtained.\n *\n * If `status` is anything other than [IModelStatus.Success]($bentley), [[extents]] will be a null range.\n */\n status: IModelStatus;\n}\n\n/** The RPC interface for reading from an iModel.\n * All operations only require read-only access.\n * This interface is not normally used directly. See IModelConnection for higher-level and more convenient API for accessing iModels from a frontend.\n * @internal\n */\nexport abstract class IModelReadRpcInterface extends RpcInterface {\n /** Returns the IModelReadRpcInterface instance for the frontend. */\n public static getClient(): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface); }\n\n /** Returns the IModelReadRpcInterface instance for a custom RPC routing configuration. */\n public static getClientForRouting(token: RpcRoutingToken): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface, token); }\n\n /** The immutable name of the interface. */\n public static readonly interfaceName = \"IModelReadRpcInterface\";\n\n /** The semantic version of the interface. */\n public static interfaceVersion = \"3.7.0\";\n\n /*===========================================================================================\n NOTE: Any add/remove/change to the methods below requires an update of the interface version.\n NOTE: Please consult the README in this folder for the semantic versioning rules.\n ===========================================================================================*/\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getConnectionProps(_iModelToken: IModelRpcOpenProps): Promise<IModelConnectionProps> { return this.forward(arguments); }\n public async queryRows(_iModelToken: IModelRpcProps, _request: DbQueryRequest): Promise<DbQueryResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async querySubCategories(_iModelToken: IModelRpcProps, _categoryIds: CompressedId64Set): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryAllUsedSpatialSubCategories(_iModelToken: IModelRpcProps): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n public async queryBlob(_iModelToken: IModelRpcProps, _request: DbBlobRequest): Promise<DbBlobResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getModelProps(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelRanges(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<Range3dProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelExtents(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelExtentsProps[]> { return this.forward(arguments); }\n public async queryModelProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ModelProps[]> { return this.forward(arguments); }\n public async getElementProps(_iModelToken: IModelRpcProps, _elementIds: Id64String[]): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryElementProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryEntityIds(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<Id64String[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getClassHierarchy(_iModelToken: IModelRpcProps, _startClassName: string): Promise<string[]> { return this.forward(arguments); }\n public async getAllCodeSpecs(_iModelToken: IModelRpcProps): Promise<any[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getViewStateData(_iModelToken: IModelRpcProps, _viewDefinitionId: string, _options?: ViewStateLoadProps): Promise<ViewStateProps> { return this.forward(arguments); }\n public async readFontJson(_iModelToken: IModelRpcProps): Promise<FontMapProps> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getToolTipMessage(_iModelToken: IModelRpcProps, _elementId: string): Promise<string[]> { return this.forward(arguments); }\n /** @deprecated in 3.x use ViewStore apis. */\n public async getViewThumbnail(_iModelToken: IModelRpcProps, _viewId: string): Promise<Uint8Array> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getDefaultViewId(_iModelToken: IModelRpcProps): Promise<Id64String> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getCustomViewState3dData(_iModelToken: IModelRpcProps, _options: CustomViewState3dCreatorOptions): Promise<CustomViewState3dProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async hydrateViewState(_iModelToken: IModelRpcProps, _options: HydrateViewStateRequestProps): Promise<HydrateViewStateResponseProps> { return this.forward(arguments); }\n public async requestSnap(_iModelToken: IModelRpcProps, _sessionId: string, _props: SnapRequestProps): Promise<SnapResponseProps> { return this.forward(arguments); }\n public async cancelSnap(_iModelToken: IModelRpcProps, _sessionId: string): Promise<void> { return this.forward(arguments); }\n public async getGeometryContainment(_iModelToken: IModelRpcProps, _props: GeometryContainmentRequestProps): Promise<GeometryContainmentResponseProps> { return this.forward(arguments); }\n public async getMassProperties(_iModelToken: IModelRpcProps, _props: MassPropertiesRequestProps): Promise<MassPropertiesResponseProps> { return this.forward(arguments); }\n public async getMassPropertiesPerCandidate(_iModelToken: IModelRpcProps, _props: MassPropertiesPerCandidateRequestProps): Promise<MassPropertiesPerCandidateResponseProps[]> { return this.forward(arguments); }\n public async getIModelCoordinatesFromGeoCoordinates(_iModelToken: IModelRpcProps, _props: IModelCoordinatesRequestProps): Promise<IModelCoordinatesResponseProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getGeoCoordinatesFromIModelCoordinates(_iModelToken: IModelRpcProps, _props: GeoCoordinatesRequestProps): Promise<GeoCoordinatesResponseProps> { return this.forward(arguments); }\n public async getGeometrySummary(_iModelToken: IModelRpcProps, _props: GeometrySummaryRequestProps): Promise<string> { return this.forward(arguments); }\n public async queryTextureData(_iModelToken: IModelRpcProps, _textureLoadProps: TextureLoadProps): Promise<TextureData | undefined> { return this.forward(arguments); }\n public async loadElementProps(_iModelToken: IModelRpcProps, _elementIdentifier: Id64String | GuidString | CodeProps, _options?: ElementLoadOptions): Promise<ElementProps | undefined> {\n return this.forward(arguments);\n }\n public async generateElementMeshes(_iModelToken: IModelRpcProps, _props: ElementMeshRequestProps): Promise<Uint8Array> {\n return this.forward(arguments);\n }\n /** @internal */\n public async callViewStore(_iModelToken: IModelRpcProps, _version: string, _forWrite: boolean, _methodName: string, ..._args: any[]): Promise<any> { return this.forward(arguments); }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"IModelReadRpcInterface.js","sourceRoot":"","sources":["../../../src/rpc/IModelReadRpcInterface.ts"],"names":[],"mappings":"AAAA;;;+FAG+F;AAC/F;;GAEG;;;;;;;AAoBH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAO3C,OAAO,EAAE,uBAAuB,EAAE,MAAM,qBAAqB,CAAC;AAC9D,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAGnD;;;GAGG;AACH,MAAM,OAAO,sBAAuB,SAAQ,mBAAmB;IACtD,wBAAwB,GAAY,IAAI,CAAC;IAChC,OAAO,GAAG,kBAAkB,CAAC;CAC9C;AAwBD;;;;GAIG;AACH,MAAM,OAAgB,sBAAuB,SAAQ,YAAY;IAC/D,oEAAoE;IAC7D,MAAM,CAAC,SAAS,KAA6B,OAAO,UAAU,CAAC,qBAAqB,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC;IAEtH,0FAA0F;IACnF,MAAM,CAAC,mBAAmB,CAAC,KAAsB,IAA4B,OAAO,UAAU,CAAC,qBAAqB,CAAC,sBAAsB,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC;IAE7J,2CAA2C;IACpC,MAAM,CAAU,aAAa,GAAG,wBAAwB,CAAC;IAEhE,6CAA6C;IACtC,MAAM,CAAC,gBAAgB,GAAG,OAAO,CAAC;IAEzC;;;iGAG6F;IAEhF,AAAN,KAAK,CAAC,kBAAkB,CAAC,YAAgC,IAAoC,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;IAC9H,KAAK,CAAC,SAAS,CAAC,YAA4B,EAAE,QAAwB,IAA8B,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CA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AC;IACjC,CAAC;IACD,gBAAgB;IACT,KAAK,CAAC,aAAa,CAAC,YAA4B,EAAE,QAAgB,EAAE,SAAkB,EAAE,WAAmB,EAAE,GAAG,KAAY,IAAkB,OAAO,IAAI,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;;AAjDzK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;gEACgE;AAGxH;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;gEAC8F;AAEtJ;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8EAC2E;AAGnI;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;2DACuE;AAE/H;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC4E;AAEpI;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;+DACkF;AAM1I;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;+DACuE;AAG/H;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC6G;AAMrK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC+C;AAEvG;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;sEAC8G;AAEtK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;8DAC0G;AAQlK;IADZ,YAAY,CAAC,oBAAoB,CAAC,uBAAuB,CAAC,SAAS,CAAC;oFAC0H","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 RpcInterface\n */\n\nimport { CompressedId64Set, GuidString, Id64String, IModelStatus } from \"@itwin/core-bentley\";\nimport { Range3dProps } from \"@itwin/core-geometry\";\nimport { CodeProps } from \"../Code\";\nimport { DbBlobRequest, DbBlobResponse, DbQueryRequest, DbQueryResponse } from \"../ConcurrentQuery\";\nimport { ElementMeshRequestProps } from \"../ElementMesh\";\nimport { ElementLoadOptions, ElementProps } from \"../ElementProps\";\nimport { EntityQueryParams } from \"../EntityProps\";\nimport { FontMapProps } from \"../Fonts\";\nimport {\n GeoCoordinatesRequestProps, GeoCoordinatesResponseProps, IModelCoordinatesRequestProps, IModelCoordinatesResponseProps,\n} from \"../GeoCoordinateServices\";\nimport { GeometryContainmentRequestProps, GeometryContainmentResponseProps } from \"../GeometryContainment\";\nimport { GeometrySummaryRequestProps } from \"../GeometrySummary\";\nimport { IModelConnectionProps, IModelRpcOpenProps, IModelRpcProps } from \"../IModel\";\nimport {\n MassPropertiesPerCandidateRequestProps, MassPropertiesPerCandidateResponseProps, MassPropertiesRequestProps, MassPropertiesResponseProps,\n} from \"../MassProperties\";\nimport { ModelProps } from \"../ModelProps\";\nimport { RpcInterface } from \"../RpcInterface\";\nimport { RpcManager } from \"../RpcManager\";\nimport { SnapRequestProps, SnapResponseProps } from \"../internal/Snapping\";\nimport { TextureData, TextureLoadProps } from \"../TextureProps\";\nimport {\n CustomViewState3dCreatorOptions, CustomViewState3dProps, HydrateViewStateRequestProps, HydrateViewStateResponseProps, SubCategoryResultRow,\n ViewStateLoadProps, ViewStateProps,\n} from \"../ViewProps\";\nimport { RpcResponseCacheControl } from \"./core/RpcConstants\";\nimport { RpcNotFoundResponse } from \"./core/RpcControl\";\nimport { RpcOperation } from \"./core/RpcOperation\";\nimport { RpcRoutingToken } from \"./core/RpcRoutingToken\";\n\n/** Response if the IModelDb was not found at the backend\n * (if the service has moved)\n * @public\n */\nexport class IModelNotFoundResponse extends RpcNotFoundResponse {\n public isIModelNotFoundResponse: boolean = true;\n public override message = \"iModel not found\";\n}\n\n/** Describes the volume of geometry contained with a [GeometricModel]($backend) as returned by\n * [IModelConnection.Models.queryExtents]($frontend) and [IModelDb.Models.queryExtents]($backend).\n * @public\n */\nexport interface ModelExtentsProps {\n /** The Id of the model, or [Id64.invalid]($bentley) if the input model Id was not a well-formed [Id64String]($bentley). */\n id: Id64String;\n /** The volume of geometry contained within the model.\n * This range will be null (@see [Range3d.isNull]($geometry)) if [[status]] is not [IModelStatus.Success]($bentley) or the model contains no geometry.\n */\n extents: Range3dProps;\n /** A status code indicating what if any error occurred obtaining the model's extents. For example:\n * - [IModelStatus.InvalidId]($bentley) if the input model Id was not a well-formed [Id64String]($bentley);\n * - [IModelStatus.NotFound]($bentley) if no model with the specified Id exists in the [[IModel]];\n * - [IModelStatus.WrongModel]($bentley) if the specified model is not a [GeometricModel]($backend); or\n * - [IModelStatus.Success]($bentley) if the extents were successfully obtained.\n *\n * If `status` is anything other than [IModelStatus.Success]($bentley), [[extents]] will be a null range.\n */\n status: IModelStatus;\n}\n\n/** The RPC interface for reading from an iModel.\n * All operations only require read-only access.\n * This interface is not normally used directly. See IModelConnection for higher-level and more convenient API for accessing iModels from a frontend.\n * @internal\n */\nexport abstract class IModelReadRpcInterface extends RpcInterface {\n /** Returns the IModelReadRpcInterface instance for the frontend. */\n public static getClient(): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface); }\n\n /** Returns the IModelReadRpcInterface instance for a custom RPC routing configuration. */\n public static getClientForRouting(token: RpcRoutingToken): IModelReadRpcInterface { return RpcManager.getClientForInterface(IModelReadRpcInterface, token); }\n\n /** The immutable name of the interface. */\n public static readonly interfaceName = \"IModelReadRpcInterface\";\n\n /** The semantic version of the interface. */\n public static interfaceVersion = \"3.7.0\";\n\n /*===========================================================================================\n NOTE: Any add/remove/change to the methods below requires an update of the interface version.\n NOTE: Please consult the README in this folder for the semantic versioning rules.\n ===========================================================================================*/\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getConnectionProps(_iModelToken: IModelRpcOpenProps): Promise<IModelConnectionProps> { return this.forward(arguments); }\n public async queryRows(_iModelToken: IModelRpcProps, _request: DbQueryRequest): Promise<DbQueryResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async querySubCategories(_iModelToken: IModelRpcProps, _categoryIds: CompressedId64Set): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryAllUsedSpatialSubCategories(_iModelToken: IModelRpcProps): Promise<SubCategoryResultRow[]> { return this.forward(arguments); }\n public async queryBlob(_iModelToken: IModelRpcProps, _request: DbBlobRequest): Promise<DbBlobResponse> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getModelProps(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelRanges(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<Range3dProps[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async queryModelExtents(_iModelToken: IModelRpcProps, _modelIds: Id64String[]): Promise<ModelExtentsProps[]> { return this.forward(arguments); }\n public async queryModelProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ModelProps[]> { return this.forward(arguments); }\n public async getElementProps(_iModelToken: IModelRpcProps, _elementIds: Id64String[]): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryElementProps(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<ElementProps[]> { return this.forward(arguments); }\n public async queryEntityIds(_iModelToken: IModelRpcProps, _params: EntityQueryParams): Promise<Id64String[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getClassHierarchy(_iModelToken: IModelRpcProps, _startClassName: string): Promise<string[]> { return this.forward(arguments); }\n public async getAllCodeSpecs(_iModelToken: IModelRpcProps): Promise<any[]> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getViewStateData(_iModelToken: IModelRpcProps, _viewDefinitionId: string, _options?: ViewStateLoadProps): Promise<ViewStateProps> { return this.forward(arguments); }\n public async readFontJson(_iModelToken: IModelRpcProps): Promise<FontMapProps> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getToolTipMessage(_iModelToken: IModelRpcProps, _elementId: string): Promise<string[]> { return this.forward(arguments); }\n /** @deprecated in 3.x use ViewStore apis. */\n public async getViewThumbnail(_iModelToken: IModelRpcProps, _viewId: string): Promise<Uint8Array> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getDefaultViewId(_iModelToken: IModelRpcProps): Promise<Id64String> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getCustomViewState3dData(_iModelToken: IModelRpcProps, _options: CustomViewState3dCreatorOptions): Promise<CustomViewState3dProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async hydrateViewState(_iModelToken: IModelRpcProps, _options: HydrateViewStateRequestProps): Promise<HydrateViewStateResponseProps> { return this.forward(arguments); }\n public async requestSnap(_iModelToken: IModelRpcProps, _sessionId: string, _props: SnapRequestProps): Promise<SnapResponseProps> { return this.forward(arguments); }\n public async cancelSnap(_iModelToken: IModelRpcProps, _sessionId: string): Promise<void> { return this.forward(arguments); }\n public async getGeometryContainment(_iModelToken: IModelRpcProps, _props: GeometryContainmentRequestProps): Promise<GeometryContainmentResponseProps> { return this.forward(arguments); }\n public async getMassProperties(_iModelToken: IModelRpcProps, _props: MassPropertiesRequestProps): Promise<MassPropertiesResponseProps> { return this.forward(arguments); }\n public async getMassPropertiesPerCandidate(_iModelToken: IModelRpcProps, _props: MassPropertiesPerCandidateRequestProps): Promise<MassPropertiesPerCandidateResponseProps[]> { return this.forward(arguments); } // eslint-disable-line @typescript-eslint/no-deprecated\n public async getIModelCoordinatesFromGeoCoordinates(_iModelToken: IModelRpcProps, _props: IModelCoordinatesRequestProps): Promise<IModelCoordinatesResponseProps> { return this.forward(arguments); }\n @RpcOperation.allowResponseCaching(RpcResponseCacheControl.Immutable)\n public async getGeoCoordinatesFromIModelCoordinates(_iModelToken: IModelRpcProps, _props: GeoCoordinatesRequestProps): Promise<GeoCoordinatesResponseProps> { return this.forward(arguments); }\n public async getGeometrySummary(_iModelToken: IModelRpcProps, _props: GeometrySummaryRequestProps): Promise<string> { return this.forward(arguments); }\n public async queryTextureData(_iModelToken: IModelRpcProps, _textureLoadProps: TextureLoadProps): Promise<TextureData | undefined> { return this.forward(arguments); }\n public async loadElementProps(_iModelToken: IModelRpcProps, _elementIdentifier: Id64String | GuidString | CodeProps, _options?: ElementLoadOptions): Promise<ElementProps | undefined> {\n return this.forward(arguments);\n }\n public async generateElementMeshes(_iModelToken: IModelRpcProps, _props: ElementMeshRequestProps): Promise<Uint8Array> {\n return this.forward(arguments);\n }\n /** @internal */\n public async callViewStore(_iModelToken: IModelRpcProps, _version: string, _forWrite: boolean, _methodName: string, ..._args: any[]): Promise<any> { return this.forward(arguments); }\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@itwin/core-common",
|
|
3
|
-
"version": "5.0.0-dev.
|
|
3
|
+
"version": "5.0.0-dev.67",
|
|
4
4
|
"description": "iTwin.js components common to frontend and backend",
|
|
5
5
|
"main": "lib/cjs/core-common.js",
|
|
6
6
|
"module": "lib/esm/core-common.js",
|
|
@@ -27,8 +27,8 @@
|
|
|
27
27
|
"js-base64": "^3.6.1"
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|
|
30
|
-
"@itwin/core-bentley": "5.0.0-dev.
|
|
31
|
-
"@itwin/core-geometry": "5.0.0-dev.
|
|
30
|
+
"@itwin/core-bentley": "5.0.0-dev.67",
|
|
31
|
+
"@itwin/core-geometry": "5.0.0-dev.67"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@itwin/eslint-plugin": "5.0.0-dev.1",
|
|
@@ -42,9 +42,9 @@
|
|
|
42
42
|
"rimraf": "^3.0.2",
|
|
43
43
|
"typescript": "~5.6.2",
|
|
44
44
|
"vitest": "^3.0.5",
|
|
45
|
-
"@itwin/build-tools": "5.0.0-dev.
|
|
46
|
-
"@itwin/core-bentley": "5.0.0-dev.
|
|
47
|
-
"@itwin/core-geometry": "5.0.0-dev.
|
|
45
|
+
"@itwin/build-tools": "5.0.0-dev.67",
|
|
46
|
+
"@itwin/core-bentley": "5.0.0-dev.67",
|
|
47
|
+
"@itwin/core-geometry": "5.0.0-dev.67"
|
|
48
48
|
},
|
|
49
49
|
"nyc": {
|
|
50
50
|
"extends": "./node_modules/@itwin/build-tools/.nycrc",
|