cttl::node_insert_stay< StringT > Struct Template Reference

Substring inserter. More...

#include <node_functors.h>

List of all members.

Public Member Functions

 node_insert_stay (StringT const &str_)
 Constructs function object and initializes it with the source substring.
void operator() (node< StringT > &node_)
 Function call operator, inserts substring specified when the function object was constructed, at the offset pointed by the node.

Public Attributes

StringT m_str
 Stores string to insert.


Detailed Description

template<typename StringT = CTTL_STD_STRING>
struct cttl::node_insert_stay< StringT >

Substring inserter.

Function object, which, if called as a function, inserts substring specified when the function object was constructed, at the offset pointed by the node.

Template Parameters:
StringT specifies type of the encapsulated string. The default is std::string

Definition at line 102 of file node_functors.h.


Constructor & Destructor Documentation

template<typename StringT = CTTL_STD_STRING>
cttl::node_insert_stay< StringT >::node_insert_stay ( StringT const &  str_  ) 

Constructs function object and initializes it with the source substring.

Definition at line 105 of file node_functors.h.

00106             :
00107         m_str( str_ )
00108         {
00109         }


Member Function Documentation

template<typename StringT = CTTL_STD_STRING>
void cttl::node_insert_stay< StringT >::operator() ( node< StringT > &  node_  ) 

Function call operator, inserts substring specified when the function object was constructed, at the offset pointed by the node.

Postcondition:
All nodes at higher offset positions are adjusted forward according to the length of the inserted substring.

Definition at line 120 of file node_functors.h.

00121         {
00122             node_.insert_stay( m_str );
00123         }


Member Data Documentation

template<typename StringT = CTTL_STD_STRING>
StringT cttl::node_insert_stay< StringT >::m_str

Stores string to insert.

Definition at line 126 of file node_functors.h.


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

Generated on Sun Aug 23 13:43:45 2009 for Common Text Transformation Library by  doxygen 1.5.9