|
| Filter (const RangeType &range) |
| Constructor.
|
|
| Filter ()=default |
| Empty constructor.
|
|
RangeType | getRange (void) const |
| Getter of the range.
|
|
template<typename ... argsType> |
std::enable_if< all_same< argumentType, argsType... >::value, bool >::type | accept (const argsType &... args) const |
| The accept method of the filter: All the real computations are occuring in this method.
|
|
void | persist (TTree *t, const std::string &branchName) |
| Persist the range on a TTree.
|
|
void | setBranchAddress (TTree *t, const std::string &branchName) |
| Set the Branches addresses to this filter.
|
|
Filter< Variable, RangeType, BypassableFilter, Observer > | bypass (const bool &bypassVariable=false) |
| This method creates a new bypassable Filter with the same range of *this E.g.:
|
|
Filter< Variable, RangeType, ActivatableFilter, Observer > | enable (const bool &enableVariable=true) |
| Create a new activatable filter.
|
|
template<class otherObserver > |
Filter< Variable, RangeType, otherObserver > | observeLeaf (const otherObserver &) const |
| Function to observer of a filter.
|
|
template<class otherObserver > |
| Filter (const Filter< Variable, RangeType, otherObserver > &filter) |
| Copy constructor for filter.
|
|
std::string | getNameAndReference (std::vector< std::pair< char, void * > > *pointers=nullptr) |
| Getter for name of and reference to the range of the filters.
|
|
template<class Variable, class RangeType, class
Observer>
class Belle2::Filter< Variable, RangeType, Observer >
Basic Filter ///.
Basic building block of the Filter tools Example usage:
#include <tracking/trackFindingVXD/filterMap/filterFramework/SelectionVariable.h>
#include <tracking/trackFindingVXD/filterMap/filterFramework/UpperBoundedSet.h>
#include <tracking/trackFindingVXD/filterMap/filterFramework/Filter.h>
struct spacePoint{ float x; float y; float z; };
value(const TSpacePoint & p1, const TSpacePoint &p2){
return pow(p1.x - p2.x, 2) + pow(p1.y - p2.y, 2);
}
};
Filter<SquaredDistance2D, UpperBoundedSet, VoidObserver>
filter(UpperBoundedSet( 1.1 ));
spacePoint a( {0,0,0} ), b( {1,0,0} );
cout <<
filter.accept(a,b) << endl;
Base class of the selection variable objects used for pair filtering.
std::map< ExpRun, std::pair< double, double > > filter(const std::map< ExpRun, std::pair< double, double > > &runs, double cut, std::map< ExpRun, std::pair< double, double > > &runsRemoved)
filter events to remove runs shorter than cut, it stores removed runs in runsRemoved
will produce the output: true The Variable class will provide the static method value x( arg1, arg2) The RangeType object will provide the method contains to decide if x(arg1, arg2) is good The Observer will be notified of the actions via its static method notify
Definition at line 113 of file Filter.h.