Author: justin Date: Mon Jan 25 19:32:05 2010 New Revision: 902943 URL: http://svn.apache.org/viewvc?rev=902943&view=rev Log: SLING-1303 - Fixing compilation problem with BSF
Modified: sling/trunk/bundles/scripting/core/src/main/java/org/apache/sling/scripting/core/impl/helper/ProtectedBindings.java Modified: sling/trunk/bundles/scripting/core/src/main/java/org/apache/sling/scripting/core/impl/helper/ProtectedBindings.java URL: http://svn.apache.org/viewvc/sling/trunk/bundles/scripting/core/src/main/java/org/apache/sling/scripting/core/impl/helper/ProtectedBindings.java?rev=902943&r1=902942&r2=902943&view=diff ============================================================================== --- sling/trunk/bundles/scripting/core/src/main/java/org/apache/sling/scripting/core/impl/helper/ProtectedBindings.java (original) +++ sling/trunk/bundles/scripting/core/src/main/java/org/apache/sling/scripting/core/impl/helper/ProtectedBindings.java Mon Jan 25 19:32:05 2010 @@ -12,7 +12,7 @@ public class ProtectedBindings implements Bindings { private final Bindings wrapped; - private final Set<String> protectedKeys; + private final Set<Object> protectedKeys; public ProtectedBindings(Bindings wrapped) { this.wrapped = wrapped; @@ -24,7 +24,7 @@ * * @throws an IllegalArgumentException if the key is protected */ - public Object put(String key, Object value) { + public Object put(Object key, Object value) { if (protectedKeys.contains(key)) { throw new IllegalArgumentException(String.format("Key %s is protected.", key)); } @@ -34,8 +34,8 @@ /** * {...@inheritdoc} */ - public void putAll(Map<? extends String, ? extends Object> toMerge) { - for (String key : toMerge.keySet()) { + public void putAll(Map toMerge) { + for (Object key : toMerge.keySet()) { if (!protectedKeys.contains(key)) { wrapped.put(key, toMerge.get(key)); } @@ -74,7 +74,7 @@ * * @return an unmodifiable Set view of the map */ - public Set<java.util.Map.Entry<String, Object>> entrySet() { + public Set<java.util.Map.Entry<Object, Object>> entrySet() { return Collections.unmodifiableSet(wrapped.entrySet()); } @@ -91,7 +91,7 @@ * * @return an unmodifiable Set view of the map's keys */ - public Set<String> keySet() { + public Set<Object> keySet() { return Collections.unmodifiableSet(wrapped.keySet()); }