Class: PropTools
Class: PropTools
Functions for batch fetching properties for a list of elements or all elements. See MetaManager.propTools property in MetaManager class.
Constructors
Constructor
new PropTools(
metaManager):PropTools
Parameters
metaManager
MetaManager instance.
Returns
PropTools
Methods
getBatchPropsByELGuids()
getBatchPropsByELGuids(
guids,props):Promise<Map<number,any>>
Get batch properties for multiple elements by element GUIDs.
Parameters
guids
string[]
Element GUIDs.
props
string[]
List of full (with paths) parameter names to retrieve.
Returns
Promise<Map<number, any>>
getBatchPropsByElNums()
getBatchPropsByElNums(
elNums,props):Promise<Map<number,any>>
Get batch properties for multiple elements by element numbers.
Parameters
elNums
number[]
Element numbers.
props
string[]
List of full (with paths) parameter names to retrieve.
Returns
Promise<Map<number, any>>
getBatchPropsByModelIds()
getBatchPropsByModelIds(
modelVersionIds,props):Promise<Map<number,any>>
Get batch properties for all elements by model version GUIDs.
Parameters
modelVersionIds
string[]
Model version GUIDs.
props
string[]
List of full (with paths) parameter names to retrieve.
Returns
Promise<Map<number, any>>
parKeysToPath()
staticparKeysToPath(propKeys):string
Converts an array of strings back into a JSON path string.
Parameters
propKeys
string[]
An array of keys representing the path.
Returns
string
A string path in JSON format.
parPathToKeys()
staticparPathToKeys(path):string[]
Converts a JSON path string into an array of strings.
Parameters
path
string
The string path, e.g., "Pars.Data.Размер" or "Pars['Общая длина'].Размер".
Returns
string[]
An array of keys representing the path.