Class ApplicationPreferences
java.lang.Object
slash.navigation.converter.gui.helpers.ApplicationPreferences
Owns the flat, directly
Preferences-backed getters and setters that
used to live on BaseRouteConverter: selection thresholds, the
last-used paths for photo/audio/upload, login credentials and a handful of
enum-valued preferences (issue #214). Holds only the preference key
constants and the Preferences node passed in by the caller -- no
application state, no locking; every method here does exactly what the
matching BaseRouteConverter accessor did before the move.
The four constants that stay public (SHOW_ALL_POSITIONS_AFTER_LOADING_PREFERENCE,
RECENTER_AFTER_ZOOMING_PREFERENCE, TIME_ZONE_PREFERENCE,
PHOTO_TIMEZONE_PREFERENCE) are needed by BaseRouteConverter
itself to construct its BooleanModel/TimeZoneModel fields,
which read and write the preference directly rather than through this class.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionImportant: returns aCredentialsthat reads the current preference values lazily, since the instance is handed to the RemoteCatalog and may outlive a login/logout.booleanintgetMapViewPreference(String defaultMapViewName) doubleintdoubledoublevoidvoidsetAddAudioPreference(File path) voidsetAddPhotoPreference(File path) voidsetCategoryPreference(String category) voidsetCredentials(String userName, String password) voidsetDeletePositionsShiftTimesPreference(boolean deletePositionsShiftTimesPreference) voidsetFindPlacePreference(String searchPositionPreference) voidsetInsertStraightLineIntervalPreference(int insertStraightLineIntervalPreference) voidsetMapViewPreference(String mapViewName) voidsetNumberingStrategyPreference(NumberingStrategy numberingStrategy) voidsetNumberPatternPreference(NumberPattern numberPattern) voidsetSelectByDistancePreference(double selectByDistancePreference) voidsetSelectByOrderPreference(int selectByOrderPreference) voidsetSelectBySignificancePreference(double selectBySignificancePreference) voidsetSelectBySpeedPreference(double selectBySpeedPreference) voidsetTagStrategyPreference(TagStrategy tagStrategy) voidsetUploadRoutePreference(File path)
-
Field Details
-
SHOW_ALL_POSITIONS_AFTER_LOADING_PREFERENCE
- See Also:
-
RECENTER_AFTER_ZOOMING_PREFERENCE
- See Also:
-
TIME_ZONE_PREFERENCE
- See Also:
-
PHOTO_TIMEZONE_PREFERENCE
- See Also:
-
-
Constructor Details
-
ApplicationPreferences
-
-
Method Details
-
getSelectByDistancePreference
public double getSelectByDistancePreference() -
setSelectByDistancePreference
public void setSelectByDistancePreference(double selectByDistancePreference) -
getSelectByOrderPreference
public int getSelectByOrderPreference() -
setSelectByOrderPreference
public void setSelectByOrderPreference(int selectByOrderPreference) -
getInsertStraightLineIntervalPreference
public int getInsertStraightLineIntervalPreference() -
setInsertStraightLineIntervalPreference
public void setInsertStraightLineIntervalPreference(int insertStraightLineIntervalPreference) -
getSelectBySignificancePreference
public double getSelectBySignificancePreference() -
setSelectBySignificancePreference
public void setSelectBySignificancePreference(double selectBySignificancePreference) -
getDeletePositionsShiftTimesPreference
public boolean getDeletePositionsShiftTimesPreference() -
setDeletePositionsShiftTimesPreference
public void setDeletePositionsShiftTimesPreference(boolean deletePositionsShiftTimesPreference) -
getSelectBySpeedPreference
public double getSelectBySpeedPreference() -
setSelectBySpeedPreference
public void setSelectBySpeedPreference(double selectBySpeedPreference) -
getFindPlacePreference
-
setFindPlacePreference
-
getCredentials
Important: returns aCredentialsthat reads the current preference values lazily, since the instance is handed to the RemoteCatalog and may outlive a login/logout. -
getUserNamePreference
-
setCredentials
-
removeCredentials
public void removeCredentials() -
getUploadRoutePreference
-
setUploadRoutePreference
-
getAddPhotoPreference
-
setAddPhotoPreference
-
getAddAudioPreference
-
setAddAudioPreference
-
getTagStrategyPreference
-
getCategoryPreference
-
setCategoryPreference
-
getNumberPatternPreference
-
getNumberingStrategyPreference
-
getMapViewPreference
-
setMapViewPreference
-