Public Member Functions | Static Public Member Functions

OpenTissue::utility::ClassID< T > Class Template Reference

#include <utility_class_id.h>

Inheritance diagram for OpenTissue::utility::ClassID< T >:
OpenTissue::utility::ClassIDInterface

List of all members.

Public Member Functions

virtual size_t const class_id () const

Static Public Member Functions

static size_t const id ()

Detailed Description

template<class T>
class OpenTissue::utility::ClassID< T >

CRTP Implementation of the ClassIDInterface.

Usage: To enable class IDs for a custom class, simply inherite this class giving itself as the template argument.

Example:

   class SomeClass:
     public ClassID<SomeClass>
   { ... };
Template Parameters:
T The deriving class

Member Function Documentation

template<class T>
static size_t const OpenTissue::utility::ClassID< T >::id (  )  [inline, static]

Query the object ID.

Returns:
The object ID

Reimplemented in OpenTissue::utility::ClassIDCompositor< Base, Self >.


The documentation for this class was generated from the following file: