Package adams.core
Class StringHistory
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.AbstractHistory<T>
-
- adams.core.AbstractPersistentHistory<String>
-
- adams.core.StringHistory
-
- All Implemented Interfaces:
LoggingSupporter
,SizeOfHandler
,Serializable
public class StringHistory extends AbstractPersistentHistory<String>
History for arbitrary strings.- Version:
- $Revision$
- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class adams.core.AbstractPersistentHistory
m_HistoryFile
-
Fields inherited from class adams.core.AbstractHistory
m_History, MAX_HISTORY_COUNT, MAX_HISTORY_LENGTH
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description StringHistory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected String
copy(String obj)
Creates a copy of the object.protected boolean
load()
Loads the history from disk.protected boolean
save()
Saves the history to disk.-
Methods inherited from class adams.core.AbstractPersistentHistory
add, clear, getHistoryFile, initialize, setHistoryFile
-
Methods inherited from class adams.core.AbstractHistory
getHistory, size
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
copy
protected String copy(String obj)
Creates a copy of the object.- Specified by:
copy
in classAbstractHistory<String>
- Parameters:
obj
- the object to copy
-
save
protected boolean save()
Saves the history to disk.- Specified by:
save
in classAbstractPersistentHistory<String>
- Returns:
- true if successfully saved
-
load
protected boolean load()
Loads the history from disk.- Specified by:
load
in classAbstractPersistentHistory<String>
- Returns:
- true if successfully loaded
-
-