• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdenetwork
  • Sitemap
  • Contact Us
 

kget

bt::ChunkCounter

bt::ChunkCounter Class Reference

#include <chunkcounter.h>

List of all members.


Detailed Description

Author:
Joris Guisson

Class to keep track of how many peers have a chunk.

Definition at line 35 of file chunkcounter.h.


Public Member Functions

 ChunkCounter (Uint32 num_chunks)
void dec (Uint32 idx)
void decBitSet (const BitSet &bs)
Uint32 get (Uint32 idx) const
void inc (Uint32 idx)
void incBitSet (const BitSet &bs)
void reset ()
virtual ~ChunkCounter ()

Constructor & Destructor Documentation

bt::ChunkCounter::ChunkCounter ( Uint32  num_chunks  ) 

Definition at line 26 of file chunkcounter.cpp.

bt::ChunkCounter::~ChunkCounter (  )  [virtual]

Definition at line 33 of file chunkcounter.cpp.


Member Function Documentation

void bt::ChunkCounter::dec ( Uint32  idx  ) 

Decrement the counter for the idx'th chunk.

Parameters:
idx Index of the chunk

Definition at line 66 of file chunkcounter.cpp.

void bt::ChunkCounter::decBitSet ( const BitSet &  bs  ) 

If a bit in the bitset is one, decrement the corresponding counter.

Parameters:
bs The BitSet

Definition at line 51 of file chunkcounter.cpp.

Uint32 bt::ChunkCounter::get ( Uint32  idx  )  const

Get the counter for the idx'th chunk.

Parameters:
idx Index of the chunk

Definition at line 72 of file chunkcounter.cpp.

void bt::ChunkCounter::inc ( Uint32  idx  ) 

Increment the counter for the idx'th chunk.

Parameters:
idx Index of the chunk

Definition at line 60 of file chunkcounter.cpp.

void bt::ChunkCounter::incBitSet ( const BitSet &  bs  ) 

If a bit in the bitset is one, increment the corresponding counter.

Parameters:
bs The BitSet

Definition at line 42 of file chunkcounter.cpp.

void bt::ChunkCounter::reset (  ) 

Reset all values to 0.

Definition at line 37 of file chunkcounter.cpp.


The documentation for this class was generated from the following files:
  • chunkcounter.h
  • chunkcounter.cpp

kget

Skip menu "kget"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdenetwork

Skip menu "kdenetwork"
  • kget
  • kopete
  •   kopete
  •   libkopete
  •       libpapillon
  • krfb
Generated for kdenetwork by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal