Author: kkolinko Date: Mon May 28 18:25:46 2012 New Revision: 1343352 URL: http://svn.apache.org/viewvc?rev=1343352&view=rev Log: CTR: whitespace tabs -> spaces. No functional change.
Modified: tomcat/tc6.0.x/trunk/java/javax/el/ResourceBundleELResolver.java Modified: tomcat/tc6.0.x/trunk/java/javax/el/ResourceBundleELResolver.java URL: http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/javax/el/ResourceBundleELResolver.java?rev=1343352&r1=1343351&r2=1343352&view=diff ============================================================================== --- tomcat/tc6.0.x/trunk/java/javax/el/ResourceBundleELResolver.java (original) +++ tomcat/tc6.0.x/trunk/java/javax/el/ResourceBundleELResolver.java Mon May 28 18:25:46 2012 @@ -27,102 +27,102 @@ import java.util.ResourceBundle; public class ResourceBundleELResolver extends ELResolver { - public ResourceBundleELResolver() { - super(); - } - - public Object getValue(ELContext context, Object base, Object property) - throws NullPointerException, PropertyNotFoundException, ELException { - if (context == null) { - throw new NullPointerException(); - } - - if (base instanceof ResourceBundle) { - if (property != null) { - try { - Object result = ((ResourceBundle) base).getObject(property - .toString()); - context.setPropertyResolved(true); - return result; - } catch (MissingResourceException mre) { - return "???" + property.toString() + "???"; - } - } - } - - return null; - } - - public Class<?> getType(ELContext context, Object base, Object property) - throws NullPointerException, PropertyNotFoundException, ELException { - if (context == null) { - throw new NullPointerException(); - } - - if (base instanceof ResourceBundle) { - context.setPropertyResolved(true); - } - - return null; - } - - public void setValue(ELContext context, Object base, Object property, - Object value) throws NullPointerException, - PropertyNotFoundException, PropertyNotWritableException, - ELException { - if (context == null) { - throw new NullPointerException(); - } - - if (base instanceof ResourceBundle) { - context.setPropertyResolved(true); - throw new PropertyNotWritableException(message(context, - "resolverNotWriteable", new Object[] { base.getClass() - .getName() })); - } - } - - public boolean isReadOnly(ELContext context, Object base, Object property) - throws NullPointerException, PropertyNotFoundException, ELException { - if (context == null) { - throw new NullPointerException(); - } - - if (base instanceof ResourceBundle) { - context.setPropertyResolved(true); - } - - return true; - } - - public Iterator getFeatureDescriptors(ELContext context, Object base) { - if (base instanceof ResourceBundle) { - List<FeatureDescriptor> feats = new ArrayList<FeatureDescriptor>(); - Enumeration e = ((ResourceBundle) base).getKeys(); - FeatureDescriptor feat; - String key; - while (e.hasMoreElements()) { - key = (String) e.nextElement(); - feat = new FeatureDescriptor(); - feat.setDisplayName(key); - feat.setExpert(false); - feat.setHidden(false); - feat.setName(key); - feat.setPreferred(true); - feat.setValue(RESOLVABLE_AT_DESIGN_TIME, Boolean.TRUE); - feat.setValue(TYPE, String.class); - feats.add(feat); - } - return feats.iterator(); - } - return null; - } - - public Class<?> getCommonPropertyType(ELContext context, Object base) { - if (base instanceof ResourceBundle) { - return String.class; - } - return null; - } + public ResourceBundleELResolver() { + super(); + } + + public Object getValue(ELContext context, Object base, Object property) + throws NullPointerException, PropertyNotFoundException, ELException { + if (context == null) { + throw new NullPointerException(); + } + + if (base instanceof ResourceBundle) { + if (property != null) { + try { + Object result = ((ResourceBundle) base).getObject(property + .toString()); + context.setPropertyResolved(true); + return result; + } catch (MissingResourceException mre) { + return "???" + property.toString() + "???"; + } + } + } + + return null; + } + + public Class<?> getType(ELContext context, Object base, Object property) + throws NullPointerException, PropertyNotFoundException, ELException { + if (context == null) { + throw new NullPointerException(); + } + + if (base instanceof ResourceBundle) { + context.setPropertyResolved(true); + } + + return null; + } + + public void setValue(ELContext context, Object base, Object property, + Object value) throws NullPointerException, + PropertyNotFoundException, PropertyNotWritableException, + ELException { + if (context == null) { + throw new NullPointerException(); + } + + if (base instanceof ResourceBundle) { + context.setPropertyResolved(true); + throw new PropertyNotWritableException(message(context, + "resolverNotWriteable", new Object[] { base.getClass() + .getName() })); + } + } + + public boolean isReadOnly(ELContext context, Object base, Object property) + throws NullPointerException, PropertyNotFoundException, ELException { + if (context == null) { + throw new NullPointerException(); + } + + if (base instanceof ResourceBundle) { + context.setPropertyResolved(true); + } + + return true; + } + + public Iterator getFeatureDescriptors(ELContext context, Object base) { + if (base instanceof ResourceBundle) { + List<FeatureDescriptor> feats = new ArrayList<FeatureDescriptor>(); + Enumeration e = ((ResourceBundle) base).getKeys(); + FeatureDescriptor feat; + String key; + while (e.hasMoreElements()) { + key = (String) e.nextElement(); + feat = new FeatureDescriptor(); + feat.setDisplayName(key); + feat.setExpert(false); + feat.setHidden(false); + feat.setName(key); + feat.setPreferred(true); + feat.setValue(RESOLVABLE_AT_DESIGN_TIME, Boolean.TRUE); + feat.setValue(TYPE, String.class); + feats.add(feat); + } + return feats.iterator(); + } + return null; + } + + public Class<?> getCommonPropertyType(ELContext context, Object base) { + if (base instanceof ResourceBundle) { + return String.class; + } + return null; + } } --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org