sdaiPutAttr

...

Syntax

//   Visual Studio for Windows
public:
void __declspec(dllexport) __stdcall sdaiPutAttr(
            __int64 instance,
            void    * attribute,
            __int64 valueType,
            void    * value
        );

//   Linux, OS-X and non-Visual Studio Windows solutions
public:
void sdaiPutAttr(
            int64_t instance,
            void    * attribute,
            int64_t valueType,
            void    * value
        );    

Property instance

Size: 64 bit / 8 byte (value)
Handle of an instance within an IFC file, for example #31313 = IFCWALLSTANDARDCASE(...)

Property attribute

Size: 64 bit / 8 byte (value)
A handle to the an attribute of a certain entity, for example attribute Name of entity IFCROOT.

Property valueType

Size: 64 bit / 8 byte (value)
Type of the value, for example sdaiSTRING, sdaiINSTANCE, sdaiREAL, ...

Property value

Size: 64 bit / 8 byte (reference)
Placeholder for the information, formatting depending on defined valueType.

Examples

Here you can find code snippits that show how the API call sdaiPutAttr can be used.

__int64 * localPutAttrBN(__int64 instance, char * attributeName)
{
    //
    //  This function is an alternative to the API call sdaiCreateAggrBN()
    //  based on sdaiCreateAggr().
    //
    //  Use of sdaiCreateAggr() can lead to performance improvement compared to sdaiCreateAggrBN().
    //
    __int64 instanceType = sdaiGetInstanceType(instance);
    void    * attribute = sdaiGetAttrDefinition(instanceType, attributeName);

    return  sdaiPutAttr(instance, attribute);
}