WrappedFilterConfig: Fix 'unchecked or unsafe operations' warning

- Use Collections.emptyEnumeration() which is available in Java 7,
  rather than the Collections.enumeration(Collections.emptyList())
  workaround that was used for Java 6 compatibility.

- Add type specification to prevent "unchecked conversion" warning.

- Remove @Suppress annotations that are no longer necessary.

Change-Id: Iba4b61330d5ca8a822b8121fe46fb20418e79347
This commit is contained in:
David Pursehouse
2016-11-13 07:22:46 -08:00
parent d2b6d71a1e
commit 3df35793e5

View File

@@ -39,10 +39,9 @@ class WrappedFilterConfig implements FilterConfig {
return null;
}
@SuppressWarnings({"rawtypes", "unchecked"})
@Override
public Enumeration getInitParameterNames() {
return Collections.enumeration(Collections.emptyList());
public Enumeration<String> getInitParameterNames() {
return Collections.emptyEnumeration();
}
@Override