Public Member Functions | Private Attributes
ecl::Converter< std::string, int > Class Template Reference

Converts int to string, convenient but slow. More...

#include <string.hpp>

Inheritance diagram for ecl::Converter< std::string, int >:
Inheritance graph

List of all members.

Public Member Functions

std::string operator() (const int &input)
 Converts an integer into a string.
virtual ~Converter ()

Private Attributes

char buffer [31]

Detailed Description

class ecl::Converter< std::string, int >

Converts int to string, convenient but slow.

Slightly slower but convenient (no need for preallocating buffers) conversion of int to a string. This implementation is based on a technique similarly used in the stlsoft libraries.

See also:

Definition at line 51 of file string.hpp.

Constructor & Destructor Documentation

virtual ecl::Converter< std::string, int >::~Converter ( ) [inline, virtual]

Reimplemented in ecl::Converter< std::string, void >.

Definition at line 99 of file string.hpp.

Member Function Documentation

std::string ecl::Converter< std::string, int >::operator() ( const int &  input) [inline]

Converts an integer into a string.

This is slow in comparison to the buffered character string functions. There is no need for error handling here as it will always work.

input: the integer to be converted.
string : the string representation of the integer.

Definition at line 63 of file string.hpp.

Member Data Documentation

char ecl::Converter< std::string, int >::buffer[31] [private]

Definition at line 107 of file string.hpp.

The documentation for this class was generated from the following file:

Author(s): Daniel Stonier
autogenerated on Wed Aug 26 2015 11:27:10