Class Validator.ValidateVisitor
java.lang.Object
org.apache.jasper.compiler.Node.Visitor
org.apache.jasper.compiler.Validator.ValidateVisitor
- Enclosing class:
Validator
A visitor for validating nodes other than page directives
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate static final JspUtil.ValidAttribute[]private JspCompilationContextprivate static final JspUtil.ValidAttribute[]private ErrorDispatcherprivate static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private ClassLoaderprivate PageInfoprivate static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[]private static final JspUtil.ValidAttribute[] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidcheckNamedAttributes(Node.CustomTag n, Node.JspAttribute[] jspAttrs, int start, Hashtable<String, Object> tagDataAttrs) private voidcheckSetter(Node.CustomTag n, TagAttributeInfo tldattr) private voidcheckXmlAttributes(Node.CustomTag n, Node.JspAttribute[] jspAttrs, Hashtable<String, Object> tagDataAttrs) private StringescapePound(String value) private Stringprivate javax.el.FunctionMapperprivate Node.JspAttributegetJspAttribute(String qName, String uri, String localName, String value, Node n, boolean dynamic, TagAttributeInfo tagAttr) Preprocess attributes that can be expressions.private StringgetLiteral(Node n, String value) private StringGet the method name from the signature.private String[]getParameters(String signature) Get the parameters types from the function signature.private StringgetReturnType(String signature) Get the return type from the signature.private voidprivate voidthrowErrorIfExpression(Node n, String attrName, String actionName) private voidvalidateFunctions(ELNode.Nodes el, Node n) Validate functions in EL expressionsvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvoidvisit(Node.PlugIn n) voidvoidvoidvoidvoid
-
Field Details
-
pageInfo
-
err
-
loader
-
ctxt
-
jspRootAttrs
-
includeDirectiveAttrs
-
taglibDirectiveAttrs
-
includeActionAttrs
-
paramActionAttrs
-
forwardActionAttrs
-
getPropertyAttrs
-
setPropertyAttrs
-
useBeanAttrs
-
plugInAttrs
-
attributeAttrs
-
invokeAttrs
-
doBodyAttrs
-
jspOutputAttrs
-
-
Constructor Details
-
ValidateVisitor
ValidateVisitor(Compiler compiler)
-
-
Method Details
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
visit
- Overrides:
visitin classNode.Visitor- Throws:
JasperException
-
checkSetter
- Throws:
JasperException
-
checkXmlAttributes
private void checkXmlAttributes(Node.CustomTag n, Node.JspAttribute[] jspAttrs, Hashtable<String, Object> tagDataAttrs) throws JasperException- Throws:
JasperException
-
checkNamedAttributes
private void checkNamedAttributes(Node.CustomTag n, Node.JspAttribute[] jspAttrs, int start, Hashtable<String, Object> tagDataAttrs) throws JasperException- Throws:
JasperException
-
getJspAttribute
private Node.JspAttribute getJspAttribute(String qName, String uri, String localName, String value, Node n, boolean dynamic, TagAttributeInfo tagAttr) throws JasperException Preprocess attributes that can be expressions. Expression delimiters are stripped.If value is null, checks if there are any NamedAttribute subelements in the tree node, and if so, constructs a JspAttribute out of a child NamedAttribute node.
- Throws:
JasperException
-
getLiteral
-
throwErrorIfExpression
private void throwErrorIfExpression(Node n, String attrName, String actionName) throws JasperException - Throws:
JasperException
-
escapePound
-
findUri
-
validateFunctions
Validate functions in EL expressions- Throws:
JasperException
-
processSignature
- Throws:
JasperException
-
getReturnType
Get the return type from the signature.- Throws:
JasperException
-
getMethod
Get the method name from the signature.- Throws:
JasperException
-
getParameters
Get the parameters types from the function signature.- Returns:
- An array of parameter class names
- Throws:
JasperException
-
getFunctionMapper
- Throws:
JasperException
-