API Reference > OdDAI Namespace > Classes > Attribute Class > Attribute Constructor > Attribute::Attribute Constructor (OdAnsiString, Entity *)
Attribute::Attribute Constructor (OdAnsiString, Entity *)
Syntax
C++
Attribute(OdAnsiString name, Entity * parentEntity = NULL);
Parameters 
Description 
OdAnsiString name 
[in] A pointer to a string that contains the attribute name.  
optional 
[in] A flag that determines whether the value of the created attribute is optional (equal to true) or mandatory (equal to false). 

Creates a new attribute object with specified parameters.

Copyright (c) 2002-2020. Open Design Alliance. All rights reserved.