Quick Links:

bal | bbl | bdl | bsl

Public Types | Public Member Functions

balxml::Formatter_PrettyImplState Class Reference

#include <balxml_formatter_prettyimpl.h>

List of all members.

Public Types

typedef bsl::allocator< char > allocator_type
typedef Formatter_PrettyImplStateId Id
typedef FormatterWhitespaceType WhitespaceType

Public Member Functions

 BSLMF_NESTED_TRAIT_DECLARATION (Formatter_PrettyImplState, bslma::UsesBslmaAllocator)
 Formatter_PrettyImplState ()
 Formatter_PrettyImplState (const allocator_type &allocator)
 Formatter_PrettyImplState (int indentLevel, int spacesPerLevel, int wrapColumn, const allocator_type &allocator=allocator_type())
 Formatter_PrettyImplState (Id::Enum id, int indentLevel, int spacesPerLevel, int column, int wrapColumn, const bsl::vector< WhitespaceType::Enum > &elementNesting, const allocator_type &allocator=allocator_type())
 Formatter_PrettyImplState (const Formatter_PrettyImplState &original, const allocator_type &allocator=allocator_type())
int & column ()
bsl::vector
< WhitespaceType::Enum > & 
elementNesting ()
Id::Enumid ()
int & indentLevel ()
int & spacesPerLevel ()
int & wrapColumn ()
const int & column () const
const bsl::vector
< WhitespaceType::Enum > & 
elementNesting () const
allocator_type get_allocator () const
const Id::Enumid () const
const int & indentLevel () const
const int & spacesPerLevel () const
const int & wrapColumn () const

Detailed Description

This class provides an in-core, value-semantic attribute type that maintains all of the state information needed to pretty-print an XML document using the operations provided by Formatter_PrettyImplUtil.

See Component balxml_formatter_prettyimpl


Member Typedef Documentation


Constructor & Destructor Documentation

balxml::Formatter_PrettyImplState::Formatter_PrettyImplState (  ) 
balxml::Formatter_PrettyImplState::Formatter_PrettyImplState ( const allocator_type allocator  )  [explicit]

Create a Formatter_PrettyImplState having an id attribute of Id::e_AT_START, indentLevel, spacesPerLevel, column, and wrapColumn attributes of 0, and an empty elementNesting attribute. Optionally specify an allocator (e.g., the address of a bslma::Allocator object) to supply memory; otherwise, the default allocator is used.

balxml::Formatter_PrettyImplState::Formatter_PrettyImplState ( int  indentLevel,
int  spacesPerLevel,
int  wrapColumn,
const allocator_type allocator = allocator_type() 
)

Create a Formatter_PrettyImplState having an id attribute of Id::e_AT_START, the specified indentLevel, the specified spacesPerLevel, and the specified wrapColumn, a column attribute of 0, and an empty elementNesting attribute. Optionally specify an allocator (e.g., the address of a bslma::Allocator object) to supply memory; otherwise, the default allocator is used.

balxml::Formatter_PrettyImplState::Formatter_PrettyImplState ( Id::Enum  id,
int  indentLevel,
int  spacesPerLevel,
int  column,
int  wrapColumn,
const bsl::vector< WhitespaceType::Enum > &  elementNesting,
const allocator_type allocator = allocator_type() 
)

Create a Formatter_PrettyImplState having the specified id, indentLevel, spacesPerLevel, column, wrapColumn, and elementNesting attributes. Optionally specify an allocator (e.g., the address of a bslma::Allocator object) to supply memory; otherwise, the default allocator is used.

balxml::Formatter_PrettyImplState::Formatter_PrettyImplState ( const Formatter_PrettyImplState original,
const allocator_type allocator = allocator_type() 
)

Create a Formatter_PrettyImplState object having the same value as the specified original object. Optionally specify an allocator (e.g., the address of a bslma::Allocator object) to supply memory; otherwise, the default allocator is used.


Member Function Documentation

balxml::Formatter_PrettyImplState::BSLMF_NESTED_TRAIT_DECLARATION ( Formatter_PrettyImplState  ,
bslma::UsesBslmaAllocator   
)
int& balxml::Formatter_PrettyImplState::column (  ) 

Return a reference providing modifiable access to the column attribute of this object.

bsl::vector<WhitespaceType::Enum>& balxml::Formatter_PrettyImplState::elementNesting (  ) 

Return a reference providing modifiable access to the elementNesting attribute of this object.

Id::Enum& balxml::Formatter_PrettyImplState::id (  ) 

Return a reference providing modifiable access to the id attribute of this object.

int& balxml::Formatter_PrettyImplState::indentLevel (  ) 

Return a reference providing modifiable access to the indentLevel attribute of this object.

int& balxml::Formatter_PrettyImplState::spacesPerLevel (  ) 

Return a reference providing modifiable access to the spacesPerLevel attribute of this object.

int& balxml::Formatter_PrettyImplState::wrapColumn (  ) 

Return a reference providing modifiable access to the wrapColumn attribute of this object.

const int& balxml::Formatter_PrettyImplState::column (  )  const

Return a reference providing non-modifiable access to the column attribute of this object.

const bsl::vector<WhitespaceType::Enum>& balxml::Formatter_PrettyImplState::elementNesting (  )  const

Return a reference providing non-modifiable access to the elementNesting attribute of this object.

allocator_type balxml::Formatter_PrettyImplState::get_allocator (  )  const

Return the allocator associated with this object.

const Id::Enum& balxml::Formatter_PrettyImplState::id (  )  const

Return a reference providing non-modifiable access to the id attribute of this object.

const int& balxml::Formatter_PrettyImplState::indentLevel (  )  const

Return a reference providing non-modifiable access to the indentLevel attribute of this object.

const int& balxml::Formatter_PrettyImplState::spacesPerLevel (  )  const

Return a reference providing non-modifiable access to the spacesPerLevel attribute of this object.

const int& balxml::Formatter_PrettyImplState::wrapColumn (  )  const

Return a reference providing non-modifiable access to the wrapColumn attribute of this object.


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