CMS 3D CMS Logo

Functions
VertexCategories.cc File Reference
#include <iostream>
#include "SimTracker/TrackHistory/interface/VertexCategories.h"

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &os, VertexCategories const &classifier)
 

Function Documentation

◆ operator<<()

std::ostream& operator<< ( std::ostream &  os,
VertexCategories const &  classifier 
)

Definition at line 51 of file VertexCategories.cc.

51  {
52  bool init = true;
53 
54  const VertexCategories::Flags &flags = classifier.flags();
55 
56  // Print out the classification for the track
57  for (std::size_t index = 0; index < flags.size(); ++index) {
58  if (flags[index]) {
59  if (init) {
61  init = false;
62  } else
63  os << "::" << VertexCategories::Names[index];
64  }
65  }
66  os << std::endl;
67 
68  return os;
69 }

References VertexCategories::flags(), HLT_2018_cff::flags, and VertexCategories::Names.

VertexCategories::Names
static const char *const Names[]
Name of the different categories.
Definition: VertexCategories.h:52
init
Definition: init.py:1
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
HLT_2018_cff.flags
flags
Definition: HLT_2018_cff.py:11758
VertexCategories::Flags
std::vector< bool > Flags
Main types associated to the class.
Definition: VertexCategories.h:55