Ipelib: ipe::XmlAttributes Class Reference

Ipelib

- Main Page
- Related Pages
- Modules
- Classes

- Class List
- Class Hierarchy
- Class Members

Public Types | Public Member Functions | List of all members
ipe::XmlAttributes Class Reference
Ipe Base

`#include <ipexml.h>`

## Public Types
typedef Map::const_iterator | const_iterator

## Public Member Functions
const_iterator | begin () const
const_iterator | end () const
| XmlAttributes ()
void | clear ()
String | operator[] (String str) const
bool | has (String str) const
bool | has (String str, String &val) const
void | add (String key, String val)
void | setSlash ()
bool | slash () const

## Detailed Description

Stores attributes of an XML tag.

## Member Typedef Documentation

typedef Map::const_iterator ipe::XmlAttributes::const_iterator

Iterator for (key, value) pairs.

## Constructor & Destructor Documentation

XmlAttributes::XmlAttributes | ( |  | ) |

Constructor for an empty collection.

Referenced by end().

## Member Function Documentation

const_iterator ipe::XmlAttributes::begin | ( |  | ) | const
| inline

Return const iterator for first attribute.

const_iterator ipe::XmlAttributes::end | ( |  | ) | const
| inline

Return const iterator for end of attributes.

References add(), clear(), has(), operator[](), and XmlAttributes().

void XmlAttributes::clear | ( |  | ) |

Remove all attributes.

Referenced by end(), and ipe::XmlParser::parseAttributes().

String XmlAttributes::operator[] | ( | String | str | ) | const

Return attribute with given key.

Returns an empty string if no attribute with this key exists.

Referenced by end().

bool XmlAttributes::has | ( | String | str | ) | const

Check whether attribute exists.

References ipe::XmlParser::XmlParser().

Referenced by ipe::Bitmap::Bitmap(), end(), ipe::Group::Group(), ipe::ImlParser::parseBitmap(), ipe::ImlParser::parseDocument(), ipe::ImlParser::parseObject(), ipe::ImlParser::parsePage(), ipe::ImlParser::parseStyle(), ipe::Reference::Reference(), and ipe::Text::Text().

bool XmlAttributes::has | ( | String | str,
|  | String & | val
| ) |  | const

Check whether attribute exists, set `val` if so.

void XmlAttributes::add | ( | String | key,
|  | String | val
| ) |  |

Add a new attribute.

Referenced by end(), and ipe::XmlParser::parseAttributes().

void ipe::XmlAttributes::setSlash | ( |  | ) |
| inline

Set that the tag contains the final /.

Referenced by ipe::XmlParser::parseAttributes().

bool ipe::XmlAttributes::slash | ( |  | ) | const
| inline

Return whether tag contains the final /.

Referenced by ipe::ImlParser::parseBitmap(), ipe::ImlParser::parseObject(), and ipe::ImlParser::parseStyle().

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

- ipexml.h
- ipexml.cpp