All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Classes | Namespaces | Functions
DumpUtils.h File Reference

Utilities to dump objects into a stream. More...

#include <string>
#include <sstream>
#include <type_traits>

Go to the source code of this file.

Classes

struct  lar::dump::ArrayDumper< Array >
 Dumps the first N elements of an array. More...
 
struct  lar::dump::ArrayDumper< T * >
 
struct  lar::dump::VectorDumper< Vector >
 Manipulator managing the dump of the vector content into a stream. More...
 
struct  lar::dump::VectorDumper< T * >
 
struct  lar::dump::VectorDumper< T[3]>
 

Namespaces

 lar
 LArSoft-specific namespace.
 
 lar::dump
 Namespace for LArSoft dumping utilities.
 
 lar::dump::details
 

Functions

template<typename Coll >
auto lar::dump::details::ptr_cbegin (Coll const &v)
 
template<typename T >
std::add_const_t< T > * lar::dump::details::ptr_cbegin (T *ptr)
 
template<typename Stream , typename Array >
void lar::dump::details::dumpArray (Stream &&out, Array &&a, size_t n)
 Inserts n of elements of a in the specified stream. More...
 
template<size_t N, typename Array >
auto lar::dump::array (Array const &a)
 Returns a manipulator which will print the specified array. More...
 
template<typename Vector >
auto lar::dump::vector (Vector const &v)
 Returns a manipulator which will print the specified array. More...
 
template<typename Vector3D >
auto lar::dump::vector3D (Vector3D const &v)
 Returns a manipulator which will print the specified vector. More...
 
template<typename Stream , typename Array >
Streamlar::dump::operator<< (Stream &&out, ArrayDumper< Array > &&manip)
 Dumps the array contained in the manipulator into a stream. More...
 
template<typename Stream , typename Vector >
Streamlar::dump::operator<< (Stream &&out, VectorDumper< Vector > &&manip)
 Dumps the vector contained in the manipulator into a stream. More...
 
template<typename String , typename Vector >
String lar::dump::operator+ (String const &s, VectorDumper< Vector > const &manip)
 Concatenates a vector to the specified string. More...
 
template<typename Vector >
std::string lar::dump::operator+ (const char *s, VectorDumper< Vector > const &manip)
 Creates a string with s concatenated to the rendered vector. More...
 
template<typename String , typename Vector >
String lar::dump::operator+ (VectorDumper< Vector > const &manip, String const &s)
 
template<typename Vector >
std::string lar::dump::operator+ (VectorDumper< Vector > const &manip, const char *s)
 Creates a string with the rendered vector concatenated to s. More...
 
template<typename String , typename Vector >
String & lar::dump::operator+= (String &s, VectorDumper< Vector > const &manip)
 Appends a string rendering of a vector to the specified string. More...
 

Detailed Description

Utilities to dump objects into a stream.

Author
Gianluca Petrillo (petri.nosp@m.llo@.nosp@m.fnal..nosp@m.gov)
Date
February 28, 2017

The library DumpUtils.h is currently header-only.

Definition in file DumpUtils.h.