From cf35984971341b8a8688eb02a22bcbc1772991d1 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Tue, 19 Jul 2011 23:29:41 -0500 Subject: Use Boost iterator_facade to create new iterators --- src/generate.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/generate.h') diff --git a/src/generate.h b/src/generate.h index 25ad41ea..f9207ff5 100644 --- a/src/generate.h +++ b/src/generate.h @@ -48,7 +48,9 @@ namespace ledger { class session_t; -class generate_posts_iterator : public posts_iterator +class generate_posts_iterator + : public iterator_facade_base { session_t& session; unsigned int seed; @@ -105,7 +107,7 @@ public: TRACE_DTOR(generate_posts_iterator); } - virtual post_t * operator()(); + virtual void increment(); protected: void generate_string(std::ostream& out, int len, bool only_alpha = false); -- cgit v1.2.3