NVIDIA Iray API Home  Up
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
mi::neuraylib::Tag Class Reference

A tag represents a unique identifier for database elements in the database. More...

Inheritance diagram for mi::neuraylib::Tag:
Inheritance graph
[legend]

Public Types

typedef bool(Tag::*  bool_conversion_support )() const
  Helper typedef. More...
 

Public Member Functions

  Tag ()
  Constructor. More...
 
  Tag (Tag_struct tag_struct)
  Constructor from the underlying storage type. More...
 
bool  is_valid () const
  Returns true if the tag is valid, i.e., is not equal to NULL_TAG. More...
 
  operator bool_conversion_support () const
  Helper function for the conversion of a Tag to a bool. More...
 

Additional Inherited Members

- Public Attributes inherited from mi::neuraylib::Tag_struct
Uint32  id
  The actual ID of the tag. More...
 

Detailed Description

A tag represents a unique identifier for database elements in the database.

See Also
the underlying POD type mi::neuraylib::Tag_struct.

Member Typedef Documentation

typedef bool(Tag::* mi::neuraylib::Tag::bool_conversion_support)() const

Helper typedef.

This typedef represents the type of is_valid() used by the bool_conversion_support() operator.

Constructor & Destructor Documentation

mi::neuraylib::Tag::Tag ( )
inline

Constructor.

Sets the ID initially to 0, i.e., creates an invalid tag.

mi::neuraylib::Tag::Tag ( Tag_struct  tag_struct)
inline

Constructor from the underlying storage type.

Member Function Documentation

bool mi::neuraylib::Tag::is_valid ( ) const
inline

Returns true if the tag is valid, i.e., is not equal to NULL_TAG.

mi::neuraylib::Tag::operator bool_conversion_support ( ) const
inline

Helper function for the conversion of a Tag to a bool.

This helper function allows to write

Tag t (...);
if (t) ...

instead of

Tag t (...);
if (t.is_valid()) ...