C++ Library Extensions 2022.12.09
To help learn modern C++ programming
tpf::output Namespace Reference

Stream output operators are defined. More...

Namespaces

namespace  hidden
 Implementations in this scope is meant NOT to be accessed directly by the client.
 

Classes

struct  flush_stream
 
struct  new_line
 
struct  new_Line
 
struct  new_line_flush
 
struct  new_Line_flush
 
class  string_stream
 

Functions

template<typename CharType , typename T >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const tpf::bitwise::bit_pattern< T > &a)
 
template<typename CharType , typename... ElementTypes>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const tpf::types::any< ElementTypes... > &a)
 
template<typename CharType , typename T >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::optional< T > &opt)
 
template<typename CharType , auto N, auto D>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::ratio< N, D > &r)
 
template<typename CharType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::byte &b)
 
template<typename CharType , auto IndexValue>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::indexer_t< IndexValue > &indexer)
 
template<typename CharType , auto RowValue, auto ColumnValue>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::indexer_2d_t< RowValue, ColumnValue > &indexer)
 
template<typename CharType , auto HeightValue, auto RowValue, auto ColumnValue>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::indexer_3d_t< HeightValue, RowValue, ColumnValue > &indexer)
 
template<typename CharType , typename Type , int Tag>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::tag_type< Type, Tag > &ncw)
 
template<typename CharType , typename Type >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::initializer_list< Type > &init_list)
 
template<typename CharType , template< auto... >class ContainerType, auto... Ints>
std::basic_ostream< CharType > & operator>> (std::basic_ostream< CharType > &os, const ContainerType< Ints... > &seq)
 
template<typename CharType , typename T , auto FirstValue, auto LastValue, size_t CountValue, bool stack_order>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::hidden::st_sequence_info< T, FirstValue, LastValue, CountValue, stack_order > &seq)
 
template<typename CharType , typename T , T... Ints>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::integer_sequence< T, Ints... > &seq)
 
template<typename CharType , typename T , T... Ints>
std::basic_ostream< CharType > & operator>> (std::basic_ostream< CharType > &os, const std::integer_sequence< T, Ints... > &seq)
 
template<typename CharType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, types::TemplateCategory tc)
 
std::ostream & operator<< (std::ostream &os, const std::wstring &str)
 Feed std::wstring to std::ostream. More...
 
std::ostream & operator<< (std::ostream &os, const wchar_t *str)
 Feed const wchar_t* to std::ostream. More...
 
std::wostream & operator<< (std::wostream &os, const std::string &str)
 Feed std::string to std::wostream. More...
 
template<typename CharType , typename FirstType , typename SecondType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::pair< FirstType, SecondType > &pr)
 Feed std::pair<FirstType, SecondType> to std::basic_ostream<CharType> More...
 
template<typename CharType , typename... Types>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::tuple< Types... > &tuple)
 
template<typename CharType , typename Type , typename... Types>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::variant< Type, Types... > &variant)
 
template<typename CharType , typename Type_1 , typename Type_2 >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::unique_ptr< Type_1, Type_2 > &ptr)
 
template<typename CharType , typename Type >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::shared_ptr< Type > &ptr)
 
template<typename CharType , typename ElementType , size_t Size>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::array< ElementType, Size > &array)
 
template<typename CharType , template< typename, typename... > class ContainerType, typename Type , typename... Types>
hidden::enable_stream_if_not_string_t< CharType, ContainerType, Type, Types... > operator<< (std::basic_ostream< CharType > &os, const ContainerType< Type, Types... > &container)
 Feed STL container to std::basic_stream<CharType> More...
 
template<typename CharType , typename FirstType , typename SecondType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::array_wrapper_t< FirstType, SecondType > &array)
 
template<typename CharType , typename... Types>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::type_list_t< Types... > &typelist)
 
template<typename CharType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::exception &expt)
 
template<typename CharType , template< typename, typename... > class ContainerType, typename... ElementTypes>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::hidden::container_of_variants_class< ContainerType, ElementTypes... > &container)
 
