Package io.deephaven.configuration
Class DataDir
java.lang.Object
io.deephaven.configuration.DataDir
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Pathget()Gets the data directory, first by the system property "deephaven.dataDir" if present, next by the system property "workspace" if present, next by the environment variable "DEEPHAVEN_DATA_DIR" if present, and otherwise ".".static PathGets the data directory if the system property "deephaven.dataDir" or "workspace" is present, or if the environment variable "DEEPHAVEN_DATA_DIR" is present, otherwise sets the system property "deephaven.dataDir" todefaultValueand returnsdefaultValue.
-
Field Details
-
PROPERTY
- See Also:
-
ENV_VAR
- See Also:
-
-
Constructor Details
-
DataDir
public DataDir()
-
-
Method Details
-
get
Gets the data directory, first by the system property "deephaven.dataDir" if present, next by the system property "workspace" if present, next by the environment variable "DEEPHAVEN_DATA_DIR" if present, and otherwise ".".- Returns:
- the data directory
-
getOrSet
Gets the data directory if the system property "deephaven.dataDir" or "workspace" is present, or if the environment variable "DEEPHAVEN_DATA_DIR" is present, otherwise sets the system property "deephaven.dataDir" todefaultValueand returnsdefaultValue.- Parameters:
defaultValue- the value to set if none is present- Returns:
- the data directory
-