Lines Matching refs:out

78 static void PrintLogPrefix(const LogContent& content, const LogFormat& format, std::ostream& out)  in PrintLogPrefix()  argument
93 out << tl.tm_zone << " "; in PrintLogPrefix()
97 out << (tl.tm_year + TM_YEAR_BASE) << "-"; in PrintLogPrefix()
99 out << setfill('0'); in PrintLogPrefix()
100 out << setw(DT_WIDTH) << (tl.tm_mon + 1) << "-" << setw(DT_WIDTH) << tl.tm_mday << " "; in PrintLogPrefix()
101 out << setw(DT_WIDTH) << tl.tm_hour << ":" << setw(DT_WIDTH) << tl.tm_min << ":"; in PrintLogPrefix()
102 out << setw(DT_WIDTH) << tl.tm_sec; in PrintLogPrefix()
104 out << setfill(' '); in PrintLogPrefix()
105 out << setw(MONO_WIDTH) << content.mono_sec; in PrintLogPrefix()
107 out << setfill(' '); in PrintLogPrefix()
108 out << setw(EPOCH_WIDTH) << content.tv_sec; in PrintLogPrefix()
110 out << "Invalid time format" << endl; in PrintLogPrefix()
114 out << "."; in PrintLogPrefix()
115 out << setfill('0'); in PrintLogPrefix()
117 out << setw(MSEC_WIDTH) << (content.tv_nsec / NS2MS); in PrintLogPrefix()
119 out << setw(USEC_WIDTH) << (content.tv_nsec / NS2US); in PrintLogPrefix()
121 out << setw(NSEC_WIDTH) << content.tv_nsec; in PrintLogPrefix()
123 out << "Invalid time accuracy format" << endl; in PrintLogPrefix()
129 out << setfill(' '); in PrintLogPrefix()
131 out << " " << setw(PID_WIDTH) << content.pid << " " << setw(PID_WIDTH) << content.tid; in PrintLogPrefix()
133 out << " " << LogLevel2ShortStr(content.level) << " "; in PrintLogPrefix()
135 out << GetLogTypePrefix(content.type); in PrintLogPrefix()
137 out << setfill('0'); in PrintLogPrefix()
138 out << hex << setw(DOMAIN_WIDTH) << ShortDomain(content.domain) << dec; in PrintLogPrefix()
140 out << "/" << content.tag << ": "; in PrintLogPrefix()
142 out << " " << content.tag << " "; in PrintLogPrefix()
146 static void AdaptWrap(const LogContent& content, const LogFormat& format, std::ostream& out) in AdaptWrap() argument
149 out << setfill(' '); in AdaptWrap()
150 out << std::setw(PREFIX_LEN + StringToWstring(content.tag).length()) << " "; in AdaptWrap()
152 PrintLogPrefix(content, format, out); in AdaptWrap()
156 void LogPrintWithFormat(const LogContent& content, const LogFormat& format, std::ostream& out) in LogPrintWithFormat() argument
160 out << "\x1B[38;5;" << GetColor(content.level) << "m"; in LogPrintWithFormat()
167 PrintLogPrefix(content, format, out); in LogPrintWithFormat()
180 out << tmp << endl; in LogPrintWithFormat()
184 AdaptWrap(content, format, out); in LogPrintWithFormat()
190 out << pHead; in LogPrintWithFormat()
195 out << "\x1B[0m"; in LogPrintWithFormat()
198 out << endl; in LogPrintWithFormat()