- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Member Functions

# CRTP_IndexType< Derived > Class Template Reference

Search for all occurrences

## Detailed Description

### template<typename Derived>
class adsk::Data::CRTP_IndexType< Derived >

This CRTP (Curiously Recurring Template Pattern) class implements some shared methods which all derived classes can use, and for whom the implementations use the same pattern.

For all derived index types use this declaration for the class:

class METADATA_EXPORT MyIndex : public CRTP_IndexType<MyIndex> { ... }

This will automatically instantiate a common clone() method as well as establishing the abstract interface each index type needs to implement.

`#include <adskDataIndexType.h>`

Inheritance diagram for CRTP_IndexType< Derived >:
[legend]

List of all members.

## Public Member Functions
virtual IndexType * | clone () const
| Create a duplicate of this object.
virtual std::string | typeName () const
| Get the unique name of this index type.

## Member Function Documentation

virtual IndexType* clone | ( |  | ) | const`[inline, virtual]`

Search for all occurrences

Create a duplicate of this object.

This is virtual so that derived types create the correct type of object.

Returns:
  Pointer to copy of this object

Implements IndexType.

virtual std::string typeName | ( |  | ) | const`[inline, virtual]`

Search for all occurrences

Get the unique name of this index type.

Returns:
  String containing the index type name

Implements IndexType.