PCL
|
A wrapper class that applies a binary function to pointers to objects. More...
#include <Indirect.h>
Public Member Functions | |
IndirectBinaryFunction (BF f) | |
IndirectBinaryFunction (const IndirectBinaryFunction< T1Ptr, T2Ptr, BF > &)=default | |
void | operator() (T1Ptr ptr1, T2Ptr ptr2) const |
The BF template argument represents a binary function type of the form:
void (*BF)( T1, T2 )
The T1Ptr and T2Ptr template arguments represent pointers to BF's first and second argument types, respectively. T1Ptr and T2Ptr are also the argument types of IndirectBinaryFunction::operator ()().
IndirectBinaryFunction can be used as BF, but acting on pointers to objects of the types T1 and T2.
Definition at line 131 of file Indirect.h.
|
inline |
Constructs an IndirectBinaryFunction to wrap a binary function f.
Definition at line 138 of file Indirect.h.
|
default |
Copy constructor.
|
inline |
Function call operator. Applies the wrapped binary function to *ptr1 and *ptr2.
If either ptr1 or ptr2 is nullptr, the function is not invoked and calling this member function has no effect.
Definition at line 155 of file Indirect.h.