Share via


CDefaultCompareTraits::CompareElements

Call this function to compare two elements for equality.

static bool CompareElements( 
   const T& element1, 
   const T& element2  
);

Parameters

  • element1
    The first element.

  • element2
    The second element.

Return Value

Returns true if the elements are equal, false otherwise.

Remarks

The default implementation of this function is the equality (==) operator. For objects other than simple data types, this function may need to be overridden.

Requirements

Header: atlcoll.h

See Also

Reference

CDefaultCompareTraits Class

CDefaultCompareTraits::CompareElementsOrdered

Other Resources

CDefaultCompareTraits Members