View Javadoc
1 package org.argosfields.spring; 2 3 import java.util.Properties; 4 5 import org.eclipse.jface.preference.IPreferenceStore; 6 import org.eclipse.jface.preference.JFacePreferences; 7 import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer; 8 9 /*** 10 * SpringContextConfigurator.java 11 * 12 * @author Xavier Cho 13 * @version $Revision: 1.1 $ $Date: 2004/04/15 05:43:55 $ 14 */ 15 public class SpringContextConfigurator extends PropertyPlaceholderConfigurer { 16 17 /*** 18 * @see org.springframework.beans.factory.config.PropertyPlaceholderConfigurer#resolvePlaceholder(java.lang.String, java.util.Properties) 19 */ 20 protected String resolvePlaceholder( 21 final String placeholder, 22 final Properties props) { 23 IPreferenceStore prefs = JFacePreferences.getPreferenceStore(); 24 String value = prefs.getString(placeholder); 25 26 if (value == null) { 27 value = super.resolvePlaceholder(placeholder, props); 28 } 29 30 return value; 31 } 32 }

This page was automatically generated by Maven