Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members  

judo::CDATA Class Reference

Character data storage class. More...

#include <judo.hpp>

Inheritance diagram for judo::CDATA:

judo::Node List of all members.

Public Member Functions

 CDATA (const char *text, unsigned int textsz, bool escaped=false)
 Default constructor.

void setText (const char *text, unsigned int textsz, bool escaped=false)
 Overwrite all existing character data in this object with specified text.

void appendText (const char *text, unsigned int textsz, bool escaped=false)
 Append new character data to the existing text in this object.

const std::string & getText () const
 Get a read-only reference to the character data in this object.

std::string toString () const
 Get a properly escaped XML string representation of this object.

void accumulate (XMLAccumulator &acc) const
 Accumulator entry point for recursive XML serialization.


Detailed Description

Character data storage class.

Definition at line 149 of file judo.hpp.


Member Function Documentation

void judo::CDATA::accumulate XMLAccumulator &    acc const [inline, virtual]
 

Accumulator entry point for recursive XML serialization.

This is a virtual abstract method that is implemented by subclasses.

Parameters:
acc An instance of an XMLAccumulator

Implements judo::Node.

Definition at line 223 of file judo.hpp.

void judo::CDATA::appendText const char *    text,
unsigned int    textsz,
bool    escaped = false
[inline]
 

Append new character data to the existing text in this object.

Parameters:
text New character data to store
textsz Length of new character data
escaped Is the text escaped?

Definition at line 195 of file judo.hpp.

Referenced by judo::Element::addCDATA().

const std::string& judo::CDATA::getText   const [inline]
 

Get a read-only reference to the character data in this object.

Note that this data is not properly escaped XML and is not suitable for passing to an XML parser.

Definition at line 212 of file judo.hpp.

void judo::CDATA::setText const char *    text,
unsigned int    textsz,
bool    escaped = false
[inline]
 

Overwrite all existing character data in this object with specified text.

Parameters:
text New character data to store
textsz Length of new character data
escaped Is the text escaped?

Definition at line 176 of file judo.hpp.

std::string judo::CDATA::toString   const [inline, virtual]
 

Get a properly escaped XML string representation of this object.

See also:
Node::toString

Implements judo::Node.

Definition at line 220 of file judo.hpp.


The documentation for this class was generated from the following file:
Generated on Thu Jul 24 13:31:55 2003 for jabberoo by doxygen1.3-rc3