Class DeploymentConfiguration

java.lang.Object
net.sourceforge.jnlp.config.DeploymentConfiguration

public final class DeploymentConfiguration extends Object
Manages the various properties and configuration related to deployment. See: http://download.oracle.com/javase/1.5.0/docs/guide/deployment/deployment-guide/properties.html
  • Field Details

  • Constructor Details

    • DeploymentConfiguration

      public DeploymentConfiguration()
  • Method Details

    • isLocked

      public boolean isLocked(String key)
    • lock

      public void lock(String key)
    • unlock

      public void unlock(String key)
    • setLoadingException

      public void setLoadingException(ConfigurationException ex)
    • getLoadingException

      public ConfigurationException getLoadingException()
    • resetToDefaults

      public void resetToDefaults()
    • load

      public void load() throws ConfigurationException
      Initialize this deployment configuration by reading configuration files. Generally, it will try to continue and ignore errors it finds (such as file not found).
      Throws:
      ConfigurationException - if it encounters a fatal error.
    • load

      public void load(boolean fixIssues) throws ConfigurationException, MalformedURLException
      Initialize this deployment configuration by reading configuration files. Generally, it will try to continue and ignore errors it finds (such as file not found).
      Parameters:
      fixIssues - If true, fix issues that are discovered when reading configuration by resorting to the default values
      Throws:
      ConfigurationException - if it encounters a fatal error.
      MalformedURLException
    • copyTo

      public void copyTo(Properties target)
      Copies the current configuration into the target
      Parameters:
      target - properties where to copy actual ones
    • getProperty

      public String getProperty(String key)
      Get the value for the given key
      Parameters:
      key - the property key
      Returns:
      the value for the key, or null if it can not be found
    • getPropertyAsList

      public List<String> getPropertyAsList(String key)
    • getAllPropertyNames

      public Set<String> getAllPropertyNames()
      Returns:
      a Set containing all the property names
    • getRaw

      public Map<String,Setting> getRaw()
      Returns:
      a map containing property names and the corresponding settings
    • setProperty

      public void setProperty(String key, String value)
      Sets the value of corresponding to the key. If the value has been marked as locked, it is not changed
      Parameters:
      key - the key
      value - the value to be associated with the key
    • save

      public void save() throws IOException
      Saves all properties that are not part of default or system properties
      Throws:
      IOException - if unable to save the file
      IllegalStateException - if save() is called before load()
    • VVPossibleBrowserValues

      public static String VVPossibleBrowserValues()
      convenient method to show VVPossibleBrowserValues with all four params
      Returns:
      translation of VVPossibleBrowserValues with all params in