UNPKG

trimble-connect-workspace-api

Version:

Trimble Connect Workspace API

728 lines (727 loc) 32.2 kB
import { HexColor, Vector3, ModelObjectIds, ModelSpec, ModelState, ModelId, ObjectRuntimeId, ObjectProperties, ModelObjects, ColorRGBA, Layer, ModelVersionIdentifier, ViewEntityStates, Box3, PanoramaMetadata, IPointCloudSettings, DeepPartial, HierarchyType, HierarchyEntity, PropertySetDefinition } from "./common"; import { Camera, CameraPreset, CameraOptions, SectionPlane } from "./ViewAPI"; /** The selector mode. */ export declare type SelectorMode = "add" | "remove" | "set"; /** The model objects selection. */ export declare type Selection = ModelObjectIds[]; /** The tools that can be activated. */ export declare const TOOLS: string[]; /** The snapping types that can be configured for a tool. */ export declare const TOOL_SNAP_TYPES: string[]; /** * The data structure representing the selector criteria based on the parameters of the object entities in Trimble Connect 3D Viewer. */ export interface EntityParameter { /** The object class */ class?: string; /** The object properties filter expression * @deprecated Shouldn't be used * In order to query objects with certain properties, the query should contain the pair of property name and property value criteria. * The property name is in the format of <PropertySet>.<PropertyName>. For instance: * * Query objects with certain string value or array: * ``` * properties: {'IfcRectangleProfile.ProfileName': '400*400'}, * properties: {'IfcRectangleProfile.ProfileName': ['300*300', '400*400']}, * ``` * Use the original property names from the model - the property names in the Trimble Connect UI are formatted differently for better readability. */ properties?: any; } /** * The data structure representing the loaded file. */ export interface File { /** The file content. When the host application uses .NET Workspace API, the * client must pass the value as a base64 encoded string in a function argument. * The string must not contain a Data URL prefix (e.g. `data:application/octet-stream;base64,`) * * .NET Workspace API function return value will be a base64 encoded string. * */ blob?: Blob | string; /** The file related metadata */ file: FileEntry; /** The identifier. */ id: string; /** Defines whether there is a newer version available. */ isOldVersion?: boolean; /** The file name. */ name: string; /** The nesting level in the file tree */ nestingLevel: number; /** Defines the permissions level. */ permission?: string; /** The type of the file. */ type: string; /** The version identifier of the file. */ versionId: string; } /** * The data structure representing the file metadata. */ export interface FileEntry { /** The last checked out user. */ checkedOutBy?: User; /** The last checked out date. */ checkedOutOn?: string; /** The author. */ createdBy?: User; /** The creation date. */ createdOn?: string; /** The user that deleted the file. */ deletedBy?: User; /** The deletion date. */ deletedOn?: string; /** The hash. */ hash?: string; /** Defines the visibility state. */ hidden?: boolean; /** The identifier. */ id: string; /** The user that modified the file. */ modifiedBy?: User; /** The last modification date. */ modifiedOn?: string; /** The file name. */ name: string; /** The parent identifier. */ parentId?: string; /** The parent type. */ parentType?: string; /** The project identifier. */ projectId?: string; /** The revision number. */ revision?: number; /** The runtime identifier. */ runtimeId?: string; /** The runtime file type. */ runtimeType?: string; /** The file size. */ size?: number; /** The assimilation status. */ status?: string; /** The thumbnail url. */ thumbnailUrl?: string[]; /** The file or folder file entry type. */ type: string; /** The version identifier. */ versionId?: string; } /** * The data structure representing the object state to be applied. */ export interface ObjectState { /** The object visibility; if a boolean is given, the object visibility state will be changed, * or "reset" to reset the visibility to default */ visible?: boolean | "reset"; /** The object color if any, or "reset" to reset the visibility to default */ color?: ColorRGBA | HexColor | "reset"; } /** * @deprecated Use getObjectProperties API instead. * The option for output object data. */ export interface ObjectOutputOptions { loadProperties?: boolean; } /** * The data structure representing the placement of a Trimble Connect model ({@link ModelSpec}). */ export interface ModelPlacement { /** The model position in millimeters */ position?: Vector3; /** The axis unit vector */ axis?: Vector3; /** The model ref direction unit vector */ refDirection?: Vector3; /** A scalar value. If defined, all of the above vectors will be scaled by the value. */ scale?: number; } /** * The data structure representing the properties of a Trimbim model. */ export interface TrimbimModel { /** The trb model identifier. */ id: string; /** The trb content. When the host application uses .NET Workspace API, the * client must pass the value as a base64 encoded string in a function argument. * The string must not contain a Data URL prefix (e.g. `data:application/octet-stream;base64,`) * * .NET Workspace API function return value will be a base64 encoded string. * */ trbBlob?: Blob | string; /** The trb model id from which blob is fetched */ trbBlobFromId?: string; /** The model placement */ placement?: ModelPlacement; /** If specified, a value indicating whether the trb to fit to view or not */ fitToView?: boolean; /** If specified, a value indicating whether the trb to be shown or hidden */ visible?: boolean; /** Defines whether loaded trimbim model is clipped by clip planes or not (default is clipped) */ clippable?: boolean; /** Object selector for setting partial visibility of model */ selector?: ObjectSelector; /** The object color if any, or "reset" to reset the color to default */ color?: ColorRGBA | HexColor | "reset"; } /** * A structure representing a model object filter. * * The result set is an intersection of object sets where `modelObjectIds`, `selected` and `parameter` filters apply. */ export interface ObjectSelector { /** Objects to be included into the selection. * Leaving this property undefined implies that _all_ objects are included. */ modelObjectIds?: ModelObjectIds[]; /** If set to `true`, only objects currently in `selected` state are included. Otherwise this filter is ignored. */ selected?: boolean; /** If specified, filters model objects by their parameters. Otherwise this filter is ignored. */ parameter?: EntityParameter; /** * @deprecated Use getObjectProperties API instead. * If specified, the options for output data. */ output?: ObjectOutputOptions; } /** * The icon detail. */ export interface PointIcon { /** The icon identifier */ id: number; /** The icon path */ iconPath: string; /** The icon position. The coordinates are in meters. */ position: Vector3; /** The icon size */ size: number; } /** * The data structure representing the object state to be applied. */ export interface ObjectState { /** The object visibility; if a boolean is given, the object visibility state will be changed, * or "reset" to reset the visibility to default */ visible?: boolean | "reset"; /** The object color if any, or "reset" to reset the visibility to default */ color?: ColorRGBA | HexColor | "reset"; /** The object opacity */ opacity?: number; } /** * The data structure representing the viewer settings. */ export interface ViewerSettings { /** Assembly selection active */ assemblySelection: boolean; /** Zoom to fit ratio to define tightness of zoom */ zoomToFitRatio?: number | "reset"; } /** * The data structure representing the instruction visible when tool is activated. */ export interface ToolInstruction { /** The instruction title. */ title: string; /** The instruction text. */ text: string; /** The timeout in milliseconds until the instruction is hidden. */ timeout?: number; } /** * The data structure representing the options when a tool is activated. */ export interface ToolOptions { /** The instruction to be displayed when the tool is activated. If no value is provided, the default instruction will be displayed, if any. */ instruction: ToolInstruction; /** The snapping types to be set when the tool is activated. If no value is provided, all snapping types are set. */ snapTypes: string[]; } /** * The data structure representing Trimble Connect user. */ export interface User { /** The identifier. */ id: string; /** The user's firstname. */ firstName: string; /** The user's lastname. */ lastName: string; /** The user's email. */ email: string; /** The user's status. */ status: string; } /** * The data structure representing an element stored inside a view. */ export interface Element { /** Flag to indicate if the element is part of a hierarchy of elements. */ isRecursive?: boolean; /** The pick priority value of the element. */ priority?: number; /** The source id of the element, as retrieved from the viewer. */ sourceId?: string; /** The state of the element. */ state?: ViewEntityStates; /** The version id of the model the element originates from. */ versionId?: string; /** The color of the element. */ color?: ColorRGBA; } /** * The data structure representing the element types stored inside a view. */ export interface ElementType { /** The type of the element type. */ type?: string; /** The state of the element type. */ state?: number; /** The pick priority value of the element type. */ priority?: number; /** The color of the element type. */ color?: ColorRGBA; } /** * The data structure representing the presentation of a view. */ export interface Presentation { /** Flag to indicate if the ghost mode is enabled in the viewer. */ ghost?: boolean; /** Flag to indicate if the transparent mode is enabled in the viewer. */ transparent?: boolean; /** Flag to indicate if the wireframe mode is enabled in the viewer. */ wireframe?: boolean; /** The transparency level set in the viewer. */ transparencyLevel?: number; /** Flag to indicate if new state is enabled. */ isNewEnabled?: boolean; /** Flag to indicate if pending state is enabled. */ isPendingEnabled?: boolean; /** Flag to indicate if critical state is enabled. */ isCriticalEnabled?: boolean; /** Flag to indicate if resolved state is enabled. */ isResolvedEnabled?: boolean; /** Flag to indicate if ignored state is enabled. */ isIgnoredEnabled?: boolean; /** Flag to indicate if notes are enabled. */ isNotesEnabled?: boolean; /** Flag to indicate if documents are enabled. */ isDocumentsEnabled?: boolean; /** The element types of the view. */ elementTypes?: ElementType[]; /** The elements of the view. */ elements?: Element[]; /** The applied modelIds*/ applyToModels?: string[]; } /** * The data structure representing the properties of a point cloud. */ export interface PointCloud { /** The point cloud identifier. */ id: string; /** Point cloud URL */ url: string; /** The model placement */ placement?: ModelPlacement; /** If specified, a value indicating whether the point cloud to fit to view or not */ fitToView?: boolean; /** If specified, a value indicating whether the point cloud to be shown or hidden */ visible?: boolean; } /** * The types representing the supported camera navigation modes in 3DViewer */ export declare const enum CameraMode { LookAround = "look_around", Pan = "pan", Panorama = "panorama", Rotate = "rotate", Walk = "walk" } /** * The data structure representing the presentation of the position of a object. */ export interface ObjectPosition { /** The identifier. */ id: ObjectRuntimeId; /** The object position. The coordinates are in meters. */ position: Vector3; } /** * The data structure representing the presentation of the bounding box of an object. */ export interface ObjectBoundingBox { /** The identifier. */ id: ObjectRuntimeId; /** Bounding box of the object */ boundingBox: Box3; } /** Payload for `viewer.onPresentationChanged` event */ export declare type PresentationUpdate = DeepPartial<Presentation>; /** Payload for `viewer.onSectionPlaneChanged` event */ export interface SectionPlaneUpdate { action: "added" | "updated" | "removed"; sectionPlane: SectionPlane; } export interface AttachmentTypeSelected { /** The attachment type */ attachmentType: "topic" | "todo" | "other"; } /** Data structure representing entities of a specific model */ export interface IModelEntities { /** The model identifier */ modelId: ModelId; /** The external object identifiers */ entityIds: ObjectRuntimeId[]; } /** * The API for communicating with Trimble Connect 3D Viewer viewer. */ export interface ViewerAPI { /** Activates the tool in the viewer. * @param name - The name of the tool. "reset" value resets the tool to the default tool * @param options - The options to be set for the tool * @returns The awaitable task */ activateTool(name: string, options?: Partial<ToolOptions>): Promise<void>; /** Adds the icon to the viewer. * @param pointIcon - The icon * @returns The awaitable task */ addIcon(pointIcon: PointIcon | PointIcon[]): Promise<void>; /** Adds the section plane to the viewer. * @param sectionPlane - The section * @returns The added section plane(s) */ addSectionPlane(sectionPlane: SectionPlane | SectionPlane[]): Promise<SectionPlane[]>; /** Adds a trimbim model to the viewer. * If only visibility and placement needs to be changed, then it is suggested not to pass blob which will result in serialization penalty and reloading of the trimbim. * The limit for trimbim size is 10MB. * @param model - The trb model * @returns The added TrimBimModel(s) */ addTrimbimModel(model: TrimbimModel | TrimbimModel[]): Promise<boolean[]>; /** Gets the runtime entity IDs of the objects identified by external unique IDs. E.g. For the IFC format, and external id is the uncompressed guid associated with the object. * @param modelId - The model identifier * @param objectIds - The external object identifiers * @returns A Promise which resolves to an array of runtime IDs. The return value array is always of same length as the `objectIds` argument array. For any index where no runtime ID was found for the given `objectId`, the value of the said index will be `undefined` or `null`. */ convertToObjectRuntimeIds(modelId: ModelId, objectIds: string[]): Promise<number[]>; /** Gets the external IDs for the loaded objects in the viewer with the given runtime entity IDs. * * The function throws an exception if no matching external ID is found for every runtime ID in the `runtimeIds` argument. * @param modelId - The model identifier * @param runtimeIds - The runtime identifiers of the objects * @returns The awaitable task that returns the external IDs for the loaded objects in the viewer with the given runtime IDs */ convertToObjectIds(modelId: ModelId, runtimeIds: number[]): Promise<string[]>; /** Gets the current camera data asynchronously. * @returns The awaitable task that returns the current camera data */ getCamera(): Promise<Camera>; /** Gets all the colored objects in the current Trimble Connect project asynchronously. * @returns The awaitable task that returns the colored object entities in the current Trimble Connect project. */ getColoredObjects(): Promise<ModelObjects[]>; /** Gets the list of icons that where added through the API. * @returns The awaitable task that returns the list of icons. */ getIcon(): Promise<PointIcon[]>; /** Gets the list of layers asynchronously. * @param modelId - The identifier of the model to which the layers belong * @returns The awaitable task that returns the model object entities in the current Trimble Connect 3D Viewer */ getLayers(modelId: ModelId): Promise<Layer[]>; /** Get the loaded model file * @param modelId - The identifier of the model * @returns The awaitable task that returns the model file */ getLoadedModel(modelId: ModelId): Promise<File>; /** Gets the list of all models that are available from the file tree asynchronously. * @remarks This may not include all files in the current Trimble Connect project as the file tree only loads the files at root level at start-up. The file hierarchy is lazy-loaded when users expand a tree node. * @returns The awaitable task that returns the model files */ getModels(state?: ModelState): Promise<ModelSpec[]>; /** Gets the object properties asynchronously. * @param modelId - The identifier of the model to which the object belongs * @param objectRuntimeIds - The object runtime identifiers * @returns The awaitable task that returns the model object entities in the current Trimble Connect 3D Viewer */ getObjectProperties(modelId: ModelId, objectRuntimeIds: ObjectRuntimeId[]): Promise<ObjectProperties[]>; /** Gets the positions of the objects based on the ObjectRuntimeId. * @deprecated - use {@link ViewerAPI.getObjectBoundingBoxes} instead. * @param modelId - The identifier of the model to which the object belongs * @param objectRuntimeIds - Array of objectRuntimeId. * @returns The awaitable task that returns the {@link ObjectPosition}. */ getObjectPositions(modelId: ModelId, objectRuntimeIds: ObjectRuntimeId[]): Promise<ObjectPosition[]>; /** Gets the bounding box of the objects based on the ObjectRuntimeId. * @param modelId - The identifier of the model to which the object belongs * @param objectRuntimeIds - Array of objectRuntimeId. * @returns The awaitable task that returns the {@link ObjectBoundingBox}. */ getObjectBoundingBoxes(modelId: ModelId, objectRuntimeIds: ObjectRuntimeId[]): Promise<ObjectBoundingBox[]>; /** Gets the objects satisfying the selector and object state criteria. * @param selector - The selector defining the selection criteria to retrieve the objects. * @param objectState - The objectState defining the visibility criteria to retrieve the objects. * @returns The awaitable task that returns the model object entities in the current Trimble Connect 3D Viewer. */ getObjects(selector?: ObjectSelector, objectState?: ObjectState): Promise<ModelObjects[]>; /** Gets the presentation of the current view. * @returns The awaitable task that returns the current view's presentation data. */ getPresentation(): Promise<Presentation>; /** Gets the list of section planes that are in 3D. * @returns The awaitable task that returns the current objects selection data */ getSectionPlanes(): Promise<SectionPlane[]>; /** Gets the current objects selection data asynchronously. * @remarks Use {@link ViewerAPI.getObjects} to get the data of the objects with the specified identifiers. * @param selector - The selector defining the criteria to retrieve the objects * @returns The awaitable task that returns the current objects selection data */ getSelection(): Promise<Selection>; /** Gets the snapshot of the current view. * @returns A Promise which resolves to a Data URL string containing a base64 encoded image. E.g. `data:image/png;base64,SGVsbG8sIFdvcmxkIQ...` */ getSnapshot(): Promise<string>; /** Gets the loaded trimbim models. * @returns The awaitable task that returns the loaded trimbims. */ getTrimbimModels(): Promise<TrimbimModel[]>; /** Sets the model placement asynchronously. * @param modelId - The ID of the model whose placement will be changed * @param placement - The model placement data to be applied * @returns The awaitable task */ placeModel(modelId: ModelId, placement: ModelPlacement): Promise<void>; /** Removes the icon from the viewer. * @param pointIcon - The icon to be removed. If the parameter is undefined, all added icons will be removed * @returns The awaitable task */ removeIcon(pointIcon?: PointIcon | PointIcon[]): Promise<void>; /** Removes section planes in viewer. * @param sectionPlaneIds - The identifiers of the sectionPlanes that needs to be removed(optional). If this value is not provided or empty array is given then all sectionPlanes will be removed. * */ removeSectionPlanes(sectionPlaneIds?: number[]): Promise<void>; /** Removes the trimbim model from the viewer. * @param model - The trimbim model to be removed. If the parameter is undefined, all added models will be removed * @returns The awaitable task */ removeTrimbimModel(modelId?: string | string[]): Promise<void>; /** Resets model, camera and tools to their default states asynchronously * @returns The awaitable task */ reset(): Promise<void>; /** Sets the camera data asynchronously. * @param camera - The camera data to be applied; * or sets the camera to fit according to the object selector; * or "reset" string to reset the camera to default; * or the camera preset to be applied * @param options - The camera options to be applied, like animationTime; * @returns The awaitable task */ setCamera(camera: Camera | ObjectSelector | "reset" | CameraPreset, options?: Partial<CameraOptions>): Promise<void>; /** Sets the object state asynchronously. * @param selector - The selector which defines the affected objects. If the argument is `undefined`, the `objectState` is applied to all objects in the loaded models * @param objectState - The object state to be applied * @returns The awaitable task */ setObjectState(selector: ObjectSelector | undefined, objectState: ObjectState): Promise<void>; /** Define object selection in loaded 3d models. * @param selector - A selector which defines to which objects to apply the `mode` argument to. * @param mode - The mode is applied to all objects matching the criteria defined by the `selector` argument * * `add` = Add objects to the currently selected objects * * `remove` = Remove objects from the currently selected objects * * `set` = Set objects as selected. Any other objects are deselected. * @returns The awaitable task */ setSelection(selector: ObjectSelector, mode: SelectorMode): Promise<void>; /** Sets the opacity of the 3D viewer asynchronously. * @param transparency - The opacity level, which ranges from 0 to 100 * @returns The awaitable task */ setOpacity(transparency: number): Promise<void>; /** Sets the access token of the 3D viewer asynchronously. * @deprecated Use {@link EmbedAPI.setTokens} instead. * @param accessToken - The Trimble Connect access token * @param refreshToken - The Trimble Connect refresh token * @returns The awaitable task */ setAccessTokens(accessToken: string, refreshToken?: string): Promise<void>; /** Sets the layers visibility of the model asynchronously. * @param modelId - The ID of the model whose layers visibility will be changed * @param layers - A value containing the layers whom visibility will be changed * @returns The awaitable task */ setLayersVisibility(modelId: ModelId, layers: Layer[]): Promise<void>; /** Toggles the model state asynchronously. * @param modelId - The model identifier or array of model identifiers * @param loaded - A value indicating whether the model should be loaded or unloaded. * If this parameter is not defined, the model state will be toggled * @param fitToView - Value indicating if model(s) should be fitted to view after loading. * @returns The awaitable task */ toggleModel(modelId: ModelId | ModelId[], loaded?: boolean, fitToView?: boolean): Promise<void>; /** Toggles the model version state asynchronously. * @param modelId - The model identifier or array of model identifiers. The model identifier includes model id and version id. * @param loaded - A value indicating whether the model should be loaded or unloaded. * If this parameter is not defined, the model state will be toggled * @param fitToView - Value indicating if model(s) should be fitted to view after loading. * @returns The awaitable task */ toggleModelVersion(modelId: ModelVersionIdentifier | ModelVersionIdentifier[], loaded?: boolean, fitToView?: boolean): Promise<void>; /** Gets the current viewer settings asynchronously. * @returns The awaitable task that returns the current viewer settings. */ getSettings(): Promise<ViewerSettings>; /** Sets the viewer settings asynchronously. * @param settings - {@link ViewerSettings} - configure the assemblySelection mode and fitToZoomRatio. * @returns The awaitable task. */ setSettings(settings: Partial<ViewerSettings>): Promise<void>; /** Adds the panorama tiles in the viewer space. * @param settings - {@link PanoramaMetadata} - Panorama tile configuration * @returns The awaitable task that will resolve into boolean. */ addPanorama(settings: PanoramaMetadata): Promise<boolean>; /** Adds the point clouds into the viewer space. * @param pointCloud - {@link PointCloud} - point cloud source data. * @returns The awaitable task that will resolve into boolean. */ addPointCloud(pointCloud: PointCloud | PointCloud[]): Promise<boolean>; /** Gets the point cloud and panorama tiles added to the viewer using addPointCloud and addPanorama * @returns The awaitable task that will resolve into {@link PointCloud} */ getPointClouds(): Promise<PointCloud[]>; /** Removes any model file from the viewer * @param modelId - unique identifier of the model file * @param fitToView - allows to reset the viewer camera position * @returns The awaitable task that will resolve into boolean. */ removeModel(modelId: string, fitToView?: boolean): Promise<boolean>; /** Sets the configuration of point clouds based on the modeId * @param settings - {@link IPointCloudSettings} - allowed point cloud configuration settings. * @param modelId - unique identifier of the point cloud. * @returns The awaitable task that will resolve into boolean. */ setPointCloudSettings(settings: IPointCloudSettings, modelIds?: string[]): Promise<boolean>; /** Gets the current camera navigation mode in the viewer * @returns The awaitable task that will resolve into {@link CameraMode}. */ getCameraMode(): Promise<CameraMode>; /** Sets the current camera navigation mode in the viewer * @param mode - allowed camera navigation modes by the viewer * @param spawnPoint - The spawn point for the camera mode - walk * @returns The awaitable task that will resolve into boolean. */ setCameraMode(mode: CameraMode, spawnPoint?: Vector3): Promise<boolean>; /** Equivalent to the "Show only selected objects" feature in the viewer. It will simply hide all objects except the ones provided in the input. * @param IModelEntities - Array of model entities to be isolated * @returns The awaitable task that will resolve into boolean. */ isolateEntities(modelEntities: IModelEntities[]): Promise<boolean>; /** * Retreives hierarchy parents of given children * @param modelId - The model identifier * @param entityIds - The children entity ids * @param hierarchyType - The hierarchy type * @param recursive - (default false) if false only direct parents are returned, otherwise returns all parents up to hierarchy roots. * @param containedOnly - (default false) if false the parent will be returned when atleast one child is given in entityIds, otherwise parent is returned only when all its children are. */ getHierarchyParents(modelId: ModelId, entityIds: ObjectRuntimeId[], hierarchyType?: HierarchyType, recursive?: boolean, containedOnly?: boolean): Promise<HierarchyEntity[]>; /** * Retreives hierarchy children of given parent * @param modelId - The model identifier * @param entityIds - The parent entity ids * @param hierarchyType - The hierarchy type * @param recursive - (default false) if false only direct children are returned, otherwise returns tho whole tree or children. */ getHierarchyChildren(modelId: ModelId, entityIds: ObjectRuntimeId[], hierarchyType?: HierarchyType, recursive?: boolean): Promise<HierarchyEntity[]>; /** Below viewer API methods for smart 3dv search extension - Note: meant for internal use only */ /** @internal*/ getPsetDefinitions: () => Promise<PsetDefinitionForSearch[]>; /** @internal */ getEntities: () => Promise<IEntitiesForSearch[]>; /** @internal */ getEntityIdsForAISearch: (AIResponse: IResponseFromAI) => Promise<ISearchResponse[]>; /** * Show the clearance bands between selected Trimbim entities and point cloud. * @param pointcloudModelId - The ID of the point cloud model. * @param trimbimModelId - The ID of the Trimble BIM model. * @param entityIds - The IDs of the entities to set clearance for. */ setPointCloudClearance(pointcloudModelId: string, trimbimModelId: string, entityIds: ObjectRuntimeId[]): Promise<void>; /** * Removes the clearance bands for the specified point cloud model. * @param modelId - The ID of the model from which to remove the clearance bands */ removePointCloudClearance(modelId: string): void; } /** Below type definitions for smart 3dv search extension - Note: meant for internal use only */ /** @internal*/ export interface PsetDefinitionForSearch { modelId: string; psets: PropertySetDefinition[]; } /** @internal*/ export interface IEntitiesForSearch { modelId: string; versionId: string; entityForModel: Entity[]; } /** @internal*/ export interface Entity { class: string; identifierType: IdentifierType; id: number; } /** @internal*/ export declare const enum IdentifierType { Guid = 0, String = 1, SpatialHash = 2, DwgHandle = 3, None = 4 } /** @internal*/ export interface IResponseFromAI { command: ICommand; type: string; filterCriteria: IConditionGroup; } /** @internal*/ export interface ICommand { commandName: string; commandParameters: { [key: string]: string | number | boolean; }; } /** @internal*/ export interface IConditionGroup { logicalGroup: string; outerConditions: IOuterCondition[]; } /** @internal*/ export interface IOuterCondition { logicalGroup: string; innerConditions: ICondition[]; } /** @internal*/ export interface ICondition { propertyName: string; operator: string; value: string | number | boolean; propertyNameHint: string; } /** @internal*/ export interface ISearchResponse { modelId: string; versionId: string; entityIdForModel: number[]; }