API Reference > OdDAI Namespace > Classes > Entity Class > Entity Methods > Entity::findAttribute Method
Entity::findAttribute Method
Syntax
C++
const AttributePtr findAttribute(const char * attrName) const;
Parameters 
Description 
const char * attrName 
[in] An ANSI string that contains the name of the attribute to find.  

A smart pointer to the found attribute definition; if the attribute is not found then a NULL smart pointer is returned.

Searches for an attribute definition with a specified name for the entity definition and all its supertypes.

The search of the attribute is performed starting from the most base entity definition towards its subtypes (to this entity definition).

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