Class PropertiesConfigurationSource

All Implemented Interfaces:
ConfigurationSource<AbstractHashConfigurationSource.HashConfigurationQuery<String,PropertiesConfigurationSource>,AbstractHashConfigurationSource.HashExecutableConfigurationQuery<String,PropertiesConfigurationSource>,AbstractHashConfigurationSource.HashListConfigurationQuery<String,PropertiesConfigurationSource>>, DefaultableConfigurationSource<AbstractHashConfigurationSource.HashConfigurationQuery<String,PropertiesConfigurationSource>,AbstractHashConfigurationSource.HashExecutableConfigurationQuery<String,PropertiesConfigurationSource>,AbstractHashConfigurationSource.HashListConfigurationQuery<String,PropertiesConfigurationSource>,PropertiesConfigurationSource>

public class PropertiesConfigurationSource extends AbstractHashConfigurationSource<String,PropertiesConfigurationSource>

A configuration source backed by a Properties object.

This source supports parameterized configuration properties defined as follows:


 Properties properties = new Properties();
 
 properties.setProperty("web.server_port", "8080");
 properties.setProperty("web.server_port[profile=\"ssl\"]", "8443");
 properties.setProperty("db.url[env=\"dev\"]", "jdbc:oracle:thin:@dev.db.server:1521:sid");
 properties.setProperty("db.url[env=\"prod\",zone=\"eu\"]", "jdbc:oracle:thin:@prod_eu.db.server:1521:sid");
 properties.setProperty("db.url[env=\"prod\",zone=\"us\"]", "jdbc:oracle:thin:@prod_us.db.server:1521:sid");
 
Since:
1.6
Author:
Jeremy Kuhn
See Also: