Classes | Namespaces | Functions
ostream.h File Reference
#include "format.h"
#include <ostream>

Go to the source code of this file.

Classes

class  internal::formatbuf< Char >
 
struct  internal::test_stream< Char >
 
class  internal::is_streamable< T, Char >
 
struct  convert_to_int< T, Char, void >
 
struct  formatter< T, Char, typename std::enable_if< internal::is_streamable< T, Char >::value && !internal::format_type< typename buffer_context< Char >::type, T >::value >::type >
 

Namespaces

 internal
 

Functions

template<typename Char >
void internal::write (std::basic_ostream< Char > &os, basic_buffer< Char > &buf)
 
template<typename Char , typename T >
void internal::format_value (basic_buffer< Char > &buffer, const T &value)
 
template<typename Char >
void vprint (std::basic_ostream< Char > &os, basic_string_view< Char > format_str, basic_format_args< typename buffer_context< Char >::type > args)
 
template<typename S , typename... Args>
std::enable_if< internal::is_string< S >::value >::type print (std::basic_ostream< FMT_CHAR(S)> &os, const S &format_str, const Args &...args)
 

Function Documentation

template<typename S , typename... Args>
std::enable_if<internal::is_string<S>::value>::type print ( std::basic_ostream< FMT_CHAR(S)> &  os,
const S format_str,
const Args &...  args 
)
inline

Prints formatted data to the stream os.

Example**::

fmt::print(cerr, "Don't {}!", "panic");

Definition at line 146 of file ostream.h.

147  {
148  internal::checked_args<S, Args...> ca(format_str, args...);
149  vprint(os, to_string_view(format_str), *ca);
150 }
static QCString args
Definition: declinfo.cpp:674
void vprint(std::basic_ostream< Char > &os, basic_string_view< Char > format_str, basic_format_args< typename buffer_context< Char >::type > args)
Definition: ostream.h:128
string_view_t & to_string_view(spdlog::level::level_enum l) SPDLOG_NOEXCEPT
Definition: common.h:132
template<typename Char >
void vprint ( std::basic_ostream< Char > &  os,
basic_string_view< Char >  format_str,
basic_format_args< typename buffer_context< Char >::type args 
)
inline

Definition at line 128 of file ostream.h.

130  {
132  internal::vformat_to(buffer, format_str, args);
133  internal::write(os, buffer);
134 }
void write(std::basic_ostream< Char > &os, basic_buffer< Char > &buf)
Definition: ostream.h:76
buffer_context< Char >::type::iterator vformat_to(internal::basic_buffer< Char > &buf, basic_string_view< Char > format_str, basic_format_args< typename buffer_context< Char >::type > args)
Definition: format.h:3233
internal::basic_buffer< FMT_CHAR(S)> buffer
Definition: printf.h:757