 |
PhoenixMock
1.8.7
Tools to split/merge/print mock used in Phoenix
|
Go to the documentation of this file.
24 std::list<std::string> listFile;
37 std::vector<std::string> vecFile1;
40 std::vector<std::string> vecFile2;
54 std::vector<std::string> vecFoundFile =
phoenix_find(
"./*.cmake");
58 int main(
int argc,
char** argv){
59 std::list<std::string> listArg;
bool getListFileInDir(std::list< std::string > &listFile, const std::string &dirName, const std::string &expr)
Get the list of files in a directory.
time_t getFileModificationTime(const std::string &fileName)
Get the last modification time of the given file.
time_t getFileInDirPerTime(std::vector< std::string > &vecFile, const std::string &dirName, time_t mostRecentTime)
Get the list of most recent files in a directory.
void testStringSystem()
Test the string system function.
std::string phoenix_getenv(const std::string &varName)
Get the value of the given environment variable.
bool phoenix_unsetenv(const std::string &name)
Unset a environment variable.
bool saveFileContent(const std::string &filename, const std::string &content)
Save a string in a file.
bool phoenix_setenv(const std::string &name, const std::string &value, int overwrite)
Set a environment variable.
bool isStringMatchRegex(const std::string &str, const std::string &expression)
Fonction qui dit si une chaine de caractère correspond à une expression régulière de regex.
bool phoenix_chmod(const std::string &fileName, mode_t __mode)
Change the mode of a file or directory.
bool createDirIfNotExist(const std::string &directoryName)
Creates a directory if it does not exist.
void makeListArgument(std::list< std::string > &listArgument, int argc, char **argv)
Makes the argument list of a program.
std::string getProgramDirectory()
Get the program directory.
std::string getCurrentNodeName()
Get the name of the current node on which the program is running.
bool getListAllFileInDir(std::list< std::string > &listFile, const std::string &dirName)
Get the list of files in a directory.
void getListFileInCurrentDir(std::list< std::string > &listFile, const std::string &expr)
Function like a ls in shell.
#define phoenix_assert(isOk)
std::string getProgramLocation()
Get the program location.
std::string getHomeDir()
Gets the $HOME directory.
void phoenix_find(std::vector< std::string > &vecFile, const std::string &path)
Find all files which matches the path expression (example : /path/*.cpp)
int main(int argc, char **argv)
std::string getProgramPrefix()
Get the program prefix (installation directory without /bin)