Orxonox: TiXmlStylesheetReference Class Reference

# TiXmlStylesheetReference Class Reference

`#include <src/tinyxml/tinyxml.h>`

Inheritance diagram for TiXmlStylesheetReference:

List of all members.

## Public Member Functions

virtual bool | Accept (TiXmlVisitor *visitor) const
virtual TiXmlNode * | Clone () const
| Creates a copy of this StylesheetReference and returns it.
const char * | Href () const
| Href. Will return an empty string if none was found.
void | operator= (const TiXmlStylesheetReference &copy)
virtual const char * | Parse (const char *p, TiXmlParsingData *data, TiXmlEncoding encoding)
virtual void | Print (FILE *cfile, int depth) const
virtual void | Print (FILE *cfile, int depth, TIXML_STRING *str) const
| TiXmlStylesheetReference (const TiXmlStylesheetReference &copy)
| TiXmlStylesheetReference (const char *_type, const char *_href)
| Construct.
| TiXmlStylesheetReference ()
| Construct an empty declaration.
virtual TiXmlStylesheetReference * | ToStylesheetReference ()
| Cast to a more defined type. Will return null not of the requested type.
virtual const TiXmlStylesheetReference * | ToStylesheetReference () const
| Cast to a more defined type. Will return null not of the requested type.
const char * | Type () const
| Type. Will return an empty string if none was found.
virtual | ~TiXmlStylesheetReference ()

## Protected Member Functions

void | CopyTo (TiXmlStylesheetReference *target) const

## Private Attributes

TIXML_STRING | href
TIXML_STRING | type

## Detailed Description

A stylesheet reference looks like this:

    		<?xml-stylesheet type="text/xsl" href="style.xsl"?>

Note: In this version of the code, the attributes are handled as special cases, not generic attributes, simply because there can only be at most 2 and they are always the same.

## Constructor & Destructor Documentation

TiXmlStylesheetReference::TiXmlStylesheetReference | ( |  | ) | `[inline]`

Construct an empty declaration.

Referenced by Clone().

TiXmlStylesheetReference::TiXmlStylesheetReference | ( | const char * | _type,
|  | const char * | _href |
| ) |  |  |

Construct.

References href, and type.

TiXmlStylesheetReference::TiXmlStylesheetReference | ( | const TiXmlStylesheetReference & | copy | ) |

References CopyTo().

virtual TiXmlStylesheetReference::~TiXmlStylesheetReference | ( |  | ) | `[inline, virtual]`

## Member Function Documentation

bool TiXmlStylesheetReference::Accept | ( | TiXmlVisitor * | visitor | ) | const`[virtual]`

Walk the XML tree visiting this node and all of its children.

Implements TiXmlNode.

References TiXmlVisitor::Visit().

TiXmlNode * TiXmlStylesheetReference::Clone | ( |  | ) | const`[virtual]`

Creates a copy of this StylesheetReference and returns it.

Implements TiXmlNode.

References CopyTo(), and TiXmlStylesheetReference().

void TiXmlStylesheetReference::CopyTo | ( | TiXmlStylesheetReference * | target | ) | const`[protected]`

References TiXmlNode::CopyTo(), href, and type.

Referenced by Clone(), operator=(), and TiXmlStylesheetReference().

const char* TiXmlStylesheetReference::Href | ( |  | ) | const`[inline]`

Href. Will return an empty string if none was found.

References href.

void TiXmlStylesheetReference::operator= | ( | const TiXmlStylesheetReference & | copy | ) |

References TiXmlNode::Clear(), and CopyTo().

const char * TiXmlStylesheetReference::Parse | ( | const char * | p,
|  | TiXmlParsingData * | data,
|  | TiXmlEncoding | encoding |
| ) |  |  | `[virtual]`

Implements TiXmlBase.

References TiXmlParsingData::Cursor(), TiXmlNode::GetDocument(), href, TiXmlBase::IsWhiteSpace(), TiXmlBase::location, TiXmlAttribute::Parse(), TiXmlDocument::SetError(), TiXmlBase::SkipWhiteSpace(), TiXmlParsingData::Stamp(), TiXmlBase::StringEqual(), TiXmlBase::TIXML_ERROR_PARSING_DECLARATION, type, and TiXmlAttribute::Value().

virtual void TiXmlStylesheetReference::Print | ( | FILE * | cfile,
|  | int | depth |
| ) |  |  | const`[inline, virtual]`

All TinyXml classes can print themselves to a filestream or the string class (TiXmlString in non-STL mode, std::string in STL mode.) Either or both cfile and str can be null.

This is a formatted print, and will insert tabs and newlines.

(For an unformatted stream, use the << operator.)

Implements TiXmlBase.

References Print().

void TiXmlStylesheetReference::Print | ( | FILE * | cfile,
|  | int | depth,
|  | TIXML_STRING * | str |
| ) |  |  | const`[virtual]`

References href, and type.

Referenced by Print().

virtual TiXmlStylesheetReference* TiXmlStylesheetReference::ToStylesheetReference | ( |  | ) | `[inline, virtual]`

Cast to a more defined type. Will return null not of the requested type.

Reimplemented from TiXmlNode.

virtual const TiXmlStylesheetReference* TiXmlStylesheetReference::ToStylesheetReference | ( |  | ) | const`[inline, virtual]`

Cast to a more defined type. Will return null not of the requested type.

Reimplemented from TiXmlNode.

const char* TiXmlStylesheetReference::Type | ( |  | ) | const`[inline]`

Type. Will return an empty string if none was found.

Reimplemented from TiXmlNode.

References type.

## Member Data Documentation

TIXML_STRING TiXmlStylesheetReference::href`[private]`

Referenced by CopyTo(), Href(), Parse(), Print(), and TiXmlStylesheetReference().

TIXML_STRING TiXmlStylesheetReference::type`[private]`

Reimplemented from TiXmlNode.

Referenced by CopyTo(), Parse(), Print(), TiXmlStylesheetReference(), and Type().

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

- src/tinyxml/tinyxml.h
- src/tinyxml/tinyxml.cpp
- src/tinyxml/tinyxmlparser.cpp