4 #ifndef CASM_FileData_HH
5 #define CASM_FileData_HH
12 FileData(std::string
const &_path, std::time_t _timestamp)
Interface class to check and/or store path and last_write_time of file on disk. Used to determine if ...
bool exists() const
checks path for existing file. Does not alter stored timestamp
FileData(std::string const &_path)
Construct with path, timestamp is set if file exists at path.
FileData()
default constructor
std::time_t timestamp() const
return stored timestamp. Timestamp corresponds to last_write_time of file timestamp defaults to 0 if ...
bool empty() const
Returns true if path is empty.
std::string const & path() const
return stored path
bool up_to_date() const
checks timestamp of file at path. Returns true if last_write_time of file matches timestamp returns f...
void refresh()
Updates timestamp using stored path.
bool operator==(FileData const &other) const
returns true if other FileData has same stored path and timestamp
FileData(std::string const &_path, std::time_t _timestamp)
Construct with path and explicit timestamp.