ezEngine  Milestone 7
ezHashableStruct< DERIVED > Class Template Reference

This class provides a base class for hashable structs (e.g. descriptor objects). More...

#include <HashableStruct.h>

Public Member Functions

EZ_FORCE_INLINE ezUInt32 CalculateHash () const
 Calculates the (CRC32) hash of the struct and returns it.
 

Detailed Description

template<typename DERIVED>
class ezHashableStruct< DERIVED >

This class provides a base class for hashable structs (e.g. descriptor objects).

To help with this there are two parts: 1) memclear on initialization. 2) a CalculateHash() function calculating the CRC32 hash of the object.

You can make your own struct hashable by deriving from ezHashableStruct providing the type of your class / struct as the template parameter.


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