Lines Matching refs:os

64                                 size_t count, ostream* os) {
72 *os << ' ';
74 *os << '-';
77 *os << text;
83 ostream* os) {
85 *os << count << "-byte object <";
94 PrintByteSegmentInObjectTo(obj_bytes, 0, count, os);
96 PrintByteSegmentInObjectTo(obj_bytes, 0, kChunkSize, os);
97 *os << " ... ";
100 PrintByteSegmentInObjectTo(obj_bytes, resume_pos, count - resume_pos, os);
102 *os << ">";
115 ostream* os) {
116 PrintBytesInObjectToImpl(obj_bytes, count, os);
146 static CharFormat PrintAsCharLiteralTo(Char c, ostream* os) {
149 *os << "\\0";
152 *os << "\\'";
155 *os << "\\\\";
158 *os << "\\a";
161 *os << "\\b";
164 *os << "\\f";
167 *os << "\\n";
170 *os << "\\r";
173 *os << "\\t";
176 *os << "\\v";
180 *os << static_cast<char>(c);
183 *os << "\\x" + String::FormatHexInt(static_cast<UnsignedChar>(c));
192 static CharFormat PrintAsStringLiteralTo(wchar_t c, ostream* os) {
195 *os << "'";
198 *os << "\\\"";
201 return PrintAsCharLiteralTo<wchar_t>(c, os);
207 static CharFormat PrintAsStringLiteralTo(char c, ostream* os) {
209 static_cast<wchar_t>(static_cast<unsigned char>(c)), os);
217 void PrintCharAndCodeTo(Char c, ostream* os) {
219 *os << ((sizeof(c) > 1) ? "L'" : "'");
220 const CharFormat format = PrintAsCharLiteralTo<UnsignedChar>(c, os);
221 *os << "'";
228 *os << " (" << static_cast<int>(c);
236 *os << ", 0x" << String::FormatHexInt(static_cast<UnsignedChar>(c));
238 *os << ")";
241 void PrintTo(unsigned char c, ::std::ostream* os) {
242 PrintCharAndCodeTo<unsigned char>(c, os);
244 void PrintTo(signed char c, ::std::ostream* os) {
245 PrintCharAndCodeTo<unsigned char>(c, os);
250 void PrintTo(wchar_t wc, ostream* os) {
251 PrintCharAndCodeTo<wchar_t>(wc, os);
263 const CharType* begin, size_t len, ostream* os) {
265 *os << kQuoteBegin;
273 *os << "\" " << kQuoteBegin;
275 is_previous_hex = PrintAsStringLiteralTo(cur, os) == kHexEscape;
277 *os << "\"";
287 const CharType* begin, size_t len, ostream* os) {
296 PrintCharsAsStringTo(begin, len - 1, os);
304 PrintCharsAsStringTo(begin, len, os);
305 *os << " (no terminating NUL)";
309 void UniversalPrintArray(const char* begin, size_t len, ostream* os) {
310 UniversalPrintCharArray(begin, len, os);
315 void UniversalPrintArray(const wchar_t* begin, size_t len, ostream* os) {
316 UniversalPrintCharArray(begin, len, os);
320 void PrintTo(const char* s, ostream* os) {
322 *os << "NULL";
324 *os << ImplicitCast_<const void*>(s) << " pointing to ";
325 PrintCharsAsStringTo(s, strlen(s), os);
337 void PrintTo(const wchar_t* s, ostream* os) {
339 *os << "NULL";
341 *os << ImplicitCast_<const void*>(s) << " pointing to ";
342 PrintCharsAsStringTo(s, std::wcslen(s), os);
349 void PrintStringTo(const ::string& s, ostream* os) {
350 PrintCharsAsStringTo(s.data(), s.size(), os);
354 void PrintStringTo(const ::std::string& s, ostream* os) {
355 PrintCharsAsStringTo(s.data(), s.size(), os);
360 void PrintWideStringTo(const ::wstring& s, ostream* os) {
361 PrintCharsAsStringTo(s.data(), s.size(), os);
366 void PrintWideStringTo(const ::std::wstring& s, ostream* os) {
367 PrintCharsAsStringTo(s.data(), s.size(), os);