dlvhex  2.1.0
include/dlvhex2/Printhelpers.h File Reference

Helpers for printing objects to streams. More...

#include <boost/range/iterator_range.hpp>
#include <boost/function.hpp>
#include <boost/bind.hpp>
#include <boost/optional.hpp>
#include <iostream>
#include <sstream>
#include <set>
#include <vector>
Include dependency graph for Printhelpers.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

class  ostream_printable< T >
struct  print_container
struct  print_stream_container< T >
struct  print_method_container

Functions

std::ostream & operator<< (std::ostream &o, print_container *c)
template<typename T >
print_containerprint_method (const T &t)
print_containerprint_function (const print_method_container::PrintFn &fn)
template<typename T >
print_containerprintopt (const boost::optional< T > &t)
template<typename T >
print_containerprintptr (const boost::shared_ptr< T > &t)
template<typename T >
print_containerprintptr (const boost::shared_ptr< const T > &t)
template<typename T >
print_containerprintptr (const T *const t)
template<typename Range >
print_containerprintrange (Range r, const char *open="<", const char *sep=",", const char *close=">")
template<typename T >
print_containerprintset (const std::set< T > &t, const char *open="{", const char *sep=",", const char *close="}")
template<typename T >
print_containerprintvector (const std::vector< T > &t, const char *open="[", const char *sep=",", const char *close="]")

Detailed Description

Helpers for printing objects to streams.

Author:
Peter Schueller <ps@kr.tuwien.ac.at>

Definition in file Printhelpers.h.


Function Documentation

std::ostream& operator<< ( std::ostream &  o,
print_container c 
) [inline]

Definition at line 88 of file Printhelpers.h.

References print_container::print().

template<typename T >
print_container* print_method ( const T &  t) [inline]
template<typename T >
print_container* printptr ( const boost::shared_ptr< const T > &  t) [inline]

Definition at line 157 of file Printhelpers.h.

template<typename T >
print_container* printptr ( const T *const  t) [inline]

Definition at line 167 of file Printhelpers.h.