arsa  2.7
Public Member Functions | List of all members
irr::io::IIrrXMLWriter< char_type, super_class > Class Template Referenceabstract

Interface providing methods for making it easier to write XML files. More...

#include <irrXML.h>

Inheritance diagram for irr::io::IIrrXMLWriter< char_type, super_class >:

Public Member Functions

virtual ~IIrrXMLWriter ()
 Destructor. More...
 
virtual void writeXMLHeader ()=0
 Writes an xml 1.0 header. More...
 
virtual void writeElement (const char_type *name, bool empty=false, const char_type *attr1Name=0, const char_type *attr1Value=0, const char_type *attr2Name=0, const char_type *attr2Value=0, const char_type *attr3Name=0, const char_type *attr3Value=0, const char_type *attr4Name=0, const char_type *attr4Value=0, const char_type *attr5Name=0, const char_type *attr5Value=0)=0
 
virtual void writeElement (const char_type *name, bool empty, core::array< core::string< char_type > > &names, core::array< core::string< char_type > > &values)=0
 Writes an xml element with any number of attributes. More...
 
virtual void writeComment (const char_type *comment)=0
 Writes a comment into the xml file. More...
 
virtual void writeClosingTag (const char_type *name)=0
 Writes the closing tag for an element. Like "</foo>". More...
 
virtual void writeText (const char_type *text)=0
 Writes a text into the file. More...
 
virtual void writeLineBreak ()=0
 Writes a line break. More...
 

Detailed Description

template<class char_type, class super_class>
class irr::io::IIrrXMLWriter< char_type, super_class >

Interface providing methods for making it easier to write XML files.

Definition at line 377 of file irrXML.h.

Constructor & Destructor Documentation

◆ ~IIrrXMLWriter()

template<class char_type , class super_class >
virtual irr::io::IIrrXMLWriter< char_type, super_class >::~IIrrXMLWriter ( )
inlinevirtual

Destructor.

Definition at line 382 of file irrXML.h.

382 {}

Member Function Documentation

◆ writeClosingTag()

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeClosingTag ( const char_type *  name)
pure virtual

Writes the closing tag for an element. Like "</foo>".

◆ writeComment()

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeComment ( const char_type *  comment)
pure virtual

Writes a comment into the xml file.

◆ writeElement() [1/2]

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeElement ( const char_type *  name,
bool  empty = false,
const char_type *  attr1Name = 0,
const char_type *  attr1Value = 0,
const char_type *  attr2Name = 0,
const char_type *  attr2Value = 0,
const char_type *  attr3Name = 0,
const char_type *  attr3Value = 0,
const char_type *  attr4Name = 0,
const char_type *  attr4Value = 0,
const char_type *  attr5Name = 0,
const char_type *  attr5Value = 0 
)
pure virtual

Writes an xml element with maximal 5 attributes like "<foo />" or <foo optAttr="value" />. The element can be empty or not.

Parameters
nameName of the element
emptySpecifies if the element should be empty. Like "<foo />". If You set this to false, something like this is written instead: "<foo>".
attr1Name1st attributes name
attr1Value1st attributes value
attr2Name2nd attributes name
attr2Value2nd attributes value
attr3Name3rd attributes name
attr3Value3rd attributes value
attr4Name4th attributes name
attr4Value4th attributes value
attr5Name5th attributes name
attr5Value5th attributes value

◆ writeElement() [2/2]

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeElement ( const char_type *  name,
bool  empty,
core::array< core::string< char_type > > &  names,
core::array< core::string< char_type > > &  values 
)
pure virtual

Writes an xml element with any number of attributes.

◆ writeLineBreak()

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeLineBreak ( )
pure virtual

Writes a line break.

◆ writeText()

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeText ( const char_type *  text)
pure virtual

Writes a text into the file.

All occurrences of special characters such as & (&), < (<), > (>), and " (") are automatically replaced.

◆ writeXMLHeader()

template<class char_type , class super_class >
virtual void irr::io::IIrrXMLWriter< char_type, super_class >::writeXMLHeader ( )
pure virtual

Writes an xml 1.0 header.

Looks like <?xml version="1.0"?>. This should always be called before writing anything other, because also the text file header for Unicode texts is written out with this method.


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