ATLAS Offline Software
Loading...
Searching...
No Matches
IFilter< T > Class Template Referenceabstract

IFilter is the main interface to the filters. More...

#include <IFilter.h>

Inheritance diagram for IFilter< T >:
Collaboration diagram for IFilter< T >:

Public Member Functions

 IFilter ()
 Default constructor:
 IFilter (const IFilter< T > &rhs)
 Copy constructor:
virtual ~IFilter ()
 Destructor:
IFilter< T > & operator= (const IFilter< T > &rhs)
 Assignment operator:
virtual bool isAccepted (const T *element) const =0
 Main filter method.
bool operator() (const T *element) const
virtual void setFilter (const IFilterCuts *ifilter)=0
 Pure virtual function (to be overloaded by each of the children classes) to copy the cut properties of a given filter to another one.

Detailed Description

template<typename T>
class IFilter< T >

IFilter is the main interface to the filters.

It inherits from IFilterCuts to be able to copy a set of cut properties without explicitly knowing the concrete implementation of the derived filter.

Definition at line 30 of file IFilter.h.

Constructor & Destructor Documentation

◆ IFilter() [1/2]

template<typename T>
IFilter< T >::IFilter ( )
inline

Default constructor:

Definition at line 78 of file IFilter.h.

78 :
80{}
IFilterCuts()
Default constructor:
Definition IFilterCuts.h:69

◆ IFilter() [2/2]

template<typename T>
IFilter< T >::IFilter ( const IFilter< T > & rhs)
inline

Copy constructor:

Definition at line 83 of file IFilter.h.

83 :
85{}
IFilter is the main interface to the filters.
Definition IFilter.h:31

◆ ~IFilter()

template<typename T>
IFilter< T >::~IFilter ( )
inlinevirtual

Destructor:

Definition at line 88 of file IFilter.h.

88{}

Member Function Documentation

◆ isAccepted()

template<typename T>
virtual bool IFilter< T >::isAccepted ( const T * element) const
pure virtual

Main filter method.

This method takes the decision whether or not the filter has to accept the element. It returns true or false accordingly.

Implemented in ChargeFilter< T >, MomentumFilter< T >, and PdgIdFilter< T >.

◆ operator()()

template<typename T>
bool IFilter< T >::operator() ( const T * element) const
inline

Definition at line 101 of file IFilter.h.

102{
103 return isAccepted(element);
104}
virtual bool isAccepted(const T *element) const =0
Main filter method.

◆ operator=()

template<typename T>
IFilter< T > & IFilter< T >::operator= ( const IFilter< T > & rhs)
inline

Assignment operator:

Definition at line 91 of file IFilter.h.

92{
93 if ( this != &rhs ) {
95 }
96 return *this;
97}
IFilterCuts & operator=(const IFilterCuts &rhs)
Assignment operator:
Definition IFilterCuts.h:78

◆ setFilter()

virtual void IFilterCuts::setFilter ( const IFilterCuts * ifilter)
pure virtualinherited

Pure virtual function (to be overloaded by each of the children classes) to copy the cut properties of a given filter to another one.

It copies the properties of ifilter to the current IFilterCuts object.

Parameters
ifilterthe IFilterCuts which holds a set of properties one wants to copy to the current IFilterCuts object.

Implemented in AssocFilter< OBJ, ASSO >, AssocFilter< IParticle, IParticle >, ChargeFilter< T >, McVtxFilter, MomentumFilter< T >, and PdgIdFilter< T >.


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