General Utility Library for C++14  2.7
Classes | Namespaces | Functions
hexdump.h File Reference

Detailed Description

Declarations of hexdump()

Author
General Utility Library Contributors
Date
Created on September 25, 2018

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 2.1 of the license, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this program. If not, see https://www.gnu.org/licenses/.

#include <iomanip>
#include <sstream>
#include <type_traits>
#include <utility>
#include "gul14/internal.h"
#include "gul14/string_view.h"
Include dependency graph for hexdump.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  gul14::HexdumpParameterForward< IteratorT, ContainerT >
 Helper object used to enable a convenient syntax to dump things to a stream. More...
 

Namespaces

 gul14
 Namespace gul14 contains all functions and classes of the General Utility Library.
 

Functions

template<typename IteratorT , typename = std::enable_if_t<detail::IsHexDumpIterator<IteratorT>::value>>
std::string gul14::hexdump (IteratorT begin, IteratorT end, string_view prompt="")
 Generate a hexdump of a data range and return it as a string. More...
 
template<typename ContainerT , typename = std::enable_if_t<detail::IsHexDumpContainer<ContainerT>::value>>
std::string gul14::hexdump (const ContainerT &cont, string_view prompt="")
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
template<typename IteratorT , typename = std::enable_if_t<detail::IsHexDumpIterator<IteratorT>::value>>
HexdumpParameterForward< const IteratorT > gul14::hexdump_stream (const IteratorT &begin, const IteratorT &end, std::string prompt="")
 Generate a hexdump of a data range that can be efficiently written to a stream using operator<<. More...
 
template<typename ContainerT , typename = std::enable_if_t<detail::IsHexDumpContainer<ContainerT>::value>>
HexdumpParameterForward< const decltype(std::declval< ContainerT >).cbegin())> gul14::hexdump_stream (const ContainerT &cont, std::string prompt="")
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
template<typename ContainerT , typename = std::enable_if_t<detail::IsHexDumpContainer<ContainerT>::value, decltype(HexdumpParameterForward<decltype(std::declval<ContainerT>().cbegin()), ContainerT> {}, 0)>>
HexdumpParameterForward< decltype(std::declval< ContainerT >).cbegin()), ContainerT > gul14::hexdump_stream (ContainerT &&cont, std::string prompt="")
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...