Go to the source code of this file.
◆ operator<<()
std::ostream& operator<< |
( |
std::ostream & |
s, |
|
|
const DcsStatus & |
c |
|
) |
| |
Pretty-print operator for DcsStatus.
Definition at line 51 of file DcsStatus.cc.
References c, mps_fire::i, mps_splice::line, DcsStatus::nPartitions, DcsStatus::partitionList, DcsStatus::partitionName, and alignCSCRings::s.
52 constexpr
size_t kZeitBufferSize = 128;
53 char zeit[kZeitBufferSize];
54 constexpr
size_t kLineBufferSize = 157;
55 char line[kLineBufferSize];
58 s <<
"DcsStatus Version: " <<
c.version() <<
" SourceID: " <<
c.sourceID() << std::endl;
60 timespec ts =
c.collectionTime();
61 hora = gmtime(&ts.tv_sec);
62 strftime(zeit, kZeitBufferSize,
"%Y.%m.%d %H:%M:%S", hora);
63 snprintf(
line, kLineBufferSize,
" CollectionTime: %s.%9.9d", zeit, (
int)ts.tv_nsec);
64 s <<
line << std::endl;
68 " TrigType: %d EventID: %d BunchNumber: %d",
72 s <<
line << std::endl;
75 line, kLineBufferSize,
" MagnetCurrent: %e MagnetTemperature: %e",
c.magnetCurrent(),
c.magnetTemperature());
76 s <<
line << std::endl;
78 snprintf(
line, kLineBufferSize,
" Ready: %d 0x%8.8X",
c.ready(),
c.ready());
79 s <<
line << std::endl;
87 s <<
line << std::endl;
static const char *const partitionName[]
static const int partitionList[]