template<typename CharType , template< typename, typename... > class ContainerType, typename... ElementTypes>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::hidden::container_of_tuples_class< ContainerType, ElementTypes... > &container)
 
template<typename CharType , typename ContainerType >
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::reverse_st< ContainerType > &container)
 
template<typename CharType , size_t ElementCount>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const std::byte(&array)[ElementCount])
 
template<typename CharType , typename ElementType , size_t ElementCount>
std::enable_if_t<!types::is_char_v< ElementType >, std::basic_ostream< CharType > & > operator<< (std::basic_ostream< CharType > &os, const ElementType(&array)[ElementCount])
 
template<typename CharType , typename ElementType , size_t ElementCount>
std::basic_ostream< CharType > & operator<< (std::basic_ostream< CharType > &os, const types::reverse_st< ElementType(&)[ElementCount]> &container)
 
constexpr new_line nl ()
 
constexpr new_Line nL ()
 
constexpr flush_stream flush ()
 
constexpr new_line_flush endl ()
 
constexpr new_Line_flush endL ()
 
template<typename T , typename = std::enable_if_t<!(types::is_tag_type_v<T> || types::is_numbers_type_v<T>)>>
sstreamoperator>> (sstream &os, T arg)
 
template<template< typename... > class TemplateType, typename... Types>
sstreamoperator>> (sstream &os, const TemplateType< Types... > &arg)
 
template<typename Type , int Tag>
sstreamoperator>> (sstream &os, const types::tag_type< Type, Tag > &)
 
template<template< auto... > class ContainerType, auto... Ints>
sstreamoperator>> (sstream &os, const ContainerType< Ints... > &arg)
 
template<template< typename T, T... > class TemplateType, typename Type , Type... Args, typename = std::enable_if_t<!types::is_tag_type_v<TemplateType<Type, Args...>>>>
sstreamoperator>> (sstream &os, const TemplateType< Type, Args... > &)
 
template<typename Type >
string_streamoperator< (string_stream &os, Type &&arg)
 
template<typename Type >
string_streamoperator> (string_stream &os, Type &&arg)
 
template<typename Type , size_t CacheSize>
sstreamoperator<< (sstream &os, const tpf::parallel::cache_wrapper< Type, CacheSize > &cw)
 

Detailed Description

Stream output operators are defined.

Function Documentation

◆ endl()

constexpr new_line_flush tpf::output::endl ( )
constexpr

Definition at line 840 of file tpf_output.hpp.

Here is the caller graph for this function:

◆ endL()

constexpr new_Line_flush tpf::output::endL ( )
constexpr

Definition at line 841 of file tpf_output.hpp.

◆ flush()

constexpr flush_stream tpf::output::flush ( )
constexpr

Definition at line 839 of file tpf_output.hpp.

◆ nl()

constexpr new_line tpf::output::nl ( )
constexpr

Definition at line 837 of file tpf_output.hpp.

Here is the caller graph for this function:

◆ nL()

constexpr new_Line tpf::output::nL ( )
constexpr

Definition at line 838 of file tpf_output.hpp.

◆ operator<()

template<typename Type >
string_stream & tpf::output::operator< ( string_stream os,
Type &&  arg 
)

Definition at line 1020 of file tpf_output.hpp.

◆ operator<<() [1/33]

template<typename Type , size_t CacheSize>
sstream & tpf::output::operator<< ( sstream os,
const tpf::parallel::cache_wrapper< Type, CacheSize > &  cw 
)

Definition at line 1079 of file tpf_output.hpp.

Here is the call graph for this function:

◆ operator<<() [2/33]

template<typename CharType , template< typename, typename... > class ContainerType, typename Type , typename... Types>
hidden::enable_stream_if_not_string_t< CharType, ContainerType, Type, Types... > tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const ContainerType< Type, Types... > &  container 
)

Feed STL container to std::basic_stream<CharType>

Template Parameters
CharTypefor std::basic_stream<CharType>
ContainerTypefor STL container
Typefor the first template parameter
Typesfor the rest of the template parameter
Parameters
osfor output stream, either std::ostream or std::wostream
containerof STL container class, ContainerType<Type, Types...>
Returns
enable_stream_if_not_string_t<CharType, ContainerType, Type, Types...>

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [3/33]

