Commit 29a2730e authored by Martin Heistermann's avatar Martin Heistermann

implement property size()

parent bc45b8c5
......@@ -88,6 +88,8 @@ public:
virtual const std::string typeNameWrapper() const = 0;
virtual size_t size() const = 0;
protected:
virtual void delete_multiple_entries(const std::vector<bool>& _tags) = 0;
......
......@@ -88,6 +88,9 @@ public:
virtual void resize(size_t _n) {
data_.resize(_n, def_);
}
virtual size_t size() const {
return data_.size();
}
virtual void clear() {
data_.clear();
vector_type().swap(data_);
......
......@@ -91,6 +91,7 @@ public:
const_iterator begin() const { return ptr::shared_ptr<PropT>::get()->begin(); }
iterator begin() { return ptr::shared_ptr<PropT>::get()->begin(); }
size_t size() const { return ptr::shared_ptr<PropT>::get()->size(); }
const_iterator end() const { return ptr::shared_ptr<PropT>::get()->end(); }
iterator end() { return ptr::shared_ptr<PropT>::get()->end(); }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment