Package adams.core.gnuplot
Class AbstractScriptletWithDataFile
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.core.gnuplot.AbstractScriptlet
-
- adams.core.gnuplot.AbstractScriptletWithDataFile
-
- All Implemented Interfaces:
adams.core.Destroyable
,adams.core.ErrorProvider
,adams.core.GlobalInfoSupporter
,adams.core.io.AbsolutePathSupporter
,adams.core.logging.LoggingLevelHandler
,adams.core.logging.LoggingSupporter
,adams.core.option.OptionHandler
,adams.core.QuickInfoSupporter
,adams.core.SizeOfHandler
,Serializable
- Direct Known Subclasses:
AbstractPlotScriptlet
,MultiScriptlet
public abstract class AbstractScriptletWithDataFile extends AbstractScriptlet implements adams.core.io.AbsolutePathSupporter
Ancestor for scriplets that generate Gnuplot scripts (or parts of it). Specifies the data file.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected adams.core.io.PlaceholderFile
m_DataFile
the data file to use.protected boolean
m_UseAbsolutePath
whether to use absolute path for data file.-
Fields inherited from class adams.core.gnuplot.AbstractScriptlet
COMMENT, m_LastError, m_Owner
-
-
Constructor Summary
Constructors Constructor Description AbstractScriptletWithDataFile()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
check()
Hook method for performing checks.String
dataFileTipText()
Returns the tip text for this property.void
defineOptions()
Adds options to the internal list of options.String
getActualDataFile()
Returns the actual data file to use in the scripts.adams.core.io.PlaceholderFile
getDataFile()
Returns the data file in use.boolean
getUseAbsolutePath()
Returns whether to use the data file's absolute path.protected void
reset()
Resets the scriptlet.void
setDataFile(adams.core.io.PlaceholderFile value)
Sets the data file to use.void
setUseAbsolutePath(boolean value)
Sets whether to use the data file's absolute path.String
useAbsolutePathTipText()
Returns the tip text for this property.-
Methods inherited from class adams.core.gnuplot.AbstractScriptlet
doGenerate, generate, getLastError, getOwner, getQuickInfo, hasLastError, setOwner
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, initialize, loggingLevelTipText, newOptionManager, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
-
-
-
Method Detail
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceadams.core.option.OptionHandler
- Overrides:
defineOptions
in classadams.core.option.AbstractOptionHandler
-
reset
protected void reset()
Resets the scriptlet.- Overrides:
reset
in classAbstractScriptlet
-
setDataFile
public void setDataFile(adams.core.io.PlaceholderFile value)
Sets the data file to use.- Parameters:
value
- the data file
-
getDataFile
public adams.core.io.PlaceholderFile getDataFile()
Returns the data file in use.- Returns:
- the data file
-
dataFileTipText
public String dataFileTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
setUseAbsolutePath
public void setUseAbsolutePath(boolean value)
Sets whether to use the data file's absolute path.- Specified by:
setUseAbsolutePath
in interfaceadams.core.io.AbsolutePathSupporter
- Parameters:
value
- true if to use absolute path
-
getUseAbsolutePath
public boolean getUseAbsolutePath()
Returns whether to use the data file's absolute path.- Specified by:
getUseAbsolutePath
in interfaceadams.core.io.AbsolutePathSupporter
- Returns:
- true if to use absolute path
-
useAbsolutePathTipText
public String useAbsolutePathTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the explorer/experimenter gui
-
getActualDataFile
public String getActualDataFile()
Returns the actual data file to use in the scripts.- Returns:
- the actual filename
-
check
public String check()
Hook method for performing checks.
Default implementation only checks whether the data file is available.- Overrides:
check
in classAbstractScriptlet
- Returns:
- null if all checks passed, otherwise error message
-
-