template<typename CharType , typename ElementType , size_t ElementCount>
std::enable_if_t<!types::is_char_v< ElementType >, std::basic_ostream< CharType > & > tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const ElementType(&)  array[ElementCount] 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [4/33]

template<typename CharType , typename ElementType , size_t Size>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::array< ElementType, Size > &  array 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [5/33]

template<typename CharType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::byte &  b 
)

Definition at line 974 of file tpf_output.hpp.

◆ operator<<() [6/33]

template<typename CharType , size_t ElementCount>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::byte(&)  array[ElementCount] 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [7/33]

template<typename CharType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::exception &  expt 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [8/33]

template<typename CharType , typename Type >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::initializer_list< Type > &  init_list 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [9/33]

template<typename CharType , typename T , T... Ints>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::integer_sequence< T, Ints... > &  seq 
)

Definition at line 128 of file tpf_output.hpp.

◆ operator<<() [10/33]

template<typename CharType , typename T >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::optional< T > &  opt 
)

Definition at line 1026 of file tpf_output.hpp.

◆ operator<<() [11/33]

template<typename CharType , typename FirstType , typename SecondType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::pair< FirstType, SecondType > &  pr 
)

Feed std::pair<FirstType, SecondType> to std::basic_ostream<CharType>

Template Parameters
CharTypefor std::basic_ostream<CharType>
FirstTypefor std::pair<FirstType, SecondType>
SecondTypefor std::pair<FirstType, SecondType>
Parameters
os— an instance of std::basic_stream<CharType>
pr— an instance of std::pair<FirstType, SecondType>
Returns
std::basic_ostream<CharType>&

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [12/33]

template<typename CharType , auto N, auto D>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::ratio< N, D > &  r 
)

Definition at line 974 of file tpf_output.hpp.

◆ operator<<() [13/33]

template<typename CharType , typename Type >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::shared_ptr< Type > &  ptr 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [14/33]

template<typename CharType , typename... Types>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::tuple< Types... > &  tuple 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [15/33]

template<typename CharType , typename Type_1 , typename Type_2 >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::unique_ptr< Type_1, Type_2 > &  ptr 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [16/33]

template<typename CharType , typename Type , typename... Types>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const std::variant< Type, Types... > &  variant 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [17/33]

template<typename CharType , typename T >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const tpf::bitwise::bit_pattern< T > &  a 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [18/33]

template<typename CharType , typename... ElementTypes>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const tpf::types::any< ElementTypes... > &  a 
)

Definition at line 1026 of file tpf_output.hpp.

◆ operator<<() [19/33]

template<typename CharType , typename FirstType , typename SecondType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::array_wrapper_t< FirstType, SecondType > &  array 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [20/33]

template<typename CharType , template< typename, typename... > class ContainerType, typename... ElementTypes>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::hidden::container_of_tuples_class< ContainerType, ElementTypes... > &  container 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [21/33]

template<typename CharType , template< typename, typename... > class ContainerType, typename... ElementTypes>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::hidden::container_of_variants_class< ContainerType, ElementTypes... > &  container 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [22/33]

template<typename CharType , typename T , auto FirstValue, auto LastValue, size_t CountValue, bool stack_order>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::hidden::st_sequence_info< T, FirstValue, LastValue, CountValue, stack_order > &  seq 
)

Definition at line 128 of file tpf_output.hpp.

◆ operator<<() [23/33]

template<typename CharType , auto RowValue, auto ColumnValue>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::indexer_2d_t< RowValue, ColumnValue > &  indexer 
)

Definition at line 974 of file tpf_output.hpp.

◆ operator<<() [24/33]

template<typename CharType , auto HeightValue, auto RowValue, auto ColumnValue>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::indexer_3d_t< HeightValue, RowValue, ColumnValue > &  indexer 
)

Definition at line 974 of file tpf_output.hpp.

◆ operator<<() [25/33]

template<typename CharType , auto IndexValue>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::indexer_t< IndexValue > &  indexer 
)

