Quick Links: |
#include <bdlb_printadapter.h>
Public Member Functions | |
PrintAdapter (const TYPE *object, int level=0, int spacesPerLevel=4) | |
int | level () const |
const TYPE & | object () const |
int | spacesPerLevel () const |
This class
provides an object that may be streamed with operator<<
to give full control of the indentation format of the streaming.
See Component bdlb_printadapter
bdlb::PrintAdapter< TYPE >::PrintAdapter | ( | const TYPE * | object, | |
int | level = 0 , |
|||
int | spacesPerLevel = 4 | |||
) | [explicit] |
Create a print adapter object bound to the specified object
, and with the optionally specified level
and spacesPerLevel
attributes, to be used when the PrintAdapter
object is streamed. Unless level
is specified, a value of 0 is used, unless spacesPerLevel
is specified, a value of 4 is used.
int bdlb::PrintAdapter< TYPE >::level | ( | ) | const |
Return the level
attribute.
const TYPE& bdlb::PrintAdapter< TYPE >::object | ( | ) | const |
Return a reference to the object referred to by this print adapter.
int bdlb::PrintAdapter< TYPE >::spacesPerLevel | ( | ) | const |
Return the spacesPerLevel
attribute.