switch to jakarta property names Signed-off-by: Scott Marlow <smarlow@redhat.com>
diff --git a/api/src/main/java/jakarta/el/ELUtil.java b/api/src/main/java/jakarta/el/ELUtil.java index 20ff1d1..772b264 100644 --- a/api/src/main/java/jakarta/el/ELUtil.java +++ b/api/src/main/java/jakarta/el/ELUtil.java
@@ -55,7 +55,7 @@ /* * For testing Backward Compatibility option static java.util.Properties properties = new java.util.Properties(); static - * { properties.setProperty("javax.el.bc2.2", "true"); } + * { properties.setProperty("jakarta.el.bc2.2", "true"); } */ public static ExpressionFactory exprFactory = ExpressionFactory.newInstance(/* properties */);
diff --git a/api/src/main/java/jakarta/el/ExpressionFactory.java b/api/src/main/java/jakarta/el/ExpressionFactory.java index d9c08ec..a7810bf 100644 --- a/api/src/main/java/jakarta/el/ExpressionFactory.java +++ b/api/src/main/java/jakarta/el/ExpressionFactory.java
@@ -123,14 +123,13 @@ * <p> * Properties are optional and can be ignored by an implementation. * - * TODO: determine if javax.el should change to jakarta.el * <p> - * The name of a property should start with "javax.el." + * The name of a property should start with "jakarta.el." * * <p> * The following are some suggested names for properties. * <ul> - * <li>javax.el.cacheSize</li> + * <li>jakarta.el.cacheSize</li> * </ul> * * @param properties Properties passed to the implementation. If null, then no properties.
diff --git a/impl/src/main/java/com/sun/el/ExpressionFactoryImpl.java b/impl/src/main/java/com/sun/el/ExpressionFactoryImpl.java index d5c31fe..71efa55 100644 --- a/impl/src/main/java/com/sun/el/ExpressionFactoryImpl.java +++ b/impl/src/main/java/com/sun/el/ExpressionFactoryImpl.java
@@ -52,9 +52,16 @@ public ExpressionFactoryImpl(Properties properties) { super(); this.properties = properties; - this.isBackwardCompatible22 = "true".equals(getProperty("javax.el.bc2.2")); + this.isBackwardCompatible22 = "true".equals(getProperty("jakarta.el.bc2.2")); } + /** + * Coerces an object to a specific type according to the Jakarta Expression Language type conversion rules. The custom + * type conversions in the <code>ELResolver</code>s are not considered. + * + * Jakarta Expression Language version 2.2 backward compatibility conversion rules apply if ExpressionFactoryImpl was created with property + * "jakarta.el.bc2.2" set to true. + */ @Override public Object coerceToType(Object obj, Class<?> type) { try {