]> git.lyx.org Git - lyx.git/blobdiff - src/support/limited_stack.h
* lyxfunctional.h: delete compare_memfun and helper classes
[lyx.git] / src / support / limited_stack.h
index 319a05c2d5df8316772c0fd0e94c6fa2c98ebb94..1354bcd701008ac89f42acca26ec6b8bf00a8463 100644 (file)
@@ -6,7 +6,7 @@
  *
  * \author John Levon
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
 #ifndef LIMITED_STACK_H
@@ -26,6 +26,7 @@ public:
        typedef std::deque<T> container_type;
        typedef typename container_type::value_type value_type;
        typedef typename container_type::size_type size_type;
+       typedef typename container_type::const_iterator const_iterator;
 
        /// limit is the maximum size of the stack
        limited_stack(size_type limit = 100) {
@@ -70,6 +71,15 @@ public:
        size_type size() const {
                return c_.size();
        }
+
+       const_iterator begin() const {
+               return c_.begin();
+       }
+
+       const_iterator end() const {
+               return c_.end();
+       }
+
 private:
        /// Internal contents.
        container_type c_;