Chaste  Release::2017.1
HeartFileFinder Class Reference

#include <HeartFileFinder.hpp>

+ Inheritance diagram for HeartFileFinder:
+ Collaboration diagram for HeartFileFinder:

Public Member Functions

 HeartFileFinder (const cp::path_type &rPath)
 
- Public Member Functions inherited from FileFinder
 FileFinder ()
 
 FileFinder (const std::string &rPath, RelativeTo::Value relativeTo)
 
 FileFinder (const std::string &rLeafName, const FileFinder &rParentOrSibling)
 
 FileFinder (const fs::path &rPath)
 
virtual ~FileFinder ()
 
virtual void SetPath (const std::string &rPath, RelativeTo::Value relativeTo)
 
virtual void SetPath (const std::string &rLeafName, const FileFinder &rParentOrSibling)
 
bool IsPathSet () const
 
bool Exists () const
 
bool IsFile () const
 
bool IsDir () const
 
bool IsEmpty () const
 
std::string GetAbsolutePath () const
 
bool IsNewerThan (const FileFinder &rOtherEntity) const
 
std::string GetLeafName () const
 
std::string GetLeafNameNoExtension () const
 
std::string GetExtension () const
 
FileFinder GetParent () const
 
std::string GetRelativePath (const FileFinder &rBasePath) const
 
FileFinder CopyTo (const FileFinder &rDest) const
 
void Remove () const
 
void DangerousRemove () const
 
std::vector< FileFinderFindMatches (const std::string &rPattern) const
 

Additional Inherited Members

- Static Public Member Functions inherited from FileFinder
static bool IsAbsolutePath (const std::string &rPath)
 
static void ReplaceSpacesWithUnderscores (std::string &rPath)
 
static void ReplaceUnderscoresWithSpaces (std::string &rPath)
 
static void FakePath (RelativeTo::Value fakeWhat, const std::string &rFakePath)
 
static void StopFaking ()
 

Detailed Description

A helper class for finding files, given paths which can be relative to various locations (e.g. the Chaste source tree root, the current directory, the Chaste test output directory, or an absolute path). This essentially just adds another constructor to FileFinder which takes in a cp::path_type.

Definition at line 50 of file HeartFileFinder.hpp.

Constructor & Destructor Documentation

HeartFileFinder::HeartFileFinder ( const cp::path_type &  rPath)

Create a file finder for the given path. This type includes both a path name, and an attribute specifying how this should be interpreted. See the XML schema for details.

Parameters
rPaththe path to the file to find

Definition at line 40 of file HeartFileFinder.cpp.

References RelativeTo::Absolute, RelativeTo::ChasteBuildRoot, RelativeTo::ChasteSourceRoot, RelativeTo::ChasteTestOutput, RelativeTo::CWD, HeartConfig::Instance(), NEVER_REACHED, and FileFinder::SetPath().


The documentation for this class was generated from the following files: