OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2015 PDFium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef TESTING_UTILS_PATH_SERVICE_H_ | |
6 #define TESTING_UTILS_PATH_SERVICE_H_ | |
7 | |
8 #include <string> | |
9 | |
10 #ifdef _WIN32 | |
11 #define PATH_SEPARATOR '\\' | |
12 #else | |
13 #define PATH_SEPARATOR '/' | |
14 #endif | |
15 | |
16 // Get the various file directory and path information. | |
17 class PathService { | |
18 public: | |
19 static bool EndsWithSeparator(const std::string& path); | |
Lei Zhang
2015/11/07 01:48:51
Comments please.
Wei Li
2015/11/07 02:36:12
Done.
| |
20 static bool GetExecutableDir(std::string* path); | |
Lei Zhang
2015/11/07 01:48:51
Can this return a string, with an empty string as
Wei Li
2015/11/07 02:36:12
Yes, it can. But we would need to write special co
Lei Zhang
2015/11/07 02:43:30
We use it in a few places. In some ways it's easie
Wei Li
2015/11/09 18:08:19
Acknowledged.
| |
21 static bool GetSourceDir(std::string* path); | |
22 static bool GetTestDataDir(std::string* path); | |
23 // Get the full path for a test file under the test data directory. | |
24 static bool GetTestFilePath(const std::string& file_name, std::string* path); | |
25 }; | |
26 #endif // TESTING_UTILS_PATH_SERVICE_H_ | |
OLD | NEW |