1 package edu.calpoly.records.spring; 2 3 import java.util.Properties; 4 5 import org.kuali.common.util.PropertyUtils; 6 import org.kuali.common.util.execute.Executable; 7 import org.kuali.common.util.spring.SpringUtils; 8 import org.springframework.core.env.ConfigurableEnvironment; 9 10 public class ShowPropertySourcesExecutable implements Executable { 11 12 ConfigurableEnvironment environment; 13 14 public ShowPropertySourcesExecutable(ConfigurableEnvironment environment) { 15 super(); 16 this.environment = environment; 17 } 18 19 @Override 20 public void execute() { 21 Properties properties = SpringUtils.getAllEnumerableProperties(environment); 22 PropertyUtils.info(properties); 23 SpringUtils.showPropertySources(environment); 24 } 25 26 public ConfigurableEnvironment getEnvironment() { 27 return environment; 28 } 29 30 public void setEnvironment(ConfigurableEnvironment environment) { 31 this.environment = environment; 32 } 33 34 }