A device detection library that is used natively or by 51Degrees products

FiftyoneDegrees::Common::EntityMetaData< K > Class Template Reference

Detailed Description

template<class K>
class FiftyoneDegrees::Common::EntityMetaData< K >

Base class for any entity meta data.

All meta data classes should extend this class.

A meta data instance is immutable once it has been instantiated. An instance is also comparable to another via the == and != operators, provided the type K is properly implemented.

Template Parameters
Kkey type for the entity which must be unique e.g. string is used for property meta data where the unique key is the name of the property. The type K must implement the < and == operators.

Inheritance diagram for FiftyoneDegrees::Common::EntityMetaData< K >:

[legend]

Public Member Functions

Constructors

 EntityMetaData (K key)
 Construct a new instance with the key provided.

Getters

K getKey () const
 Get the unique key for this entity instance.

Operators

const bool operator== (const EntityMetaData< K > other) const
 Returns true is the two entities share the same unique key.
const bool operator!= (const EntityMetaData< K > other) const
 Returns true is the two entities do not share the same unique key.

Constructor & Destructor Documentation

◆ EntityMetaData()

template<class K>
FiftyoneDegrees::Common::EntityMetaData< K >::EntityMetaData ( K key)
inline

Construct a new instance with the key provided.

Parameters
keyof type K

Member Function Documentation

◆ getKey()

template<class K>
K FiftyoneDegrees::Common::EntityMetaData< K >::getKey ( ) const
inline

Get the unique key for this entity instance.

Returns
key of type K

◆ operator!=()

template<class K>
const bool FiftyoneDegrees::Common::EntityMetaData< K >::operator!= ( const EntityMetaData< K > other) const
inline

Returns true is the two entities do not share the same unique key.

Parameters
otherthe other instance to compare
Returns
true if they are not equal

◆ operator==()

template<class K>
const bool FiftyoneDegrees::Common::EntityMetaData< K >::operator== ( const EntityMetaData< K > other) const
inline

Returns true is the two entities share the same unique key.

Parameters
otherthe other instance to compare
Returns
true if they are equal

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