mmCEsim 0.3.0
mmWave Channel Estimation Simulation
term.h File Reference

Terminal Color and Style Control. More...

#include <cstdlib>
#include <iostream>
#include <string>
Include dependency graph for term.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  TermOpt
 Terminal option. More...
 
class  Term
 Control terminal colors and styles. More...
 

Functions

static std::ostream & operator<< (std::ostream &out, const TermOpt &opt)
 Use the TermOpt in ostream. More...
 
static TermOpt operator+ (const TermOpt &o1, const TermOpt &o2)
 Combine two TermOpt configurations. More...
 
static TermOpt operator| (const TermOpt &o1, const TermOpt &o2)
 Combine two TermOpt configurations. More...
 

Detailed Description

Terminal Color and Style Control.

Author
Wuqiong Zhao (wqzha.nosp@m.o@se.nosp@m.u.edu.nosp@m..cn)
Version
0.3.0
Date
2024-01-21

Function Documentation

◆ operator+()

static TermOpt operator+ ( const TermOpt o1,
const TermOpt o2 
)
inlinestatic

Combine two TermOpt configurations.

Parameters
o1The first TermOpt configuration.
o2The second TermOpt configuration.
Returns
(TermOpt) The added result.

◆ operator<<()

static std::ostream & operator<< ( std::ostream &  out,
const TermOpt opt 
)
inlinestatic

Use the TermOpt in ostream.

Parameters
outThe ostream.
optThe TermOpt object with configuration.
Returns
(std::ostream&) The ostream.

◆ operator|()

static TermOpt operator| ( const TermOpt o1,
const TermOpt o2 
)
inlinestatic

Combine two TermOpt configurations.

This is the same as operator+.

Note
This should be used with caution since the priority is lower than the << operator.
Parameters
o1The first TermOpt configuration.
o2The second TermOpt configuration.
Returns
(TermOpt) The added result.