import { DrawingID, ObjectID, ObjectIdent, WorkGeomType } from '@buerli.io/core'; import { CircularPatternConstraint, CylindricalConstraint, FastenedConstraint, FastenedOriginConstraint, GroupConstraint, IStructureTree, LinearPatternConstraint, ParallelConstraint, PlanarConstraint, RevoluteConstraint, SliderConstraint } from '../../re-export'; /** * Finds the product of given reference in the structure tree * * @param refOrRefEtId The reference id or referenceET id. * @param tree The structure tree. * @returns The resolved product for the provided reference _refOrRefEtId_. If no product was found, _undefined_ is returned. */ export declare const findProduct: (refOrRefEtId: ObjectID, tree: IStructureTree) => ObjectID | undefined; /** * @deprecated use specific methods e.g. getFastenedConstraint() instead, getConstraint() will be removed in a future release. * * Returns the fastened or fastened origin constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The constraint information as array. The array is empty if no constraint was found. */ export declare const getConstraint: (drawingId: DrawingID, refId: ObjectID, constrName?: string) => any[]; /** * Returns the fastened constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found fastened constraint as object or undefined if nothing has been found */ export declare const getFastenedConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => Omit, 'useCurrentTransform'> | undefined; /** * Returns the fastened origin constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found fastened origin constraint as object or undefined if nothing has been found */ export declare const getFastenedOriginConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => Omit, 'useCurrentTransform'> | undefined; /** * Returns the revolute constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found revolute constraint as object or undefined if nothing has been found */ export declare const getRevoluteConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => RevoluteConstraint | undefined; /** * Returns the slider constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found slider constraint as object or undefined if nothing has been found */ export declare const getSliderConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => SliderConstraint | undefined; /** * Returns the planar constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found planar constraint as object or undefined if nothing has been found */ export declare const getPlanarConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => PlanarConstraint | undefined; /** * Returns the parallel constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found parallel constraint as object or undefined if nothing has been found */ export declare const getParallelConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => ParallelConstraint | undefined; /** * Returns the cylindrical constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found cylindrical constraint as object or undefined if nothing has been found */ export declare const getCylindricalConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => CylindricalConstraint | undefined; /** * Returns the group constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found group constraint as object or undefined if nothing has been found */ export declare const getGroupConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => GroupConstraint | undefined; /** * Returns the linear pattern constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found linear pattern constraint as object or undefined if nothing has been found */ export declare const getLinearPatternConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => LinearPatternConstraint | undefined; /** * Returns the circular pattern constraint of given reference with specified name. * * @param drawingId The drawing id. * @param refId The product reference to look for constraint. * @param constrName The name of constraint to look for. * @returns The found circular pattern constraint as object or undefined if nothing has been found */ export declare const getCircularPatternConstraint: (drawingId: DrawingID, refId: ObjectID, constrName: string) => CircularPatternConstraint | undefined; /** * @deprecated use getWorkGeometry() instead, getWorkCoordSystem() will be removed in a future release. * * Returns all workcoordsystems of given reference with specified name. * If _wcsName_ is undefined, all workcoordsystems of given reference will be returned. * * @param drawingId The drawing id. * @param refId The product reference to look for wcs. * @param wcsName The name of wcs to look for. * @returns An array of ids of all workcoordsystems found. The array is empty if nothing was found. */ export declare const getWorkCoordSystem: (drawingId: DrawingID, refId: ObjectID, wcsName?: string) => ObjectID[]; /** * Returns all work geometry of given type and given reference with specified name. * If wgName is undefined, all work geometry of given reference will be returned. * * @param drawingId The drawing id. * @param refId The product reference to look for work geometry. * @param type The type of work geometry to look for * @param wgName The name of work geometry to look for. * @returns An array of ids of all found work geometry. The array is empty if nothing was found. */ export declare const getWorkGeometry: (drawingId: DrawingID, refId: ObjectID, type: WorkGeomType, wgName?: string) => ObjectID[]; /** * Returns the part template with given identifier or name from part container. * If _partName_ is undefined, all parts from part container will be returned. * * @param drawingId The drawing id. * @param partName The identifier or name of the part to look for. * @returns An array of ids of all parts found. The array is empty if nothing was found. */ export declare const getPartTemplate: (drawingId: DrawingID, partName?: string) => ObjectID[]; /** * Returns the assembly template with given identifier or name from assembly container. * If _asmName_ is undefined, all assemblies from assembly container will be returned. * * @param drawingId The drawing id. * @param asmName The identifier or name of the assembly to look for. * @returns An array of ids of all assemblies found. The array is empty if nothing was found. */ export declare const getAssemblyTemplate: (drawingId: DrawingID, asmName?: string) => ObjectID[]; /** * Returns an instance or all instances of a node, depending on whether a name is given or not. * The node is the parent of the instance/instances we're looking for and can be a root assembly, * another instance or an assembly template. * * @param drawingId The drawing id. * @param id id of the node from which we are searching the children for instances that have the name we are looking for. * @param instanceName name of the instance we are looking for * @returns array containing the ids of the found instances */ export declare const getInstance: (drawingId: DrawingID, id: ObjectID, instanceName?: string) => ObjectID[]; /** * Returns the coordinate system (global transformation) of the given instance id. * * @param drawingId The drawing id * @param instanceId id of the instance to get the coordinate system (global transformation) from * @returns The coordinate system as an two-dimensional array */ export declare const getTransformation: (drawingId: DrawingID, instanceId: ObjectID) => number[][] | undefined; /** * Creates and returns the mate path as array from the given instance id up to the current instance. * This helps to get the right path to set constraints between instances which are located in * nested assemblies. * @param drawingId The drawing id * @param instanceId id of the instance to get the mate path from. Id can be a number or string. * @returns The mate path as array from the given instance id up to the current instance */ export declare const getMatePath: (drawingId: DrawingID, instanceId: ObjectID | ObjectIdent) => ObjectID[];