Spring Framework EnumerablePropertySource - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Spring Framework EnumerablePropertySource class.

This code example shows how to use the following methods:
 *  
 * @author ebahtijaragic 
 */ 
public class ArchaiusSpringPropertySource extends EnumerablePropertySource<Map<String, Object>> {
	public ArchaiusSpringPropertySource(String name) {
		super(name, new HashMap<String, Object>());
	} 
 
	@Override 
	public String[] getPropertyNames() {
		return Iterators.toArray(ConfigurationManager.getConfigInstance().getKeys(), String.class);
	} 
 
	@Override 
	public Object getProperty(String name) {
		return DynamicPropertyFactory.getInstance().getStringProperty(name, null).get();
	} 
} 
4
CodeRank