Classes | Namespaces | Functions
StlStreamDeclarations.hpp File Reference

Declares stream operators for STL containers. More...

#include <array>
#include <deque>
#include <list>
#include <map>
#include <memory>
#include <set>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#include "Utilities/Requires.hpp"

Go to the source code of this file.

Classes

struct  tt::is_streamable< S, T, typename >
 Check if type T has operator<<(S, T) defined. More...
 

Namespaces

 tt
 A collection of useful type traits.
 

Functions

template<typename T >
std::ostreamoperator<< (std::ostream &os, const std::list< T > &v)
 Output the items of a std::list.
 
template<typename T >
std::ostreamoperator<< (std::ostream &os, const std::vector< T > &v)
 Output the items of a std::vector.
 
template<typename T >
std::ostreamoperator<< (std::ostream &os, const std::deque< T > &v)
 Output the items of a std::deque.
 
template<typename T , size_t N>
std::ostreamoperator<< (std::ostream &os, const std::array< T, N > &a)
 Output the items of a std::array.
 
template<typename... Args>
std::ostreamoperator<< (std::ostream &os, const std::tuple< Args... > &t)
 Stream operator for tuples.
 
template<typename K , typename V , typename H >
std::ostreamoperator<< (std::ostream &os, const std::unordered_map< K, V, H > &m)
 Output all the key, value pairs of a std::unordered_map.
 
template<typename K , typename V , typename C >
std::ostreamoperator<< (std::ostream &os, const std::map< K, V, C > &m)
 Output all the key, value pairs of a std::map.
 
template<typename T >
std::ostreamoperator<< (std::ostream &os, const std::unordered_set< T > &v)
 Output the items of a std::unordered_set.
 
template<typename T , typename C >
std::ostreamoperator<< (std::ostream &os, const std::set< T, C > &v)
 Output the items of a std::set.
 
template<typename T , Requires< tt::is_streamable< std::ostream, T, void >::value > = nullptr>
std::ostreamoperator<< (std::ostream &os, const std::unique_ptr< T > &t)
 Stream operator for std::unique_ptr.
 
template<typename T , Requires< tt::is_streamable< std::ostream, T, void >::value > = nullptr>
std::ostreamoperator<< (std::ostream &os, const std::shared_ptr< T > &t)
 Stream operator for std::shared_ptr.
 
template<typename T , typename U >
std::ostreamoperator<< (std::ostream &os, const std::pair< T, U > &t)
 Stream operator for std::pair.
 

Detailed Description

Declares stream operators for STL containers.