Elm  1.0
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
elm::xom::Text Class Reference

#include <elm/xom/Text.h>

+ Inheritance diagram for elm::xom::Text:

Public Member Functions

 Text (String data)
 
 Text (const Text *text)
 
void setValue (String data)
 
String getText (void)
 
virtual Nodecopy (void)
 
virtual NodegetChild (int index)
 
virtual int getChildCount (void)
 
virtual String getValue (void)
 
virtual String toXML (void)
 
- Public Member Functions inherited from elm::xom::Node
virtual ~Node (void)
 
void * getNode (void) const
 
kind_t kind (void) const
 
void detach (void)
 
bool equals (const Node *node) const
 
virtual String getBaseURI (void)
 
virtual DocumentgetDocument (void)
 
virtual ParentNodegetParent (void)
 
virtual Nodesquery (const String &xpath)
 
virtual Nodesquery (const String &xpath, XPathContext *context)
 
int line (void) const
 

Protected Member Functions

 Text (void *node)
 
- Protected Member Functions inherited from elm::xom::Node
 Node (void *_node)
 
void setNode (void *_node)
 
Nodemake (void *node)
 
Nodeget (void *node)
 
NodeinternCopy (void)
 
NodeinternGetChild (int index)
 
int internGetChildCount (void)
 
String internGetValue (void)
 
String internToXML (void)
 

Additional Inherited Members

- Public Types inherited from elm::xom::Node
enum  kind_t {
  NONE = 0, ELEMENT, DOCUMENT, TEXT,
  COMMENT, ATTRIBUTE, PROCESSING_INSTRUCTION, DOCTYPE,
  NAMESPACE
}
 
typedef enum elm::xom::Node::kind_t kind_t
 
- Static Protected Member Functions inherited from elm::xom::Node
static void freeNode (void *node)
 
- Protected Attributes inherited from elm::xom::Node
void * node
 

Detailed Description

Node containing simple text.

Constructor & Destructor Documentation

elm::xom::Text::Text ( void *  node)
protected

Referenced by copy().

elm::xom::Text::Text ( String  data)

Build a new text node.

Parameters
dataContent of the text node.

References elm::xom::Node::node.

elm::xom::Text::Text ( const Text text)

Build a new text node by cloning an existing one.

Parameters
textText node to clone.

References elm::xom::Node::node.

Member Function Documentation

Node * elm::xom::Text::copy ( void  )
virtual

Implements elm::xom::Node.

References Text().

Node * elm::xom::Text::getChild ( int  index)
virtual

Returns the child of this node at the specified position.

Parameters
positionthe index of the child node to return
Returns
the positionth child node of this node

Implements elm::xom::Node.

References elm::xom::Node::internGetChild().

int elm::xom::Text::getChildCount ( void  )
virtual
String elm::xom::Text::getText ( void  )

Get the text of this node.

Returns
Node text.

References elm::xom::Node::node.

String elm::xom::Text::getValue ( void  )
virtual

Get the node as a string with markup removed.

Returns
Text value of the node. The returned string must be fried by the caller.

Implements elm::xom::Node.

References elm::xom::Node::internGetValue().

Referenced by elm::xom::Serializer::write().

void elm::xom::Text::setValue ( String  data)

Set the content of the text.

Parameters
dataText to put in.

References elm::xom::Node::node.

String elm::xom::Text::toXML ( void  )
virtual

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