Java 类javax.servlet.jsp.tagext.TagAttributeInfo 实例源码

项目:tomcat7    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:tomcat7    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:tomcat7    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (VAR_NAME_FROM.equals(type)) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:tomcat7    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    for (Entry<String, NameEntry> entry : nameFromTable.entrySet()) {
        String key = entry.getKey();
        NameEntry nameEntry = nameTable.get(key);
        NameEntry nameFromEntry = entry.getValue();
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", key);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        key, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:lams    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:apache-tomcat-7.0.73-with-comment    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:apache-tomcat-7.0.73-with-comment    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:apache-tomcat-7.0.73-with-comment    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (VAR_NAME_FROM.equals(type)) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:apache-tomcat-7.0.73-with-comment    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    for (Entry<String, NameEntry> entry : nameFromTable.entrySet()) {
        String key = entry.getKey();
        NameEntry nameEntry = nameTable.get(key);
        NameEntry nameFromEntry = entry.getValue();
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", key);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        key, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:lazycat    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector.size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector.size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent, description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos, dynamicAttrsMapName);
        }
项目:lazycat    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    for (Entry<String, NameEntry> entry : nameFromTable.entrySet()) {
        String key = entry.getKey();
        NameEntry nameEntry = nameTable.get(key);
        NameEntry nameFromEntry = entry.getValue();
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode, "jsp.error.tagfile.nameFrom.noAttribute", key);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName()) || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode, "jsp.error.tagfile.nameFrom.badAttribute", key,
                        Integer.toString(node.getStart().getLineNumber()));
            }
        }
    }
}
项目:packagedrone    文件:TagFileProcessor.java   
private void checkUniqueName(String name, Name type, Node n,
                             TagAttributeInfo attr)
        throws JasperException {

    HashMap<String, NameEntry> table =
        (type == Name.VAR_NAME_FROM)? nameFromTable: nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (type != Name.TAG_DYNAMIC
                || nameEntry.getType() != Name.TAG_DYNAMIC) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique",
                type.getAttribute(), type.getDirective(),
                nameEntry.getType().getAttribute(),
                nameEntry.getType().getDirective(),
                Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:class-guard    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:class-guard    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:class-guard    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (type == VAR_NAME_FROM) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:class-guard    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    Iterator<String> iter = nameFromTable.keySet().iterator();
    while (iter.hasNext()) {
        String nameFrom = iter.next();
        NameEntry nameEntry = nameTable.get(nameFrom);
        NameEntry nameFromEntry = nameFromTable.get(nameFrom);
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", nameFrom);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        nameFrom, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:package-drone    文件:TagFileProcessor.java   
private void checkUniqueName(String name, Name type, Node n,
                             TagAttributeInfo attr)
        throws JasperException {

    HashMap<String, NameEntry> table =
        (type == Name.VAR_NAME_FROM)? nameFromTable: nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (type != Name.TAG_DYNAMIC
                || nameEntry.getType() != Name.TAG_DYNAMIC) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique",
                type.getAttribute(), type.getDirective(),
                nameEntry.getType().getAttribute(),
                nameEntry.getType().getDirective(),
                Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:apache-tomcat-7.0.57    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (type == VAR_NAME_FROM) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    Iterator<String> iter = nameFromTable.keySet().iterator();
    while (iter.hasNext()) {
        String nameFrom = iter.next();
        NameEntry nameEntry = nameTable.get(nameFrom);
        NameEntry nameFromEntry = nameFromTable.get(nameFrom);
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", nameFrom);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        nameFrom, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:apache-tomcat-7.0.57    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (type == VAR_NAME_FROM) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:apache-tomcat-7.0.57    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    Iterator<String> iter = nameFromTable.keySet().iterator();
    while (iter.hasNext()) {
        String nameFrom = iter.next();
        NameEntry nameEntry = nameTable.get(nameFrom);
        NameEntry nameFromEntry = nameFromTable.get(nameFrom);
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", nameFrom);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        nameFrom, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:WBSAirback    文件:JasperTagInfo.java   
public JasperTagInfo(String tagName,
        String tagClassName,
        String bodyContent,
        String infoString,
        TagLibraryInfo taglib,
        TagExtraInfo tagExtraInfo,
        TagAttributeInfo[] attributeInfo,
        String displayName,
        String smallIcon,
        String largeIcon,
        TagVariableInfo[] tvi,
        String mapName) {

    super(tagName, tagClassName, bodyContent, infoString, taglib,
            tagExtraInfo, attributeInfo, displayName, smallIcon, largeIcon,
            tvi);

    this.dynamicAttrsMapName = mapName;
}
项目:WBSAirback    文件:TagFileProcessor.java   
public TagInfo getTagInfo() throws JasperException {

            if (name == null) {
                // XXX Get it from tag file name
            }

            if (bodycontent == null) {
                bodycontent = TagInfo.BODY_CONTENT_SCRIPTLESS;
            }

            String tagClassName = JspUtil.getTagHandlerClassName(
                    path, tagLibInfo.getReliableURN(), err);

            TagVariableInfo[] tagVariableInfos = new TagVariableInfo[variableVector
                    .size()];
            variableVector.copyInto(tagVariableInfos);

            TagAttributeInfo[] tagAttributeInfo = new TagAttributeInfo[attributeVector
                    .size()];
            attributeVector.copyInto(tagAttributeInfo);

            return new JasperTagInfo(name, tagClassName, bodycontent,
                    description, tagLibInfo, tei, tagAttributeInfo,
                    displayName, smallIcon, largeIcon, tagVariableInfos,
                    dynamicAttrsMapName);
        }
项目:WBSAirback    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap<String, NameEntry> table = (type == VAR_NAME_FROM) ? nameFromTable : nameTable;
    NameEntry nameEntry = table.get(name);
    if (nameEntry != null) {
        if (!TAG_DYNAMIC.equals(type) ||
                !TAG_DYNAMIC.equals(nameEntry.getType())) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:WBSAirback    文件:TagFileProcessor.java   
/**
 * Perform miscellaneous checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    Iterator<String> iter = nameFromTable.keySet().iterator();
    while (iter.hasNext()) {
        String nameFrom = iter.next();
        NameEntry nameEntry = nameTable.get(nameFrom);
        NameEntry nameFromEntry = nameFromTable.get(nameFrom);
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", nameFrom);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        nameFrom, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:tomcat7    文件:Node.java   
/**
 * Checks to see if the attribute of the given name is of type
 * JspFragment.
 */
public boolean checkIfAttributeIsJspFragment(String name) {
    boolean result = false;

    TagAttributeInfo[] attributes = tagInfo.getAttributes();
    for (int i = 0; i < attributes.length; i++) {
        if (attributes[i].getName().equals(name)
                && attributes[i].isFragment()) {
            result = true;
            break;
        }
    }

    return result;
}
项目:tomcat7    文件:Node.java   
JspAttribute(TagAttributeInfo tai, String qName, String uri,
        String localName, String value, boolean expr, ELNode.Nodes el,
        boolean dyn) {
    this.qName = qName;
    this.uri = uri;
    this.localName = localName;
    this.value = value;
    this.namedAttributeNode = null;
    this.expression = expr;
    this.el = el;
    this.dynamic = dyn;
    this.namedAttribute = false;
    this.tai = tai;
}
项目:tomcat7    文件:Node.java   
/**
 * Use this constructor if the JspAttribute represents a named
 * attribute. In this case, we have to store the nodes of the body of
 * the attribute.
 */
JspAttribute(NamedAttribute na, TagAttributeInfo tai, boolean dyn) {
    this.qName = na.getName();
    this.localName = na.getLocalName();
    this.value = null;
    this.namedAttributeNode = na;
    this.expression = false;
    this.el = null;
    this.dynamic = dyn;
    this.namedAttribute = true;
    this.tai = null;
}
项目:tomcat7    文件:TagFileProcessor.java   
public TagFileDirectiveVisitor(Compiler compiler,
        TagLibraryInfo tagLibInfo, String name, String path) {
    err = compiler.getErrorDispatcher();
    this.tagLibInfo = tagLibInfo;
    this.name = name;
    this.path = path;
    attributeVector = new Vector<TagAttributeInfo>();
    variableVector = new Vector<TagVariableInfo>();
}
项目:lams    文件:Node.java   
public TagAttributeInfo getTagAttributeInfo(String name) {
    TagInfo info = this.getTagInfo();
    if (info == null)
        return null;
    TagAttributeInfo[] tai = info.getAttributes();
    for (int i = 0; i < tai.length; i++) {
        if (tai[i].getName().equals(name)) {
            return tai[i];
        }
    }
    return null;
}
项目:lams    文件:Node.java   
/**
 * Checks to see if the attribute of the given name is of type
 * JspFragment.
 */
public boolean checkIfAttributeIsJspFragment(String name) {
    boolean result = false;

    TagAttributeInfo[] attributes = tagInfo.getAttributes();
    for (int i = 0; i < attributes.length; i++) {
        if (attributes[i].getName().equals(name)
                && attributes[i].isFragment()) {
            result = true;
            break;
        }
    }

    return result;
}
项目:lams    文件:Node.java   
JspAttribute(TagAttributeInfo tai, String qName, String uri,
        String localName, String value, boolean expr, ELNode.Nodes el,
        boolean dyn) {
    this.qName = qName;
    this.uri = uri;
    this.localName = localName;
    this.value = value;
    this.namedAttributeNode = null;
    this.expression = expr;
    this.el = el;
    this.dynamic = dyn;
    this.namedAttribute = false;
    this.tai = tai;
}
项目:lams    文件:Node.java   
/**
 * Use this constructor if the JspAttribute represents a named
 * attribute. In this case, we have to store the nodes of the body of
 * the attribute.
 */
JspAttribute(NamedAttribute na, TagAttributeInfo tai, boolean dyn) {
    this.qName = na.getName();
    this.localName = na.getLocalName();
    this.value = null;
    this.namedAttributeNode = na;
    this.expression = false;
    this.el = null;
    this.dynamic = dyn;
    this.namedAttribute = true;
    this.tai = null;
}
项目:lams    文件:TagFileProcessor.java   
private void checkUniqueName(String name, String type, Node n,
        TagAttributeInfo attr) throws JasperException {

    HashMap table = (type == VAR_NAME_FROM) ? nameFromTable : nameTable;
    NameEntry nameEntry = (NameEntry) table.get(name);
    if (nameEntry != null) {
        if (type != TAG_DYNAMIC || nameEntry.getType() != TAG_DYNAMIC) {
            int line = nameEntry.getNode().getStart().getLineNumber();
            err.jspError(n, "jsp.error.tagfile.nameNotUnique", type,
                    nameEntry.getType(), Integer.toString(line));
        }
    } else {
        table.put(name, new NameEntry(type, n, attr));
    }
}
项目:lams    文件:TagFileProcessor.java   
/**
 * Perform miscellean checks after the nodes are visited.
 */
void postCheck() throws JasperException {
    // Check that var.name-from-attributes has valid values.
    Iterator iter = nameFromTable.keySet().iterator();
    while (iter.hasNext()) {
        String nameFrom = (String) iter.next();
        NameEntry nameEntry = (NameEntry) nameTable.get(nameFrom);
        NameEntry nameFromEntry = (NameEntry) nameFromTable
                .get(nameFrom);
        Node nameFromNode = nameFromEntry.getNode();
        if (nameEntry == null) {
            err.jspError(nameFromNode,
                    "jsp.error.tagfile.nameFrom.noAttribute", nameFrom);
        } else {
            Node node = nameEntry.getNode();
            TagAttributeInfo tagAttr = nameEntry.getTagAttributeInfo();
            if (!"java.lang.String".equals(tagAttr.getTypeName())
                    || !tagAttr.isRequired()
                    || tagAttr.canBeRequestTime()) {
                err.jspError(nameFromNode,
                        "jsp.error.tagfile.nameFrom.badAttribute",
                        nameFrom, Integer.toString(node.getStart()
                                .getLineNumber()));
            }
        }
    }
}
项目:apache-tomcat-7.0.73-with-comment    文件:Node.java   
/**
 * Checks to see if the attribute of the given name is of type
 * JspFragment.
 */
public boolean checkIfAttributeIsJspFragment(String name) {
    boolean result = false;

    TagAttributeInfo[] attributes = tagInfo.getAttributes();
    for (int i = 0; i < attributes.length; i++) {
        if (attributes[i].getName().equals(name)
                && attributes[i].isFragment()) {
            result = true;
            break;
        }
    }

    return result;
}