aitools::invertedindex::Converter Class Reference

#include <Converter.hpp>

List of all members.

Static Public Member Functions

static uint32_t str_to_ui32 (const std::string &str)
static uint64_t str_to_ui64 (const std::string &str)
static std::string ui32_to_str (uint32_t number)
static std::string ui64_to_str (uint64_t number)
static std::string float_to_str (float number)
static std::string double_to_str (double number)
template<typename T >
static std::string nameof ()

Private Member Functions

 Converter ()
 ~Converter ()

Detailed Description

A helper class to convert integer to string and vice versa.

Author:
martin.trenkmann@uni-weimar.de

Created on Jun 22, 2008

Id
Converter.hpp,v 1.11 2010/05/11 23:41:08 trenkman Exp

Definition at line 23 of file Converter.hpp.


Constructor & Destructor Documentation

aitools::invertedindex::Converter::Converter (  )  [private]

The default constructor.

aitools::invertedindex::Converter::~Converter (  )  [private]

The destructor.


Member Function Documentation

std::string aitools::invertedindex::Converter::double_to_str ( double  number  )  [static]

Definition at line 63 of file Converter.cpp.

std::string aitools::invertedindex::Converter::float_to_str ( float  number  )  [static]

Definition at line 51 of file Converter.cpp.

template<typename T >
std::string aitools::invertedindex::Converter::nameof (  )  [inline, static]

Definition at line 80 of file Converter.hpp.

uint32_t aitools::invertedindex::Converter::str_to_ui32 ( const std::string &  str  )  [static]

A method to convert a string to an unsigned integer of 4 byte.

Parameters:
str a string to be converted.
Returns:
an 4 byte unsigned integer.

Definition at line 5 of file Converter.cpp.

uint64_t aitools::invertedindex::Converter::str_to_ui64 ( const std::string &  str  )  [static]

A method to convert a string to an unsigned integer of 8 byte.

Parameters:
str a string to be converted.
Returns:
an 8 byte unsigned integer.

Definition at line 16 of file Converter.cpp.

std::string aitools::invertedindex::Converter::ui32_to_str ( uint32_t  number  )  [static]

A method to convert an unsigned integer of 4 byte to a string representation.

Parameters:
ui64 an 4 byte unsigned integer to be converted.
Returns:
a string representation.

Definition at line 27 of file Converter.cpp.

Referenced by aitools::invertedindex::StorageSearcher::open(), and aitools::invertedindex::StorageBuilder::put().

Here is the caller graph for this function:

std::string aitools::invertedindex::Converter::ui64_to_str ( uint64_t  number  )  [static]

A method to convert an unsigned integer of 8 byte to a string representation.

Parameters:
ui64 an 8 byte unsigned integer to be converted.
Returns:
a string representation.

Definition at line 39 of file Converter.cpp.


The documentation for this class was generated from the following files:
Generated on Wed May 30 15:07:37 2012 by  doxygen 1.6.3