|
#ifndef _CELERO_TESTVECTOR_H_
#define _CELERO_TESTVECTOR_H_
#include <celero/Export.h>
#include <celero/Pimpl.h>
#include <functional>
namespace celero
{
class BenchmarkInfo;
///
/// \class TestVector
///
/// \brief Don't give me crap about a static global...
///
/// \author John Farrier
///
class TestVector
{
public:
static TestVector& Instance();
void pushBackTest(std::shared_ptr<BenchmarkInfo> x);
size_t getTestSize() const;
void forEachTest(std::function<void(std::shared_ptr<BenchmarkInfo>)> f);
void pushBackBaseline(std::shared_ptr<BenchmarkInfo> x);
size_t getBaselineSize() const;
void forEachBaseline(std::function<void(std::shared_ptr<BenchmarkInfo>)> f);
std::shared_ptr<BenchmarkInfo> getBaseline(const std::string& groupName);
private:
///
/// Default Constructor
///
TestVector();
///
/// \brief Pimpl Idiom
///
class Impl;
///
/// \brief Pimpl Idiom
///
Pimpl<Impl> pimpl;
};
}
#endif
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.
John Farrier is a professional C++ software engineer that specializes in modeling, simulation, and architecture development.
Specialties:
LVC Modeling & Simulation
Software Engineering, C++11, C++98, C, C#, FORTRAN, Python
Software Performance Optimization
Software Requirements Development
Technical Project and Team Leadership