diff options
| author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-08-01 17:32:37 -0400 |
|---|---|---|
| committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2013-08-01 17:32:37 -0400 |
| commit | 741642ba531e487c18c8139c4a2e9510eed0466d (patch) | |
| tree | 8722e1ca4d49dcb74be2429bdbe65b396aeed7c2 /node/Utils.hpp | |
| parent | 8d30d51cf3925007a4f773928b62269836228b44 (diff) | |
| download | infinitytier-741642ba531e487c18c8139c4a2e9510eed0466d.tar.gz infinitytier-741642ba531e487c18c8139c4a2e9510eed0466d.zip | |
netconf service work
Diffstat (limited to 'node/Utils.hpp')
| -rw-r--r-- | node/Utils.hpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/node/Utils.hpp b/node/Utils.hpp index de7acf0e..a222ca4f 100644 --- a/node/Utils.hpp +++ b/node/Utils.hpp @@ -120,6 +120,15 @@ public: static uint64_t getLastModified(const char *path); /** + * @param path Path to check + * @return True if file or directory exists at path location + */ + static inline bool fileExists(const char *path) + { + return (getLastModified(path) != 0); + } + + /** * @param t64 Time in ms since epoch * @return RFC1123 date string */ |