Definition at line 974 of file tpf_output.hpp.

◆ operator<<() [26/33]

template<typename CharType , typename ContainerType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::reverse_st< ContainerType > &  container 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [27/33]

template<typename CharType , typename ElementType , size_t ElementCount>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::reverse_st< ElementType(&)[ElementCount]> &  container 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [28/33]

template<typename CharType , typename Type , int Tag>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::tag_type< Type, Tag > &  ncw 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [29/33]

template<typename CharType , typename... Types>
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
const types::type_list_t< Types... > &  typelist 
)

Definition at line 287 of file tpf_output.hpp.

◆ operator<<() [30/33]

template<typename CharType >
std::basic_ostream< CharType > & tpf::output::operator<< ( std::basic_ostream< CharType > &  os,
types::TemplateCategory  tc 
)

Definition at line 207 of file tpf_output.hpp.

◆ operator<<() [31/33]

std::ostream & tpf::output::operator<< ( std::ostream &  os,
const std::wstring &  str 
)
inline

Feed std::wstring to std::ostream.

Parameters
osfor std::ostream
strfor std::wstring type
Returns
std::ostream&

Definition at line 261 of file tpf_output.hpp.

◆ operator<<() [32/33]

std::ostream & tpf::output::operator<< ( std::ostream &  os,
const wchar_t *  str 
)
inline

Feed const wchar_t* to std::ostream.

Parameters
osof type std::ostream
strof const wchar_t* type
Returns
std::ostream&

Definition at line 274 of file tpf_output.hpp.

◆ operator<<() [33/33]

std::wostream & tpf::output::operator<< ( std::wostream &  os,
const std::string &  str 
)
inline

Feed std::string to std::wostream.

Parameters
osof type std::wostream type
strof std::string type
Returns
std::wostream&

Definition at line 287 of file tpf_output.hpp.

◆ operator>()

template<typename Type >
string_stream & tpf::output::operator> ( string_stream os,
Type &&  arg 
)

Definition at line 1026 of file tpf_output.hpp.

◆ operator>>() [1/7]

template<template< auto... > class ContainerType, auto... Ints>
sstream & tpf::output::operator>> ( sstream os,
const ContainerType< Ints... > &  arg 
)

Definition at line 1006 of file tpf_output.hpp.

Here is the call graph for this function:

◆ operator>>() [2/7]

template<template< typename T, T... > class TemplateType, typename Type , Type... Args, typename = std::enable_if_t<!types::is_tag_type_v<TemplateType<Type, Args...>>>>
sstream & tpf::output::operator>> ( sstream os,
const TemplateType< Type, Args... > &   
)

Definition at line 1013 of file tpf_output.hpp.

Here is the call graph for this function:

◆ operator>>() [3/7]

template<template< typename... > class TemplateType, typename... Types>
sstream & tpf::output::operator>> ( sstream os,
const TemplateType< Types... > &  arg 
)

Definition at line 989 of file tpf_output.hpp.

◆ operator>>() [4/7]

template<typename Type , int Tag>
sstream & tpf::output::operator>> ( sstream os,
const types::tag_type< Type, Tag > &   
)

Definition at line 999 of file tpf_output.hpp.

◆ operator>>() [5/7]

template<typename T , typename = std::enable_if_t<!(types::is_tag_type_v<T> || types::is_numbers_type_v<T>)>>
sstream & tpf::output::operator>> ( sstream os,
arg 
)

Definition at line 981 of file tpf_output.hpp.

◆ operator>>() [6/7]

template<typename CharType , template< auto... >class ContainerType, auto... Ints>
std::basic_ostream< CharType > & tpf::output::operator>> ( std::basic_ostream< CharType > &  os,
const ContainerType< Ints... > &  seq 
)

Definition at line 175 of file tpf_output.hpp.

◆ operator>>() [7/7]

template<typename CharType , typename T , T... Ints>
std::basic_ostream< CharType > & tpf::output::operator>> ( std::basic_ostream< CharType > &  os,
const std::integer_sequence< T, Ints... > &  seq 
)

Definition at line 207 of file tpf_output.hpp.