CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Friends
edm::OStreamColumn Class Reference

#include <OStreamColumn.h>

Public Member Functions

template<typename T >
auto operator() (T const &t) const
 
 OStreamColumn (std::string const &t)
 
 OStreamColumn (std::string const &t, std::size_t const w)
 
std::size_t width () const
 

Private Attributes

std::string title_
 
std::size_t width_
 

Friends

std::ostream & operator<< (std::ostream &, OStreamColumn const &)
 
template<typename E >
std::ostream & operator<< (std::ostream &, OStreamColumnEntry< E > const &)
 

Detailed Description

Definition at line 53 of file OStreamColumn.h.

Constructor & Destructor Documentation

◆ OStreamColumn() [1/2]

OStreamColumn::OStreamColumn ( std::string const &  t)
explicit

Definition at line 7 of file OStreamColumn.cc.

7 : OStreamColumn{t, 0} {}

References submitPVValidationJobs::t.

◆ OStreamColumn() [2/2]

OStreamColumn::OStreamColumn ( std::string const &  t,
std::size_t const  w 
)
explicit

Definition at line 9 of file OStreamColumn.cc.

10  : title_{t}, width_{std::max(w, title_.size())} {}

References submitPVValidationJobs::t.

Member Function Documentation

◆ operator()()

template<typename T >
auto edm::OStreamColumn::operator() ( T const &  t) const
inline

Definition at line 59 of file OStreamColumn.h.

59  {
60  return OStreamColumnEntry<T>{*this, t};
61  }

References submitPVValidationJobs::t.

◆ width()

std::size_t edm::OStreamColumn::width ( ) const
inline

Definition at line 63 of file OStreamColumn.h.

63 { return width_; }

References width_.

Friends And Related Function Documentation

◆ operator<< [1/2]

std::ostream& operator<< ( std::ostream &  t,
OStreamColumn const &  c 
)
friend

Definition at line 12 of file OStreamColumn.cc.

12  {
13  t << std::setw(c.width_) << c.title_;
14  return t;
15  }

◆ operator<< [2/2]

template<typename E >
std::ostream& operator<< ( std::ostream &  t,
OStreamColumnEntry< E > const &  ce 
)
friend

Definition at line 78 of file OStreamColumn.h.

78  {
79  t << std::setw(ce.col.width_) << ce.t;
80  return t;
81  }

Member Data Documentation

◆ title_

std::string edm::OStreamColumn::title_
private

Definition at line 66 of file OStreamColumn.h.

◆ width_

std::size_t edm::OStreamColumn::width_
private

Definition at line 67 of file OStreamColumn.h.

Referenced by edm::operator<<(), and width().

OStreamColumn
edm::OStreamColumn::title_
std::string title_
Definition: OStreamColumn.h:66
w
const double w
Definition: UKUtility.cc:23
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
edm::OStreamColumn::width_
std::size_t width_
Definition: OStreamColumn.h:67
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
submitPVValidationJobs.t
string t
Definition: submitPVValidationJobs.py:644