Main Page
Namespaces
Classes
Package Documentation
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
CommonTools
Utils
interface
PointerComparator.h
Go to the documentation of this file.
1
#ifndef CommonTools_Utils_PointerComparator_h
2
#define CommonTools_Utils_PointerComparator_h
3
14
#include "
FWCore/Utilities/interface/EDMException.h
"
15
16
template
<
typename
C>
17
struct
PointerComparator
{
18
typedef
typename
C::first_argument_type
first_argument_type
;
19
typedef
typename
C::second_argument_type
second_argument_type
;
20
bool
operator()
(
const
first_argument_type
* t1,
const
second_argument_type
* t2 )
const
{
21
if
( t1 == 0 || t2 == 0 )
22
throw
edm::Exception
(
edm::errors::NullPointerError
)
23
<<
"PointerComparator: passed null pointer."
;
24
return
cmp
( *t1, *t2 );
25
}
26
C
cmp
;
27
};
28
29
30
#endif
PointerComparator::cmp
C cmp
Definition:
PointerComparator.h:26
funct::C
C
Definition:
Factorize.h:141
PointerComparator::operator()
bool operator()(const first_argument_type *t1, const second_argument_type *t2) const
Definition:
PointerComparator.h:20
EDMException.h
PointerComparator
Definition:
PointerComparator.h:17
PointerComparator::first_argument_type
C::first_argument_type first_argument_type
Definition:
PointerComparator.h:18
edm::hlt::Exception
error
Definition:
HLTenums.h:24
PointerComparator::second_argument_type
C::second_argument_type second_argument_type
Definition:
PointerComparator.h:19
edm::errors::NullPointerError
Definition:
EDMException.h:44
Generated for CMSSW Reference Manual by
1.8.5