Public Types | Public Member Functions | Public Attributes | List of all members
dune::AnaRootParserDataStruct::VertexDataStruct Class Reference

Public Types

template<typename T >
using VertexData_t = std::vector< T >
 

Public Member Functions

 VertexDataStruct ()
 
 VertexDataStruct (size_t maxVertices)
 
void Clear ()
 
void SetMaxVertices (size_t maxVertices)
 
void Resize (size_t nVertices)
 
void SetAddresses (TTree *pTree, std::string tracker, bool isCosmics)
 
size_t GetMaxVertices () const
 

Public Attributes

size_t MaxVertices
 maximum number of storable vertices More...
 
Short_t nvtx
 
VertexData_t< Short_t > vtxId
 
VertexData_t< Float_t > vtxx
 
VertexData_t< Float_t > vtxy
 
VertexData_t< Float_t > vtxz
 
VertexData_t< Short_t > vtxhasPFParticle
 
VertexData_t< Short_t > vtxPFParticleID
 

Detailed Description

Definition at line 327 of file AnaRootParser_module.cc.

Member Typedef Documentation

Definition at line 330 of file AnaRootParser_module.cc.

Constructor & Destructor Documentation

dune::AnaRootParserDataStruct::VertexDataStruct::VertexDataStruct ( )
inline

Definition at line 343 of file AnaRootParser_module.cc.

dune::AnaRootParserDataStruct::VertexDataStruct::VertexDataStruct ( size_t  maxVertices)
inline

Definition at line 344 of file AnaRootParser_module.cc.

Member Function Documentation

void dune::AnaRootParserDataStruct::VertexDataStruct::Clear ( )

Definition at line 2297 of file AnaRootParser_module.cc.

2297  {
2299  nvtx = -999;
2300 
2301  FillWith(vtxId , -999 );
2302  FillWith(vtxx , -999 );
2303  FillWith(vtxy , -999 );
2304  FillWith(vtxz , -999 );
2305  FillWith(vtxhasPFParticle, -1 );
2306  FillWith(vtxPFParticleID , -1 );
2307 }
size_t MaxVertices
maximum number of storable vertices
size_t dune::AnaRootParserDataStruct::VertexDataStruct::GetMaxVertices ( ) const
inline

Definition at line 351 of file AnaRootParser_module.cc.

351 { return MaxVertices; }
size_t MaxVertices
maximum number of storable vertices
void dune::AnaRootParserDataStruct::VertexDataStruct::Resize ( size_t  nVertices)

Definition at line 2285 of file AnaRootParser_module.cc.

2286 {
2287  MaxVertices = nVertices;
2288  vtxId.resize(MaxVertices);
2289  vtxx.resize(MaxVertices);
2290  vtxy.resize(MaxVertices);
2291  vtxz.resize(MaxVertices);
2292 
2293  vtxhasPFParticle.resize(MaxVertices);
2294  vtxPFParticleID.resize(MaxVertices);
2295 }
size_t MaxVertices
maximum number of storable vertices
void dune::AnaRootParserDataStruct::VertexDataStruct::SetAddresses ( TTree *  pTree,
std::string  tracker,
bool  isCosmics 
)

Definition at line 2309 of file AnaRootParser_module.cc.

2311  {
2312  if (MaxVertices == 0) return; // no tracks, no tree!
2313 
2315 
2316  AutoResettingStringSteam sstr;
2317 
2318  std::string VertexLabel = alg;
2319  std::string BranchName;
2320  /*
2321  BranchName = "nvtx_" + VertexLabel;
2322  CreateBranch(BranchName, &nvtx, BranchName + "/S");
2323  std::string NVertexIndexStr = "[" + BranchName + "]";
2324 
2325  BranchName = "vtxId_" + VertexLabel;
2326  CreateBranch(BranchName, vtxId, BranchName + NVertexIndexStr + "/S");
2327 
2328  BranchName = "vtxx_" + VertexLabel;
2329  CreateBranch(BranchName, vtxx, BranchName + NVertexIndexStr + "/F");
2330 
2331  BranchName = "vtxy_" + VertexLabel;
2332  CreateBranch(BranchName, vtxy, BranchName + NVertexIndexStr + "/F");
2333 
2334  BranchName = "vtxz_" + VertexLabel;
2335  CreateBranch(BranchName, vtxz, BranchName + NVertexIndexStr + "/F");
2336 
2337  BranchName = "vtxhasPFParticle_" + VertexLabel;
2338  CreateBranch(BranchName, vtxhasPFParticle, BranchName + NVertexIndexStr + "/S");
2339 
2340  BranchName = "vtxPFParticleID_" + VertexLabel;
2341  CreateBranch(BranchName, vtxPFParticleID, BranchName + NVertexIndexStr + "/S");
2342  */
2343 }
Little helper functor class to create or reset branches in a tree.
std::string string
Definition: nybbler.cc:12
size_t MaxVertices
maximum number of storable vertices
void dune::AnaRootParserDataStruct::VertexDataStruct::SetMaxVertices ( size_t  maxVertices)
inline

Definition at line 346 of file AnaRootParser_module.cc.

347  { MaxVertices = maxVertices; Resize(MaxVertices); }
size_t MaxVertices
maximum number of storable vertices

Member Data Documentation

size_t dune::AnaRootParserDataStruct::VertexDataStruct::MaxVertices

maximum number of storable vertices

Definition at line 332 of file AnaRootParser_module.cc.

Short_t dune::AnaRootParserDataStruct::VertexDataStruct::nvtx

Definition at line 334 of file AnaRootParser_module.cc.

VertexData_t<Short_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxhasPFParticle

Definition at line 340 of file AnaRootParser_module.cc.

VertexData_t<Short_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxId

Definition at line 335 of file AnaRootParser_module.cc.

VertexData_t<Short_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxPFParticleID

Definition at line 341 of file AnaRootParser_module.cc.

VertexData_t<Float_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxx

Definition at line 336 of file AnaRootParser_module.cc.

VertexData_t<Float_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxy

Definition at line 337 of file AnaRootParser_module.cc.

VertexData_t<Float_t> dune::AnaRootParserDataStruct::VertexDataStruct::vtxz

Definition at line 338 of file AnaRootParser_module.cc.


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