Class Settings.DataSettings
java.lang.Object
gaiasky.util.SettingsObject
gaiasky.util.Settings.DataSettings
- Enclosing class:
Settings
Holds configuration options related to the data files.
-
Field Summary
FieldsModifier and TypeFieldDescriptionA list of all the enabled data files.booleanWhether to use high accuracy mode in the calculations.Location of the data directory.booleanPull current cloud data for supported objects.booleanWhether to use the real attitude of Gaia, or the analytical one (NSL).Location of the default reflection skybox (cubemap).Fields inherited from class SettingsObject
parent -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidapply()clone()com.badlogic.gdx.files.FileHandledataFileHandle(String path) com.badlogic.gdx.files.FileHandledataFileHandle(String path, String dsLocation) voiddisableDataset(Dataset dataset) voiddispose()booleanenableDataset(Path dataset) Adds the given dataset descriptor file to the list of enabled JSON files.booleanChecks whether the dataset with the given key is enabled.voidEvent notification call.protected voidvoidsetSkyboxLocation(String location) This method keeps compatibility with older versions of the configuration file where the settingreflectionSkyboxLocationwas calledskyboxLocation.protected voidMethods inherited from class SettingsObject
getRoot, isEnabled, setParent
-
Field Details
-
location
Location of the data directory. -
dataFiles
-
reflectionSkyboxLocation
Location of the default reflection skybox (cubemap). -
pullCloudData
public boolean pullCloudDataPull current cloud data for supported objects. -
highAccuracy
public boolean highAccuracyWhether to use high accuracy mode in the calculations. Results in more precise locations for some objects. -
realGaiaAttitude
public boolean realGaiaAttitudeWhether to use the real attitude of Gaia, or the analytical one (NSL).
-
-
Constructor Details
-
DataSettings
public DataSettings()
-
-
Method Details
-
setSkyboxLocation
This method keeps compatibility with older versions of the configuration file where the settingreflectionSkyboxLocationwas calledskyboxLocation.- Parameters:
location- The reflection skybox location.
-
dataPath
-
dataPath
-
dataFile
-
dataFile
-
dataFileHandle
-
dataFileHandle
-
isEnabled
Checks whether the dataset with the given key is enabled. This method works by checking if any of the currently enabled dataset descriptor file paths contains the key. If the key is very lenient, it will most probably return true, so be sure to set a correct key.- Parameters:
datasetKey- The dataset key to look up.- Returns:
- True if the dataset is currently enabled, false otherwise.
-
enableDataset
Adds the given dataset descriptor file to the list of enabled JSON files.- Parameters:
dataset- The dataset descriptor file pointer.- Returns:
- True if the catalog was added, false if it does not exist, or it is not a file, or it is not readable, or it is already in the list.
-
disableDataset
-
clone
- Overrides:
clonein classSettingsObject
-
setParentRecursive
- Specified by:
setParentRecursivein classSettingsObject
-
setupListeners
protected void setupListeners()- Specified by:
setupListenersin classSettingsObject
-
dispose
public void dispose()- Specified by:
disposein interfacecom.badlogic.gdx.utils.Disposable
-
apply
public void apply() -
notify
-