aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2007-10-19 15:54:49 +0000
committerMike Buland <eichlan@xagasoft.com>2007-10-19 15:54:49 +0000
commit640154682b767ec19cb9ac3972118c10bba8e780 (patch)
tree605176e70eaf7e0af17801f391e2c1e33242ad69
parentc88dc841d0d270c73a2f517f667d1483a2f31245 (diff)
downloadlibbu++-640154682b767ec19cb9ac3972118c10bba8e780.tar.gz
libbu++-640154682b767ec19cb9ac3972118c10bba8e780.tar.bz2
libbu++-640154682b767ec19cb9ac3972118c10bba8e780.tar.xz
libbu++-640154682b767ec19cb9ac3972118c10bba8e780.zip
As long as the Bu::Hash::iterator was aware that it was finished or not, I
thought I would write an accessor for that. Also, I added a public copy constructor, it only makes sense.
-rw-r--r--src/hash.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/hash.h b/src/hash.h
index be57786..04f2657 100644
--- a/src/hash.h
+++ b/src/hash.h
@@ -507,6 +507,18 @@ namespace Bu
507 bool bFinished; 507 bool bFinished;
508 508
509 public: 509 public:
510 iterator( const iterator &i ) :
511 hsh( i.hsh ),
512 nPos( i.nPos ),
513 bFinished( i.bFinished )
514 {
515 }
516
517 bool isActive()
518 {
519 return !bFinished;
520 }
521
510 /** 522 /**
511 * Iterator incrementation operator. Move the iterator forward. 523 * Iterator incrementation operator. Move the iterator forward.
512 */ 524 */