Package adams.core.io.filechanged
Class LastModified
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.core.io.filechanged.AbstractFileChangeMonitor
-
- adams.core.io.filechanged.LastModified
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,FileChangeMonitor
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,QuickInfoSupporter
,SizeOfHandler
,Serializable
public class LastModified extends AbstractFileChangeMonitor
Uses the lastmodified timestamp.- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected long
m_LastModified
the lastmodified timestamp.-
Fields inherited from class adams.core.io.filechanged.AbstractFileChangeMonitor
m_File, m_Initialized
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description LastModified()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
checkChange(File file)
Performs the actual check whether the file has changed.protected String
doInitialize(File file)
Performs the actual initialization of the monitor with the specified file.protected String
doUpdate(File file)
Performs the actual updating of the monitor with the specified file.String
globalInfo()
Returns a string describing the object.protected void
reset()
Resets the scheme.-
Methods inherited from class adams.core.io.filechanged.AbstractFileChangeMonitor
checkFile, getMonitoredFile, getQuickInfo, hasChanged, initialize, isInitialized, update
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, defineOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
reset
protected void reset()
Resets the scheme.- Overrides:
reset
in classAbstractFileChangeMonitor
-
doInitialize
protected String doInitialize(File file)
Performs the actual initialization of the monitor with the specified file.- Specified by:
doInitialize
in classAbstractFileChangeMonitor
- Parameters:
file
- the file to initialize with- Returns:
- null if successful, otherwise error message
-
checkChange
protected boolean checkChange(File file)
Performs the actual check whether the file has changed.- Specified by:
checkChange
in classAbstractFileChangeMonitor
- Parameters:
file
- the file to check- Returns:
- true if changed
-
doUpdate
protected String doUpdate(File file)
Performs the actual updating of the monitor with the specified file.- Specified by:
doUpdate
in classAbstractFileChangeMonitor
- Parameters:
file
- the file to update with- Returns:
- null if successful, otherwise error message
-
-