BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bslim::Printer_Helper Struct Reference

#include <bslim_printer.h>

Static Public Member Functions

template<class TYPE >
static void print (bsl::ostream &stream, const TYPE &data, int level, int spacesPerLevel)
 
template<class ITERATOR >
static void print (bsl::ostream &stream, const ITERATOR &begin, const ITERATOR &end, int level, int spacesPerLevel)
 
template<class ITERATOR , class PRINT_FUNCTOR >
static void print (bsl::ostream &stream, const ITERATOR &begin, const ITERATOR &end, const PRINT_FUNCTOR &printFunctionObject, const int level, const int spacesPerLevel)
 
static void printRaw (bsl::ostream &stream, char data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_fundamental >)
 
static void printRaw (bsl::ostream &stream, unsigned char data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_fundamental >)
 
static void printRaw (bsl::ostream &stream, bool data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_fundamental >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, TYPE data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_fundamental >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, TYPE data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_enum >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const TYPE &data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bslmf::IsFunctionPointer >)
 
static void printRaw (bsl::ostream &stream, const char *data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_pointer >)
 
static void printRaw (bsl::ostream &stream, const void *data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_pointer >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const TYPE *data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_pointer >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const TYPE *data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bsl::is_array >)
 
static void printRaw (bsl::ostream &stream, const bsl::string &data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bslalg::HasStlIterators >)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const TYPE &data, int level, int spacesPerLevel, bslmf::SelectTraitCase< bslalg::HasStlIterators >)
 
template<class T1 , class T2 >
static void printRaw (bsl::ostream &stream, const bsl::pair< T1, T2 > &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 
static void printRaw (bsl::ostream &stream, const bslstl::StringRef &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 
static void printRaw (bsl::ostream &stream, const bsl::string_view &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const bsl::shared_ptr< TYPE > &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const bsl::optional< TYPE > &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 
template<class TYPE >
static void printRaw (bsl::ostream &stream, const TYPE &data, int level, int spacesPerLevel, bslmf::SelectTraitCase<>)
 

Detailed Description

This struct is an aid to the implementation of the accessors of the Printer mechanism. It provides a method template, print, that adheres to the BDE print method contract. It is not to be accessed directly by clients of bslim.

Member Function Documentation

◆ print() [1/3]

template<class ITERATOR , class PRINT_FUNCTOR >
void bslim::Printer_Helper::print ( bsl::ostream &  stream,
const ITERATOR &  begin,
const ITERATOR &  end,
const PRINT_FUNCTOR &  printFunctionObject,
const int  level,
const int  spacesPerLevel 
)
inlinestatic

Format the range of objects specified by [ begin, end ) to the specified output stream at the (absolute value of) the specified indentation level, using the specified spacesPerLevel, the number of spaces per indentation level for the objects and their nested objects, where ITERATOR supports the operators ++ and * to access the objects, printing the individual objects with the specified printFunctionObject.

◆ print() [2/3]

template<class ITERATOR >
void bslim::Printer_Helper::print ( bsl::ostream &  stream,
const ITERATOR &  begin,
const ITERATOR &  end,
int  level,
int  spacesPerLevel 
)
inlinestatic

Format the range of objects specified by [ begin, end ) to the specified output stream at the (absolute value of) the specified indentation level, using the specified spacesPerLevel, the number of spaces per indentation level for the objects and their nested objects, where ITERATOR supports the operators ++ and * to access the objects. Individual objects are printed with printValue.

◆ print() [3/3]

template<class TYPE >
void bslim::Printer_Helper::print ( bsl::ostream &  stream,
const TYPE &  data,
int  level,
int  spacesPerLevel 
)
inlinestatic

Format the specified data to the specified output stream at the (absolute value of) the specified indentation level, using the specified spacesPerLevel, the number of spaces per indentation level for this and all of its nested objects. Note that this function dispatches to printRaw based on the type traits of the deduced (template parameter) TYPE.

◆ printRaw() [1/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
bool  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_fundamental  
)
static

◆ printRaw() [2/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
char  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_fundamental  
)
static

◆ printRaw() [3/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bsl::optional< TYPE > &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
inlinestatic

◆ printRaw() [4/18]

template<class T1 , class T2 >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bsl::pair< T1, T2 > &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
inlinestatic

◆ printRaw() [5/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bsl::shared_ptr< TYPE > &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
inlinestatic

◆ printRaw() [6/18]

void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bsl::string data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bslalg::HasStlIterators  
)
inlinestatic

◆ printRaw() [7/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bsl::string_view data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
static

◆ printRaw() [8/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const bslstl::StringRef data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
static

◆ printRaw() [9/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const char *  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_pointer  
)
static

◆ printRaw() [10/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const TYPE &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bslalg::HasStlIterators  
)
inlinestatic

◆ printRaw() [11/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const TYPE &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bslmf::IsFunctionPointer  
)
inlinestatic

◆ printRaw() [12/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const TYPE &  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase<>   
)
inlinestatic

The print method of this class dispatches based on TYPE and traits to a printRaw method to do the actual printing of the specified data to the specified stream with indentation based on the specified level and spacesPerLevel.

◆ printRaw() [13/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const TYPE *  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_array  
)
inlinestatic

◆ printRaw() [14/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const TYPE *  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_pointer  
)
inlinestatic

◆ printRaw() [15/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
const void *  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_pointer  
)
static

◆ printRaw() [16/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
TYPE  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_enum  
)
inlinestatic

◆ printRaw() [17/18]

template<class TYPE >
void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
TYPE  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_fundamental  
)
inlinestatic

◆ printRaw() [18/18]

static void bslim::Printer_Helper::printRaw ( bsl::ostream &  stream,
unsigned char  data,
int  level,
int  spacesPerLevel,
bslmf::SelectTraitCase< bsl::is_fundamental  
)
static

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