LDMX Software
AcceptRange Struct Reference

This Struct is to accept a certain range from a TTree accessible value. More...

#include <CommonUtils.h>

Public Member Functions

bool operator() (ULong64_t entry)
 returns true if value is within range
 

Public Attributes

std::vector< float > * value = nullptr
 
std::array< float, 2 > range = {0., 0.}
 

Detailed Description

This Struct is to accept a certain range from a TTree accessible value.

Definition at line 226 of file CommonUtils.h.

Member Function Documentation

◆ operator()()

bool AcceptRange::operator() ( ULong64_t entry)
inline

returns true if value is within range

Parameters
entrythe entry in the tree

Definition at line 233 of file CommonUtils.h.

233 {
234 if (value != nullptr) {
235 float v = value->at(entry);
236 return (range[0] <= v && range[1] > v);
237 }
238 return false;
239 }

Member Data Documentation

◆ range

std::array<float, 2> AcceptRange::range = {0., 0.}

Definition at line 229 of file CommonUtils.h.

229{0., 0.};

◆ value

std::vector<float>* AcceptRange::value = nullptr

Definition at line 227 of file CommonUtils.h.


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