sdaiPutADBTypePath
Syntax
public const string ifcenginedll = @"ifcengine.dll"; [DllImport(IFCEngineDLL, EntryPoint = "sdaiPutADBTypePath")] public static extern void sdaiPutADBTypePath(int_t ADB, int_t pathCount, string path); [DllImport(IFCEngineDLL, EntryPoint = "sdaiPutADBTypePath")] public static extern void sdaiPutADBTypePath(int_t ADB, int_t pathCount, byte[] path);
Property ADB
Size: 32 bit / 4 byte (reference)Property pathCount
Size: 32 bit / 4 byte (value)Property path
Size: 32 bit / 4 byte (reference)
Example (based on pure API calls)
Here you can find code snippits that show how the API call sdaiPutADBTypePath can be used.
using RDF; // include at least engine.cs within your solution // // #13131 = IFCMEASUREWITHUNIT(IFCPLANEANGLEMEASURE(1.745E-2), #31313); // #31313 = IFCSIUNIT(*, .PLANEANGLEUNIT., $, .RADIAN.); // Int64 buildSIUnitInstance(Int64 model, string UnitType, string Prefix, string Name) { // #31313 = IFCSIUNIT(*, .PLANEANGLEUNIT., $, .RADIAN.); Int64 ifcSIUnitInstance = ifcengine.sdaiCreateInstanceBN(model, "IFCSIUNIT"); ifcengine.sdaiPutAttrBN(ifcSIUnitInstance, "UnitType", ifcengine.sdaiENUM, UnitType); if (Prefix != null) { ifcengine.sdaiPutAttrBN(ifcSIUnitInstance, "Prefix", ifcengine.sdaiENUM, Prefix); } ifcengine.sdaiPutAttrBN(ifcSIUnitInstance, "Name", ifcengine.sdaiENUM, Name); return ifcSIUnitInstance; } Int64 buildMeasureWithUnitInstance(Int64 model) { Int64 valueComponentADB; double valueComponent = 0.01745; // #13131 = IFCMEASUREWITHUNIT(IFCPLANEANGLEMEASURE(1.745E-2), #31313); Int64 ifcMeasureWithUnitInstance = ifcengine.sdaiCreateInstanceBN(model, "IFCMEASUREWITHUNIT"); valueComponentADB = ifcengine.sdaiCreateADB(ifcengine.sdaiREAL, ref valueComponent); ifcengine.sdaiPutADBTypePath(valueComponentADB, 1, "IFCPLANEANGLEMEASURE"); ifcengine.sdaiPutAttrBN(ifcMeasureWithUnitInstance, "ValueComponent", ifcengine.sdaiADB, ref valueComponentADB); ifcengine.sdaiPutAttrBN(ifcMeasureWithUnitInstance, "UnitComponent", ifcengine.sdaiINSTANCE, buildSIUnitInstance(model, "PLANEANGLEUNIT", null, "RADIAN")); return ifcMeasureWithUnitInstance; }