Skip to content
Snippets Groups Projects
Commit 0400c168 authored by Mathieu Valois's avatar Mathieu Valois
Browse files

Move generate_stats_thread

parent 8f93fafb
No related branches found
No related tags found
No related merge requests found
......@@ -146,6 +146,12 @@ public:
inline bool allStarted() const { return started; }
bool operator==(const Statsgen& other) const;
/**
* @brief Given parameters in threadarg, compute statistics on partition of the file
* @param threadarg : parameters and result storage
*/
static void* generate_stats_thread(void * threadarg);
private:
std::string filename;
// results of the computation
......@@ -198,11 +204,6 @@ private:
*/
void updateMinMax(minMax & minMaxValue, const Policy & pol);
/**
* @brief Action of all threads
* @param threadarg : all useful argument for the thread
*/
void * generate_stats_thread(void * threadarg);
/**
* @brief Compute statistics by consumming password from a queue
......
......@@ -260,7 +260,7 @@ void handle_password(const string& password, const uint64_t& nbPasswords, Thread
my_data->minMaxValue.updateMinMax(c.pol);
}
void* generate_stats_thread(void* threadarg) {
void* Statsgen::generate_stats_thread(void* threadarg) {
ThreadData* my_data = (ThreadData *) threadarg;
ifstream readfile(my_data->filename);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment