2012-05-01 21:35:07 +04:00
|
|
|
/*============================================================================
|
|
|
|
CMake - Cross Platform Makefile Generator
|
|
|
|
Copyright 2000-2009 Kitware, Inc.
|
|
|
|
|
|
|
|
Distributed under the OSI-approved BSD License (the "License");
|
|
|
|
see accompanying file Copyright.txt for details.
|
|
|
|
|
|
|
|
This software is distributed WITHOUT ANY WARRANTY; without even the
|
|
|
|
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
See the License for more information.
|
|
|
|
============================================================================*/
|
|
|
|
|
|
|
|
#ifndef cmParseMumpsCoverage_h
|
|
|
|
#define cmParseMumpsCoverage_h
|
|
|
|
|
|
|
|
#include "cmStandardIncludes.h"
|
|
|
|
#include "cmCTestCoverageHandler.h"
|
|
|
|
|
|
|
|
/** \class cmParseMumpsCoverage
|
|
|
|
* \brief Parse Mumps coverage information
|
|
|
|
*
|
|
|
|
* This class is used as the base class for Mumps coverage
|
|
|
|
* parsing.
|
|
|
|
*/
|
|
|
|
class cmParseMumpsCoverage
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
cmParseMumpsCoverage(cmCTestCoverageHandlerContainer& cont,
|
|
|
|
cmCTest* ctest);
|
2012-05-01 22:36:18 +04:00
|
|
|
virtual ~cmParseMumpsCoverage();
|
2012-05-01 21:35:07 +04:00
|
|
|
// This is the toplevel coverage file locating the coverage files
|
|
|
|
// and the mumps source code package tree.
|
|
|
|
bool ReadCoverageFile(const char* file);
|
|
|
|
protected:
|
|
|
|
// sub classes will use this to
|
|
|
|
// load all coverage files found in the given directory
|
|
|
|
virtual bool LoadCoverageData(const char* d) = 0;
|
|
|
|
// search the package directory for mumps files and fill
|
|
|
|
// in the RoutineToDirectory map
|
|
|
|
bool LoadPackages(const char* dir);
|
|
|
|
// initialize the coverage information for a single mumps file
|
|
|
|
void InitializeMumpsFile(std::string& file);
|
2012-05-02 01:00:43 +04:00
|
|
|
// Find mumps file for routine
|
|
|
|
bool FindMumpsFile(std::string const& routine,
|
|
|
|
std::string& filepath);
|
2012-05-01 21:35:07 +04:00
|
|
|
protected:
|
2014-02-10 09:21:34 +04:00
|
|
|
std::map<std::string, std::string> RoutineToDirectory;
|
2012-05-01 21:35:07 +04:00
|
|
|
cmCTestCoverageHandlerContainer& Coverage;
|
|
|
|
cmCTest* CTest;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|