Go to the SVN repository for this file.
40 #define NCBI_USE_ERRCODE_X Util_File 74time_t cutoff_time = current.
GetTimeT();
76 if(cutoff_time < (time_t) age) {
85 if(!(*it)->IsFile()) {
94(*it)->GetTime(&modification, &access, &creation);
100time_t check_time = 0;
104check_time = modification.
GetTimeT();
114 if(check_time < cutoff_time) {
ncbi::TMaskedQueryRegions mask
void Remove(const string &mask, unsigned int age, ETimeMode tmode=eLastAccess)
Scan the target directory, find old files matching the specified mask, files deleted if permission is...
virtual bool OnRemove(const string &filename)
Reactor function called when file is about to be deleted.
CFileObsolete(const string &path)
ETimeMode
Defines if file is deleted based on its creation time (attribute modification) or last access time.
@ eLastModification
Last modification.
@ eLastAccess
Last access time.
Delete old files from the specified directory.
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#define ERR_POST_X(err_subcode, message)
Error posting with default error code and given error subcode.
void Info(CExceptionArgs_Base &args)
TEntries GetEntries(const string &mask=kEmptyStr, TGetEntriesFlags flags=0) const
Get directory entries based on the specified "mask".
virtual bool Exists(void) const
Check if directory "dirname" exists.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
time_t GetTimeT(void) const
Get time in time_t format.
@ eCurrent
Use current time. See also CCurrentTime.
Definition of all error codes used in util (xutil.lib).
Defines classes: CDirEntry, CFile, CDir, CSymLink, CMemoryFile, CFileUtil, CFileLock,...
Defines: CTimeFormat - storage class for time format.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4