MainPage   Related pages 
AutomationAPI.h
1 
2 //
3 // $Id: AutomationAPI.h 5870 2022-01-25 12:56:31Z stefan.losch $
4 // (c) ceapoint aec technologies GmbH
5 //
6 
7 
8 #pragma once
9 
10 
11 #include "CoreAPI.h"
12 
13 
14 namespace domainBim
15 {
16 
17  class BimProject;
18 
30  class AutomationAPI : public CoreAPI
31  {
32 
33  Q_OBJECT
34 
35  public:
36 
38  /*
39  \param isAutomation Affects access rights
40  */
41  AutomationAPI( BimProject* bimPrj, bool isAutomation, QObject* parent = 0 );
42  virtual ~AutomationAPI();
45  public slots:
46 
47 
48 #pragma region FIND OBJECTS
49 
57  bool hasElement(QString id);
58 
70  QStringList getRootContainerList(QString modelName);
71 
84  QString findContainerByName( const QString& parentId, const QString& name, const QString& lookupDomain = "all" );
85 
86 
103  QString getContainerByName(QString parentId, QString name);
104 
105 
114  bool isContainer( QString id );
115 
126  QVariantList findDocumentsByLocationGps( double lat, double lon, double distance, QStringList idList = QStringList() );
127 
137  QVariantList findDocumentsByLocationRangeGps( QStringList gpsCoordinates, double distance, QStringList idList = QStringList() );
138 
149  QVariantList findDocumentsByLocationGk( double rw, double hw, double distance, QStringList idList = QStringList() );
150 
161  QStringList findDocumentsByDate( QDateTime start, QDateTime end, QStringList idList = QStringList(), bool useRef = false );
162 
163 
165 #pragma endregion
166 
167 
168 #pragma region DOCUMENTS - SYNC, METADATA
169 
207  int synchronizeDocumentContainer( QString containerId, QScriptValue callback = QScriptValue(), bool blockExecution = false );
208 
213  void resetDocumentMetaData( QString objId );
214 
216 #pragma endregion
217 
218 
219 #pragma region ACTIVITIES - TOOLS
220 
243  QVariantMap getVisualisationList();
244 
257  int setVisualisationByID( QString taskIDList, QString visID );
258 
269  int removeVisualisation( QString taskIDList );
270 
285  int setTaskMode( QString taskID, int mode );
286 
325  QVariantMap calcPropertyValuesOverTime( QString propName, QString propType, QVariantMap options );
326 
328 #pragma endregion
329 
330 #pragma region ACTIVITIES - CALENDAR
331 
340  QStringList getCalendarList();
341 
352  QString getCalendarByName(QString name);
353 
364  QString getCalendarByTask(QString taskID, bool checkInh = true);
365 
378  int setCalendar(QString taskID, QString calendarID);
379 
393  int calcWorkInMinutes(QDateTime start, QDateTime finish, QString calendarID = QString());
394 
396 #pragma endregion
397 
398 #pragma region ACTIVITIES - TASK RESTRICTIONS
399 
408  QStringList getTaskRestrictionsList();
409 
419  QString getTaskRestrictionsByName(QString name);
420 
431  QString getTaskRestrictionsByTask(QString taskID, bool checkInh = true);
432 
445  int setTaskRestrictions(QString taskID, QString restrictionID);
446 
457  int removeTaskRestrictions(QString taskID);
458 
460 #pragma endregion
461 
462 #pragma region BOQ - TOOLS
463 
477  int setBoQBreakdownStructure(QString boqModelID, QString templateStr);
479 #pragma endregion
480 
481 #pragma region GEOMETRIC TOOLS
482 
484 
516  int hasContact( QString objId1, QString objId2, QVariantMap options = QVariantMap() );
517 
550  QString createContactObject( QString parentId, QString objId1, QString objId2, QString matId, QVariantMap options = QVariantMap() );
551 
582  QStringList cutObject( QString parentId, QString objId, QVariantMap plane = QVariantMap() );
583 
584 
607  QString mergeObjects( QString parentContainerId, QString idList, bool skipClosed = false, bool keepTransparency = false, bool keepCommonProperties = false, bool replaceParent = false);
608 
609 
618  bool isIncludedIn(QString objId1, QString objId2);
619 
636  int isPointIncludedIn(double x, double y, double z, QString objId, double tol = 1.e-5 );
637 
638 
653  int checkIntersection( QString objId1, QString objId2, double tolerance = -0.00001 );
654 
677  int transformObject( QString objId, QString transformation );
678 
692  int setAsOpening( QString objId, QString openingIDList );
693 
717  QString getProjectionAsSvg( QString idList, QVariantMap options = QVariantMap() );
718 
719 
733  double calcDistance( QString objId1, QString objId2 );
734 
735 
737 #pragma endregion
738 
739 
740 #pragma region SELECTION_SETS
741 
786  QString createSelectionSets(QString propertyTypes, QString rootName, QVariantMap config = QVariantMap());
787 
795  QStringList getRootNodeListSelectionSets( QString domainFilter = "all" );
796 
806  int addToSelectionSetGeometry( QString setId, QString objectIDList );
807 
819  int removeFromSelectionSetGeometry( QString setId, QString objectIDList );
820 
828  QString createSelectionSet( QString name, QString parentID = QString() ); // , QString domain = "geometry" );
829 
835  bool removeSelectionSet( QString selsetID );
836 
842  int updateSmartSets(QStringList smartSetIDs = QStringList());
843 
845 #pragma endregion
846 
847 
848 #pragma region MODELS
849 
862  QString getModelByName( QString name, QString domainFilter = "geometry" );
863 
872  QString getModelByElement( QString id, QString domainFilter = "all" );
873 
874 
888  QString getRootContainerByName(QString modelName, QString rootContainerName);
889 
890 
904  QStringList getModelListByName( QString name, QString domain = "geometry" );
905 
916  QStringList getModelListByDomain( QString domainFilter = "all" );
917 
930  QString getRootNodeByModel( QString modelId );
931 
943  QStringList getRootNodeListByDomain( QString domainFilter = "all" );
944 
977  QString createModel(QString name, bool createRootC = true, QString domain = "geometry" );
978 
1012  QVariantMap getModelMetaData( QString modelId );
1013 
1014 
1029  int deleteModel( const QString& id );
1030 
1032 #pragma endregion
1033 
1034 
1035 #pragma region PROJECT
1036 
1055  void setCloudSettings( QVariantMap vm );
1056 
1062  void setTempValue( QString name, QVariant value );
1063 
1068  QVariant getTempValue( QString name );
1069 
1074  QStringList getListOfTempValues();
1075 
1078  void clearListOfTempValues();
1079 
1081 #pragma endregion
1082 
1083 
1084 #pragma region LINKED OBJECTS
1085 
1099  int setLinkedObjects( const QString& elementID, const QString& IDList );
1100 
1111  int removeAllLinkedObjects( QString id );
1112 
1121  int removeLinkedObjects( QString id, QString linkedIdList );
1122 
1124 #pragma endregion
1125 
1126 
1127 #pragma region PROPERTY TYPES
1128 
1143  int createPropertyType( const QString& propName, const QString& propDatatype, const QString& uomCode, bool isInh, int target, const QString& domainName = "all" );
1144 
1168  int setPropertyTypeMetaData( QString pName, QString ptype, QVariantMap metadata );
1169 
1188  int deletePropertyType( QString propName, QString propDatatype, QString domainName = "all" );
1189 
1217  QList<QVariant> getPropertyTypeBookmarkList( );
1218 
1254  QVariantMap getPropertyTypeBookmarkByID( QString bookmarkId );
1255 
1265  int activatePropertyTypeBookmark( QString bkmId );
1266 
1271  bool setPropertyTypeActive(QString pName, QString ptype, QString domain, bool active);
1272 
1278 
1282  int removePropertyTypeBookmarkByID( QString bkmId );
1283 
1293  QString addPropertyTypeBookmark( QVariantMap bookmarkConfig);
1294 
1296 #pragma endregion
1297 
1298 
1299 #pragma region PROPERTIES
1300 
1329  int setPropertyValue( QString objId, QString propName, QString propDataType, QVariant value );
1330 
1360  int setPropertyValueRepository( QString objId, QString propName, QString propDataType, QVariant value, bool createType = true );
1361 
1377  int deleteProperty( QString objId, QString propName, QString propDatatype );
1378 
1401  QList<QVariant> getAvailablePropertyValues( QString propName, QString propDatatype, int maxValues, QString domainName = "geometry" );
1402 
1403 
1419  QList<QVariant> getPropertyValues( QString propName, QString propDatatype, int maxValues = 0, QString domainName = "all", bool getNullValues = false );
1420 
1439  QList<QVariant> getPropertyValuesByObjectList(
1440  QString propName,
1441  QString propDatatype,
1442  bool checkInh,
1443  QString objIdList,
1444  int maxValues = 0,
1445  QString domainName = "all",
1446  bool getNullValues = false );
1447 
1488  QVariantMap getPropertyListAsJSON( QVariantMap options );
1489 
1565  void setPropertyListAsJSON( QVariantMap propmap, QVariantMap opt );
1566 
1568 #pragma endregion
1569 
1570 
1571 #pragma region PROPERTY SCRIPTS
1572 
1611  QVariantMap getPropertyScriptList() const;
1612 
1620  QString getPropertyScriptCode( QString domain, QString pname, QString datatype ) const;
1621 
1629  QString getPropertyScriptFgColor( QString domain, QString pname, QString datatype ) const;
1630 
1638  QString getPropertyScriptBgColor( QString domain, QString pname, QString datatype ) const;
1639 
1651  int setPropertyScriptCode( QString domain, QString pname, QString datatype, QString code );
1652 
1664  int setPropertyScriptFgColor( QString domain, QString pname, QString datatype, QString code );
1665 
1677  int setPropertyScriptBgColor( QString domain, QString pname, QString datatype, QString code );
1678 
1684  QVariantMap addPropertyScript( QString domain, QString pname, QString datatype, QString code = QString() );
1685 
1691  int removePropertyScript( QString domain, QString pname, QString datatype );
1692 
1700  void propertyScriptClearCache();
1701 
1707  void propertyScriptClearCache( QString domain, QString pname, QString datatype );
1708 
1723  QVariantMap getPropertyScriptOptions( QString domain, QString pname, QString datatype );
1724 
1743  int setPropertyScriptOptions( QString domain, QString pname, QString datatype, QVariantMap opt );
1744 
1745 
1747 #pragma endregion
1748 
1749 
1750 #pragma region GEOMETRY - MATERIALS
1751 
1784  QString createMaterial( QString matXml, QString modelId = QString() );
1785 
1798  int deleteMaterial( QString matId );
1799 
1805  QStringList getMaterialList();
1806 
1814  QString getMaterialAsXmlByID( QString matId );
1815 
1836  QVariantMap getMaterial( const QString& matId );
1837 
1844  QString getMaterialIDByName( QString matName );
1845 
1856  void updateMaterial( QString matId, QString xmlMat );
1857 
1870  int setMaterialToObjects( QString matId, QString objectIds );
1871 
1883  int setTransparency( QString objectIds, float defaultTransparency = 0.95 );
1884 
1892  void resetMaterials( bool updateUI = true );
1893 
1899  void reorderElements();
1900 
1902 #pragma endregion
1903 
1904 
1905 #pragma region GEOMETRY - COLOR SCHEMA
1906 
1919  QString createColorSchema( QString setContainerId, QString name );
1920 
1940  QString createColorSchemaFromCurrentMaterials(QString name, bool updateExisting, QVariantMap options = QVariantMap() );
1941 
1951  int deleteColorSchema( QString namePattern );
1952 
1958  QStringList getColorSchemaList();
1959 
1965  QString getCurrentColorSchema();
1966 
1976  bool activateColorSchemaByName( QString name );
1977 
1978 
1980 #pragma endregion
1981 
1982 
1983 #pragma region GEOMETRY- WIREMODE
1984 
1992  void showWireModeSchema( QString name );
1993 
1998  void clearWireMode();
1999 
2009  void setObjectsToWireMode( QString ids, bool wired );
2010 
2023  QString createWireModeSchema( QString ids, QString wmName, bool overwrite = false );
2024 
2029  QString getWired();
2030 
2035  int countWired();
2036 
2037 
2039 #pragma endregion
2040 
2041 
2042 #pragma region BBOX
2043 
2050  double getBBoxMinX();
2051 
2057  double getBBoxMaxX();
2058 
2064  double getBBoxMinY();
2065 
2071  double getBBoxMaxY();
2072 
2078  double getBBoxMinZ();
2079 
2085  double getBBoxMaxZ();
2086 
2091  void updateBoundingBox3DView();
2092 
2105  int calcOOBB( QString objIdList, double eps = 0.001 );
2106 
2119  int updateOOBB( QString obIDList, double eps = 0.001 );
2120 
2133  int calcOOBBxy( QString objIdList, double eps = 0.001 );
2134 
2147  int updateOOBBxy( QString objIdList, double eps = 0.001 );
2148 
2172  QVariantMap getBoundingBoxCommon( QString objIdList );
2173 
2193  QVariantMap getOOBBCommon( QString objIdList );
2194 
2214  QVariantMap getOOBBxyCommon( QString objIdList );
2215 
2228  double checkOverlapOBB( QString id1, QString id2, double eps );
2229 
2231 #pragma endregion
2232 
2233 
2234 #pragma region CREATE / DELETE OBJECTS / GET OBJECTS
2235 
2245  int startProjectTransaction( const QString& domain = "geometry" );
2246 
2255  int endProjectTransaction( const QString& domain = "geometry" );
2256 
2562  QString createObjectFromXml( const QString& parentId, const QString& objectXML );
2563 
2564 
2577  int deleteObjects( QString idList );
2578 
2579 
2593  void setName( QString objIdList, QString name );
2594 
2595 
2613  QString createObject( QString parentId, QString name );
2614 
2691  QVariantMap getAsJSON( QString objId );
2692 
2705  int setAsComposite( const QString& id, bool composite );
2706 
2707 
2709 #pragma endregion
2710 
2711 
2712 #pragma region REGIONS OF ALIGNMENTS
2713 
2749  QString addRegionToAlignment( QString alignmentId, QVariantMap setting );
2750 
2761  int removeAllRegionsFromAlignment( QString alignmentId );
2762 
2778  int addRangeToRegion( QString regionId, double fromStation, double toStation, QString alignmentId = QString() );
2779 
2795  int removeRangeFromRegion( QString regionId, double fromStation, double toStation, QString alignmentId = QString() );
2796 
2809  int removeAllRangesFromRegion( QString regionId, QString alignmentId = QString() );
2810 
2812 #pragma endregion
2813 
2814 
2815 #pragma region FILE OPERATIONS
2816 
2832  int createDirectory( QString path, QString dirName );
2833 
2846  bool writeFile( QString filePath, const QString& content, const QString& encoding = QString() );
2847 
2858  bool writeBinaryFile(QString filePath, const QByteArray& data);
2859 
2872  bool appendToFile(QString filePath, const QString& content, const QString& encoding = QString() );
2873 
2884  bool removeFile(QString filePath);
2885 
2890  bool copyFile( QString fnFrom, QString fnTo );
2891 
2896  bool moveFile( QString fnFrom, QString fnTo );
2897 
2908  bool checkIfFileExists(QString filePath);
2909 
2923  bool openFile( QString filePath, const QString& encoding = QString() );
2924 
2937  bool writeToFile(QString content);
2938 
2947  bool closeFile();
2948 
2971  QStringList readTextFile( QString filename, bool ignoreLineBreakesInDoubleQuotes = false, QString codec = QString() );
2972 
2982  QString readTextFileAsString( QString filename, QString codec = QString() );
2983 
2993  QByteArray readBinaryFile(QString filePath);
2994 
3040  QVariantMap readCsvFile( QString filename, QString delimiter = ";", QString quoteSign = "\"" );
3041 
3058  int csvOpen( QString filename, QString delimiter = ";", QString quoteSign = "\"" );
3059 
3066  QStringList csvNextLine( );
3067 
3074  bool csvHasNextLine();
3075 
3082  bool csvClose( );
3083 
3084 
3085 
3086 
3101  QString readImageFile( QString filename, QString targetFormat = "", bool applyExifRotation = false );
3102 
3103 
3128  QVariantList getDirectoryEntryList( QString dirPath, bool filesOnly = false, QString orderBy = "Name" );
3129 
3130 
3132 #pragma endregion
3133 
3134 
3135 #pragma region DATABASE
3136 
3142  bool dbIsLocalCopy();
3143 
3148  QString dbGetFilepath() const;
3149 
3171  int dbOpen(const QVariant connectionData = QVariant());
3172 
3177  bool dbClose();
3178 
3184  void dbCheckIn();
3185 
3194  void dbCheckOut(const QStringList& propList);
3195 
3207  bool dbQueryExec(const QString& sqlQuery);
3208 
3237  QVariantMap dbQueryRecordset(const QString& sqlQuery, const QString& key, int maxNumberOfRows = 0 );
3238 
3246  bool dbEndQueryExec();
3247 
3258  bool dbQueryNext();
3259 
3263  QVariant dbQueryValue(int column);
3264 
3270  QString dbQueryLastError();
3271 
3302  int setPropertyValueDB(const QString& objIdList, const QString& propName, const QString& propDataType, const QString& propDomain, const QVariant& value, bool createType = true);
3303 
3322  int writePropertyValueDB(const QString& objIdList, const QString& propName, const QString& propDataType, const QString& propDomain, const QVariant& value, bool createType = true );
3323 
3327  bool startTransaction();
3328 
3332  bool endTransaction();
3333 
3339  bool dbGetImmediateUpdate();
3340 
3346  void dbSetImmediateUpdate(bool);
3347 
3353  int dbClearCache( const QString& propName, const QString& propType );
3354 
3359  void dbClearCacheAll();
3360 
3372  int dbDeleteProperty( const QString& objIdList, const QString& propName, const QString& propType );
3373 
3396  int dbAssertTable( const QString& tableName, const QStringList& columnsList );
3397 
3399 #pragma endregion
3400 
3401 
3402 #pragma region OBJECT TOOLTIPS
3403 
3405 
3410  QStringList getListOfObjTooltips();
3411 
3420  void addObjectListToTooltip( QString idList, QString tooltipname );
3421 
3430  void removeObjectListFromTooltip( QString idList, QString tooltipname );
3431 
3433 
3434 #pragma endregion
3435 
3436 
3437 #pragma region LOCKING OF OBJECTS
3438 
3445  void lockObjects( QString idList );
3446 
3452  void unlockObjects( QString idList );
3453 
3458  void unlockAllObjects();
3459 
3465  QString getLocked();
3466 
3472  int countLocked();
3473 
3475 #pragma endregion
3476 
3477 
3478 #pragma region OBJECT ITERATOR
3479 
3485  void itClear();
3486 
3505  int itByFilter(QString propName, QString propDatatype, QString filterPattern, bool checkInh = true, QString domain = "geometry" );
3506 
3507 
3523  int itFilterByStatus(QString status, bool enabled = true, QString domain = "geometry");
3524 
3525 
3533  int itByObjectList( QString idList );
3534 
3540  QString itGetObjectList();
3541 
3549  bool itHasNext();
3550 
3556  QString itNext();
3557 
3563  int itCount();
3564 
3570  void itToFront();
3571 
3579  QList<QVariant> itGetAvailablePropertyValues(QString propName, QString propDatatype, int maxValues );
3580 
3585  void itSetupDbCache( QString propName, QString propType );
3586 
3591  void itSetMaterial(QString matId);
3592 
3605  void itColorCode( QString propName, QString propDT );
3606 
3621  void itColorCodeNumber( QString propName, QString propDT, double intervalSize );
3622 
3628  void itCalcOOBB( double eps );
3629 
3634  void itUpdateOOBB( double eps );
3635 
3641  void itCalcOOBBxy( double eps );
3642 
3647  void itUpdateOOBBxy( double eps );
3648 
3650 #pragma endregion
3651 
3654  private:
3655 
3656  QFile* _file;
3657  QTextStream* _textstream;
3658  QFile* _csvFile;
3659  QTextStream* _csvTextStream;
3660 
3661  char _c_delimiter;
3662  char _c_quoteSign;
3663  bool _isAutomation;
3664 
3665  /*
3666  Check if a given filePath actually contains a path, or just the filename.
3667  If path included: input unmodified, return true
3668  If path not included and project open: prepend project path to input, return true
3669  If path not included and no project open: input unmodified, return false
3670 
3671  \since 2.4.2, 2019-03-01, ah
3672  */
3673  bool _checkCompleteFilePath(QString& filePath);
3674 
3677  };
3678 
3679 }
QVariantMap getPropertyScriptOptions(QString domain, QString pname, QString datatype)
int removePropertyTypeBookmarkByID(QString bkmId)
int itFilterByStatus(QString status, bool enabled=true, QString domain="geometry")
QString getCalendarByName(QString name)
QString getModelByName(QString name, QString domainFilter="geometry")
QStringList getListOfObjTooltips()
int setPropertyValue(QString objId, QString propName, QString propDataType, QVariant value)
QString getModelByElement(QString id, QString domainFilter="all")
void setCloudSettings(QVariantMap vm)
int removeAllRangesFromRegion(QString regionId, QString alignmentId=QString())
int addToSelectionSetGeometry(QString setId, QString objectIDList)
int deleteMaterial(QString matId)
QVariant getTempValue(QString name)
int removeAllLinkedObjects(QString id)
QList< QVariant > getPropertyValuesByObjectList(QString propName, QString propDatatype, bool checkInh, QString objIdList, int maxValues=0, QString domainName="all", bool getNullValues=false)
int removeLinkedObjects(QString id, QString linkedIdList)
QStringList getModelListByName(QString name, QString domain="geometry")
QStringList getListOfTempValues()
Definition: CoreAPI.h:32
QString getCalendarByTask(QString taskID, bool checkInh=true)
QStringList readTextFile(QString filename, bool ignoreLineBreakesInDoubleQuotes=false, QString codec=QString())
void resetDocumentMetaData(QString objId)
void itColorCodeNumber(QString propName, QString propDT, double intervalSize)
int calcOOBB(QString objIdList, double eps=0.001)
bool writeToFile(QString content)
int setVisualisationByID(QString taskIDList, QString visID)
int checkIntersection(QString objId1, QString objId2, double tolerance=-0.00001)
int setAsComposite(const QString &id, bool composite)
QString getRootContainerByName(QString modelName, QString rootContainerName)
void showWireModeSchema(QString name)
bool openFile(QString filePath, const QString &encoding=QString())
QStringList cutObject(QString parentId, QString objId, QVariantMap plane=QVariantMap())
QString dbGetFilepath() const
QString addPropertyTypeBookmark(QVariantMap bookmarkConfig)
int removeRangeFromRegion(QString regionId, double fromStation, double toStation, QString alignmentId=QString())
QStringList getTaskRestrictionsList()
int synchronizeDocumentContainer(QString containerId, QScriptValue callback=QScriptValue(), bool blockExecution=false)
QVariantMap getBoundingBoxCommon(QString objIdList)
int setCalendar(QString taskID, QString calendarID)
QVariantMap readCsvFile(QString filename, QString delimiter=";", QString quoteSign="\)
QVariantList findDocumentsByLocationGps(double lat, double lon, double distance, QStringList idList=QStringList())
QString findContainerByName(const QString &parentId, const QString &name, const QString &lookupDomain="all")
QString getContainerByName(QString parentId, QString name)
QVariantList findDocumentsByLocationRangeGps(QStringList gpsCoordinates, double distance, QStringList idList=QStringList())
void itCalcOOBB(double eps)
QVariantMap addPropertyScript(QString domain, QString pname, QString datatype, QString code=QString())
int setPropertyValueRepository(QString objId, QString propName, QString propDataType, QVariant value, bool createType=true)
bool checkIfFileExists(QString filePath)
QString addRegionToAlignment(QString alignmentId, QVariantMap setting)
QString getPropertyScriptCode(QString domain, QString pname, QString datatype) const
int setPropertyScriptCode(QString domain, QString pname, QString datatype, QString code)
QString createObjectFromXml(const QString &parentId, const QString &objectXML)
QList< QVariant > getPropertyTypeBookmarkList()
int setTransparency(QString objectIds, float defaultTransparency=0.95)
QVariantMap getMaterial(const QString &matId)
QList< QVariant > getAvailablePropertyValues(QString propName, QString propDatatype, int maxValues, QString domainName="geometry")
bool setPropertyTypeActive(QString pName, QString ptype, QString domain, bool active)
bool copyFile(QString fnFrom, QString fnTo)
int createDirectory(QString path, QString dirName)
QStringList getCalendarList()
int dbClearCache(const QString &propName, const QString &propType)
QVariantMap getPropertyScriptList() const
QByteArray readBinaryFile(QString filePath)
QVariantMap getOOBBCommon(QString objIdList)
bool moveFile(QString fnFrom, QString fnTo)
int removeFromSelectionSetGeometry(QString setId, QString objectIDList)
int removeVisualisation(QString taskIDList)
QVariantMap calcPropertyValuesOverTime(QString propName, QString propType, QVariantMap options)
bool isContainer(QString id)
bool appendToFile(QString filePath, const QString &content, const QString &encoding=QString())
int deleteModel(const QString &id)
int setAsOpening(QString objId, QString openingIDList)
int updateOOBBxy(QString objIdList, double eps=0.001)
int hasContact(QString objId1, QString objId2, QVariantMap options=QVariantMap())
Definition: CoreAPI.h:53
Definition: AutomationAPI.h:30
int deleteObjects(QString idList)
bool removeSelectionSet(QString selsetID)
int setBoQBreakdownStructure(QString boqModelID, QString templateStr)
QString getPropertyScriptFgColor(QString domain, QString pname, QString datatype) const
double checkOverlapOBB(QString id1, QString id2, double eps)
bool removeFile(QString filePath)
QStringList getRootNodeListSelectionSets(QString domainFilter="all")
int setPropertyScriptOptions(QString domain, QString pname, QString datatype, QVariantMap opt)
bool dbQueryExec(const QString &sqlQuery)
void setPropertyListAsJSON(QVariantMap propmap, QVariantMap opt)
QString readImageFile(QString filename, QString targetFormat="", bool applyExifRotation=false)
int calcOOBBxy(QString objIdList, double eps=0.001)
int deletePropertyType(QString propName, QString propDatatype, QString domainName="all")
QStringList getRootContainerList(QString modelName)
QString createContactObject(QString parentId, QString objId1, QString objId2, QString matId, QVariantMap options=QVariantMap())
QString getMaterialAsXmlByID(QString matId)
int writePropertyValueDB(const QString &objIdList, const QString &propName, const QString &propDataType, const QString &propDomain, const QVariant &value, bool createType=true)
int setTaskRestrictions(QString taskID, QString restrictionID)
QVariantList findDocumentsByLocationGk(double rw, double hw, double distance, QStringList idList=QStringList())
QString getMaterialIDByName(QString matName)
void updateMaterial(QString matId, QString xmlMat)
int removePropertyScript(QString domain, QString pname, QString datatype)
int itByFilter(QString propName, QString propDatatype, QString filterPattern, bool checkInh=true, QString domain="geometry")
int setLinkedObjects(const QString &elementID, const QString &IDList)
QStringList findDocumentsByDate(QDateTime start, QDateTime end, QStringList idList=QStringList(), bool useRef=false)
QString createSelectionSet(QString name, QString parentID=QString())
QString getTaskRestrictionsByName(QString name)
void lockObjects(QString idList)
int dbDeleteProperty(const QString &objIdList, const QString &propName, const QString &propType)
QVariantMap getPropertyListAsJSON(QVariantMap options)
int deleteProperty(QString objId, QString propName, QString propDatatype)
void itSetMaterial(QString matId)
int calcWorkInMinutes(QDateTime start, QDateTime finish, QString calendarID=QString())
void resetMaterials(bool updateUI=true)
QString getPropertyScriptBgColor(QString domain, QString pname, QString datatype) const
int csvOpen(QString filename, QString delimiter=";", QString quoteSign="\)
QString createColorSchema(QString setContainerId, QString name)
QString getTaskRestrictionsByTask(QString taskID, bool checkInh=true)
int addRangeToRegion(QString regionId, double fromStation, double toStation, QString alignmentId=QString())
int transformObject(QString objId, QString transformation)
void dbSetImmediateUpdate(bool)
bool writeBinaryFile(QString filePath, const QByteArray &data)
int activatePropertyTypeBookmark(QString bkmId)
void itSetupDbCache(QString propName, QString propType)
int setMaterialToObjects(QString matId, QString objectIds)
QString createWireModeSchema(QString ids, QString wmName, bool overwrite=false)
QString readTextFileAsString(QString filename, QString codec=QString())
int createPropertyType(const QString &propName, const QString &propDatatype, const QString &uomCode, bool isInh, int target, const QString &domainName="all")
void setObjectsToWireMode(QString ids, bool wired)
QString createSelectionSets(QString propertyTypes, QString rootName, QVariantMap config=QVariantMap())
void removeObjectListFromTooltip(QString idList, QString tooltipname)
QString getProjectionAsSvg(QString idList, QVariantMap options=QVariantMap())
QVariant dbQueryValue(int column)
int removeTaskRestrictions(QString taskID)
QStringList getRootNodeListByDomain(QString domainFilter="all")
int dbOpen(const QVariant connectionData=QVariant())
QVariantMap dbQueryRecordset(const QString &sqlQuery, const QString &key, int maxNumberOfRows=0)
void itUpdateOOBB(double eps)
int setPropertyScriptFgColor(QString domain, QString pname, QString datatype, QString code)
bool isIncludedIn(QString objId1, QString objId2)
void unlockObjects(QString idList)
bool activateColorSchemaByName(QString name)
void setName(QString objIdList, QString name)
QVariantMap getAsJSON(QString objId)
QVariantMap getVisualisationList()
QStringList getMaterialList()
QString createColorSchemaFromCurrentMaterials(QString name, bool updateExisting, QVariantMap options=QVariantMap())
int startProjectTransaction(const QString &domain="geometry")
QString createModel(QString name, bool createRootC=true, QString domain="geometry")
int setPropertyTypeMetaData(QString pName, QString ptype, QVariantMap metadata)
int updateSmartSets(QStringList smartSetIDs=QStringList())
QVariantList getDirectoryEntryList(QString dirPath, bool filesOnly=false, QString orderBy="Name")
QVariantMap getOOBBxyCommon(QString objIdList)
int itByObjectList(QString idList)
QVariantMap getModelMetaData(QString modelId)
QString getRootNodeByModel(QString modelId)
QStringList csvNextLine()
QStringList getColorSchemaList()
int isPointIncludedIn(double x, double y, double z, QString objId, double tol=1.e-5)
QVariantMap getPropertyTypeBookmarkByID(QString bookmarkId)
int setPropertyValueDB(const QString &objIdList, const QString &propName, const QString &propDataType, const QString &propDomain, const QVariant &value, bool createType=true)
QStringList getModelListByDomain(QString domainFilter="all")
int deleteColorSchema(QString namePattern)
void addObjectListToTooltip(QString idList, QString tooltipname)
QList< QVariant > getPropertyValues(QString propName, QString propDatatype, int maxValues=0, QString domainName="all", bool getNullValues=false)
bool hasElement(QString id)
void itCalcOOBBxy(double eps)
void itColorCode(QString propName, QString propDT)
void itUpdateOOBBxy(double eps)
QString createMaterial(QString matXml, QString modelId=QString())
int updateOOBB(QString obIDList, double eps=0.001)
int setPropertyScriptBgColor(QString domain, QString pname, QString datatype, QString code)
int dbAssertTable(const QString &tableName, const QStringList &columnsList)
QList< QVariant > itGetAvailablePropertyValues(QString propName, QString propDatatype, int maxValues)
void dbCheckOut(const QStringList &propList)
int removeAllRegionsFromAlignment(QString alignmentId)
QString mergeObjects(QString parentContainerId, QString idList, bool skipClosed=false, bool keepTransparency=false, bool keepCommonProperties=false, bool replaceParent=false)
int setTaskMode(QString taskID, int mode)
bool writeFile(QString filePath, const QString &content, const QString &encoding=QString())
int endProjectTransaction(const QString &domain="geometry")
double calcDistance(QString objId1, QString objId2)
QString createObject(QString parentId, QString name)
void setTempValue(QString name, QVariant value)

Created: Thu Jan 27 2022 10:19:56