org.autoplot.datasource.AutoplotSettings

Autoplot's settings, stored in Java preferences, include things like the last folder opened. Also this code handles property resolution like ${HOME}/autoplot_data.


PREF_LAST_OPEN_FOLDER


PREF_RECENTLY_OPENED_FILES


PREF_LAST_OPEN_VAP_FOLDER


PREF_LAST_OPEN_VAP_FILE


PROP_AUTOPLOTDATA


PROP_FSCACHE


addPropertyChangeListener

addPropertyChangeListener( java.beans.PropertyChangeListener listener ) → void

Parameters

listener - a PropertyChangeListener

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


getAutoplotData

getAutoplotData( ) → String

return the location where Autoplot is storing its data. This includes bookmarks, history, and the file cache, and is typically "${HOME}/autoplot_data"

Returns:

the user's Autoplot data folder.

[search for examples] [view on GitHub] [view on old javadoc] [view source]


getFscache

getFscache( ) → String

Returns:

java.lang.String

[search for examples] [view on GitHub] [view on old javadoc] [view source]


getPreferences

getPreferences( java.lang.Class c ) → java.util.prefs.Preferences

wrapper that will handle legacy (v2016a) prefs, and will allow migration to ~/autoplot_data/config area.

Parameters

c - the class requesting preferences.

Returns:

the preferences object this class should use.

[search for examples] [view on GitHub] [view on old javadoc] [view source]


loadPreferences

loadPreferences( ) → void

load the preferences, which include the location of the autoplot_data directory and fscache. The system property AUTOPLOT_DATA will override the user preference autoplotData which is by default "${HOME}/autoplot_data", and can be set on the command line. The environment variable AUTOPLOT_DATA will also override the default location. AUTOPLOT_FSCACHE is the location of the remote file mirror storing lots of data and can be moved separately.

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


removePropertyChangeListener

removePropertyChangeListener( java.beans.PropertyChangeListener listener ) → void

Parameters

listener - a PropertyChangeListener

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


resolveProperty

resolveProperty( String name ) → String

resolve the property, resolving references. For example, ${HOME} is replaced with System.getProperty("user.home").

Parameters

name - the name to resolve, such as PROP_AUTOPLOTDATA or PROP_FSCACHE

Returns:

the value with references resolved. TODO: this should always make result end in slash...

[search for examples] [view on GitHub] [view on old javadoc] [view source]


setFscache

setFscache( String val ) → void

Parameters

val - a String

Returns:

void (returns nothing)

[search for examples] [view on GitHub] [view on old javadoc] [view source]


settings

settings( ) → org.autoplot.datasource.AutoplotSettings

Returns:

org.autoplot.datasource.AutoplotSettings

[search for examples] [view on GitHub] [view on old javadoc] [view source]