Issue #9537 Support error-on-el-not-found for jsp-property-group (#9625)

This commit is contained in:
Jan Bartel 2023-04-05 18:39:09 +10:00 committed by GitHub
parent 2c74d93c56
commit 5df37bf733
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 1 deletions

View File

@ -1746,6 +1746,7 @@ public class ServletContextHandler extends ContextHandler implements Graceful
private String _defaultContentType;
private String _buffer;
private String _errorOnUndeclaredNamespace;
private String _errorOnELNotFound;
@Override
public java.util.Collection<String> getUrlPatterns()
@ -1768,7 +1769,7 @@ public class ServletContextHandler extends ContextHandler implements Graceful
@Override
public String getErrorOnELNotFound()
{
return "true";
return _errorOnELNotFound;
}
public void setElIgnored(String s)
@ -1822,6 +1823,11 @@ public class ServletContextHandler extends ContextHandler implements Graceful
_errorOnUndeclaredNamespace = errorOnUndeclaredNamespace;
}
public void setErrorOnELNotFound(String errorOnELNotFound)
{
_errorOnELNotFound = errorOnELNotFound;
}
@Override
public String getScriptingInvalid()
{
@ -1893,6 +1899,7 @@ public class ServletContextHandler extends ContextHandler implements Graceful
{
StringBuilder sb = new StringBuilder();
sb.append("JspPropertyGroupDescriptor:");
sb.append(" error-on-el-not-found=").append(_errorOnELNotFound);
sb.append(" el-ignored=").append(_elIgnored);
sb.append(" is-xml=").append(_isXml);
sb.append(" page-encoding=").append(_pageEncoding);

View File

@ -1194,6 +1194,7 @@ public class StandardDescriptorProcessor extends IterativeDescriptorProcessor
jpg.addUrlPattern(url);
}
jpg.setErrorOnELNotFound(group.getString("error-on-el-not-found", false, true));
jpg.setElIgnored(group.getString("el-ignored", false, true));
jpg.setPageEncoding(group.getString("page-encoding", false, true));
jpg.setScriptingInvalid(group.getString("scripting-invalid", false, true));