PhoenixThread  1.0.0
Tools to ease parallel programming in C++
Loading...
Searching...
No Matches
lauchParallelThread.h
Go to the documentation of this file.
1/***************************************
2 Auteur : Pierre Aubert
3 Mail : pierre.aubert@lapp.in2p3.fr
4 Licence : CeCILL-C
5****************************************/
6
7#ifndef __LAUCHPARALLELTHREAD_H__
8#define __LAUCHPARALLELTHREAD_H__
9
10#include <thread>
11#include <string>
12#include <vector>
13#include "PPath.h"
14
15template<typename T, typename _Callable, typename... _Args>
16void lauchParallelThread(const std::vector<T> & listInputPTabModelFile, long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
17
18template<typename T, typename _Callable, typename... _Args>
19void lauchParallelThread(std::vector<T> & listInputPTabModelFile, long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
20
21template<typename _Callable, typename... _Args>
22bool lauchParallelThreadLog(const std::vector<PPath> & listInputPTabModelFile,
23 const PPath & baseOutputName, const PPath & fileSuffix,
24 long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
25
26template<typename _Callable, typename... _Args>
27bool lauchParallelThreadLog(const std::vector<PPath> & listInputPTabModelFile,
28 const PPath & logFile,
29 long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
30
31template<typename _Callable, typename... _Args>
32bool lauchParallelThreadLog(const PPath & baseOutputName, const PPath & fileSuffix,
33 long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
34
35template<typename _Callable, typename... _Args>
36bool lauchParallelThreadLog(const PPath & logFile,
37 long unsigned int nbThread, _Callable&& __f, _Args&&... __args);
38
40
41#endif
42
void lauchParallelThread(const std::vector< T > &listInputPTabModelFile, long unsigned int nbThread, _Callable &&__f, _Args &&... __args)
Lauch the callable function __f on nbThread threads with __args to be passed to each thread.
bool lauchParallelThreadLog(const std::vector< PPath > &listInputPTabModelFile, const PPath &baseOutputName, const PPath &fileSuffix, long unsigned int nbThread, _Callable &&__f, _Args &&... __args)
Lauch the callable function __f on nbThread threads with __args to be passed to each thread.