DataModel_detail::CompareAndPrint Class Reference

Helper for remove_duplicates. More...

#include <CompareAndPrint.h>

List of all members.

Public Member Functions

 CompareAndPrint (bool quiet)
 Constructor.
template<typename Element >
bool operator() (Element *f, Element *s) const
 Compare two pointers. Maybe print a complaint if we find a duplicate.
void warn (const std::type_info &ti, const void *f) const
 Duplicate elements were found; print a warning.

Detailed Description

Helper for remove_duplicates.

Functor to compare two pointers and optionally print a complaint if they're the same.


Constructor & Destructor Documentation

DataModel_detail::CompareAndPrint::CompareAndPrint ( bool  quiet  )  [inline]

Constructor.

Parameters:
quiet If false, then print a complaint if duplicate pointers are found.

Member Function Documentation

template<typename Element >
bool DataModel_detail::CompareAndPrint::operator() ( Element *  f,
Element *  s 
) const [inline]

Compare two pointers. Maybe print a complaint if we find a duplicate.

Parameters:
f First pointer to compare.
s Second pointer to compare.
Returns:
The result of the comparison.
void DataModel_detail::CompareAndPrint::warn ( const std::type_info &  ti,
const void *  f 
) const

Duplicate elements were found; print a warning.

Parameters:
ti type_info for the element.
f The element pointer.

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 1 Dec 2017 for RootCore Packages by  doxygen 1.6.1