[DEBUG] correct const iterators...
This commit is contained in:
parent
a4a9e23299
commit
ee2583c175
@ -106,4 +106,19 @@ void exml::AttributeListData::set(const std::string& _name, const std::string& _
|
||||
|
||||
template class exml::iterator<exml::AttributeListData, exml::Attribute>;
|
||||
|
||||
exml::AttributeListData::iterator exml::AttributeListData::begin() {
|
||||
return exml::AttributeListData::iterator(*this, 0);
|
||||
}
|
||||
|
||||
exml::AttributeListData::iterator exml::AttributeListData::end() {
|
||||
return exml::AttributeListData::iterator(*this, size());
|
||||
}
|
||||
|
||||
const exml::AttributeListData::iterator exml::AttributeListData::begin() const {
|
||||
return exml::AttributeListData::iterator(*this, 0);
|
||||
}
|
||||
|
||||
const exml::AttributeListData::iterator exml::AttributeListData::end() const {
|
||||
return exml::AttributeListData::iterator(*this, size());
|
||||
}
|
||||
|
||||
|
@ -75,12 +75,10 @@ namespace exml {
|
||||
void set(const std::string& _name, const std::string& _value);
|
||||
public:
|
||||
using iterator = exml::iterator<exml::AttributeListData, exml::Attribute>;
|
||||
iterator begin() {
|
||||
return iterator(*this, 0);
|
||||
}
|
||||
iterator end() {
|
||||
return iterator(*this, size());
|
||||
}
|
||||
iterator begin();
|
||||
iterator end();
|
||||
const iterator begin() const;
|
||||
const iterator end() const;
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -40,6 +40,23 @@ exml::Element& exml::Element::operator= (const exml::Element& _obj) {
|
||||
return *this;
|
||||
}
|
||||
|
||||
exml::ElementData::iterator exml::ElementData::begin() {
|
||||
return exml::ElementData::iterator(*this, 0);
|
||||
}
|
||||
|
||||
exml::ElementData::iterator exml::ElementData::end() {
|
||||
return exml::ElementData::iterator(*this, size());
|
||||
}
|
||||
|
||||
const exml::ElementData::iterator exml::ElementData::begin() const {
|
||||
return exml::ElementData::iterator(*this, 0);
|
||||
}
|
||||
|
||||
const exml::ElementData::iterator exml::ElementData::end() const {
|
||||
return exml::ElementData::iterator(*this, size());
|
||||
}
|
||||
|
||||
|
||||
exml::ElementData::ElementData(exml::Element* _elem) :
|
||||
m_data(_elem) {
|
||||
|
||||
|
@ -70,12 +70,10 @@ namespace exml {
|
||||
const exml::Element operator[] (const std::string& _name) const;
|
||||
public:
|
||||
using iterator = exml::iterator<exml::ElementData, exml::Node>;
|
||||
iterator begin() {
|
||||
return iterator(*this, 0);
|
||||
}
|
||||
iterator end() {
|
||||
return iterator(*this, size());
|
||||
}
|
||||
iterator begin();
|
||||
iterator end();
|
||||
const iterator begin() const;
|
||||
const iterator end() const;
|
||||
};
|
||||
/**
|
||||
* @brief Basic element Node of an XML document <YYYYY>
|
||||
|
Loading…
x
Reference in New Issue
Block a user