You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2020/01/30 18:51:03 UTC
[tomcat] 01/02: Jakarta EL 4.0 will add missing generics
This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit 3217a7b0a664193952a8b8311a125db0ee834310
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Jan 27 21:51:44 2020 +0000
Jakarta EL 4.0 will add missing generics
---
java/jakarta/el/ELContext.java | 7 ++-----
java/jakarta/el/StandardELContext.java | 6 ++----
2 files changed, 4 insertions(+), 9 deletions(-)
diff --git a/java/jakarta/el/ELContext.java b/java/jakarta/el/ELContext.java
index aae67a4..8f622b1 100644
--- a/java/jakarta/el/ELContext.java
+++ b/java/jakarta/el/ELContext.java
@@ -64,7 +64,6 @@ public abstract class ELContext {
return this.resolved;
}
- // Can't use Class<?> because API needs to match specification
/**
* Add an object to this EL context under the given key.
*
@@ -74,8 +73,7 @@ public abstract class ELContext {
* @throws NullPointerException
* If the supplied key or context is <code>null</code>
*/
- public void putContext(@SuppressWarnings("rawtypes") Class key,
- Object contextObject) {
+ public void putContext(Class<?> key, Object contextObject) {
Objects.requireNonNull(key);
Objects.requireNonNull(contextObject);
@@ -86,7 +84,6 @@ public abstract class ELContext {
this.map.put(key, contextObject);
}
- // Can't use Class<?> because API needs to match specification
/**
* Obtain the context object for the given key.
*
@@ -97,7 +94,7 @@ public abstract class ELContext {
* @throws NullPointerException
* If the supplied key is <code>null</code>
*/
- public Object getContext(@SuppressWarnings("rawtypes") Class key) {
+ public Object getContext(Class<?> key) {
Objects.requireNonNull(key);
if (this.map == null) {
return null;
diff --git a/java/jakarta/el/StandardELContext.java b/java/jakarta/el/StandardELContext.java
index ae43a73..59bffbf 100644
--- a/java/jakarta/el/StandardELContext.java
+++ b/java/jakarta/el/StandardELContext.java
@@ -73,10 +73,8 @@ public class StandardELContext extends ELContext {
standardResolver.add(context.getELResolver());
}
- // Can't use Class<?> because API needs to match specification
@Override
- public void putContext(@SuppressWarnings("rawtypes") Class key,
- Object contextObject) {
+ public void putContext(Class<?> key, Object contextObject) {
if (wrappedContext == null) {
super.putContext(key, contextObject);
} else {
@@ -85,7 +83,7 @@ public class StandardELContext extends ELContext {
}
@Override
- public Object getContext(@SuppressWarnings("rawtypes") Class key) {
+ public Object getContext(Class<?> key) {
if (wrappedContext == null) {
return super.getContext(key);
} else {
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org