Class ConfigDir

java.lang.Object
io.deephaven.configuration.ConfigDir

public final class ConfigDir extends Object
  • Field Details

  • Constructor Details

    • ConfigDir

      public ConfigDir()
  • Method Details

    • get

      public static Optional<Path> get()
      Gets the config directory by the system property "deephaven.configDir" or environment variable "DEEPHAVEN_CONFIG_DIR" if present.
      Returns:
      the config directory
    • getOrSet

      public static Path getOrSet(String defaultValue)
      Gets the config directory if the system property "deephaven.configDir" or environment variable "DEEPHAVEN_CONFIG_DIR" is present, otherwise sets the system property "deephaven.configDir" to defaultValue and returns defaultValue.
      Parameters:
      defaultValue - the value to set if none is present
      Returns:
      the config directory
    • configurationFile

      public static String configurationFile()
      Gets the configuration file, first by the system property "Configuration.rootFile" if set; otherwise the filename "deephaven.prop" in the config directory if the file exists; and otherwise returns "dh-defaults.prop".
      Returns:
      the configuration file