private void buildTree() {
        try {

            getModel().clearProjectResource();

            DefaultMutableTreeNode root = new DefaultMutableTreeNode();
            XmlReader xmlReader = new XmlReader();

            for (File file : projectFiles) {
                ProjectResource projectRes = xmlReader.readProject(file);
                projectRes.setFileName(file.getName());
                root.add(projectRes);
                if (getModel().isExistProject(projectRes)) {
                    throw new XmlConfigError("不允许存在重复的项目编号" + projectRes.getID());
                }
                getModel().addProjectResource(projectRes);
                for (NodeResource nodeRes : projectRes.getDefineNodes()) {
                    projectRes.add(nodeRes);
                    for (NodeJumpResource nodeJumpRes : nodeRes.getJumpNodes()) {
                        nodeRes.add(nodeJumpRes);
                    }

                    Field[] fields = XmlReader.class.getDeclaredFields();
                    for (Field field : fields) {
                        if (field.getName().startsWith("XML_ATTR_CELL_")) {
                            addNodeAttributeResource(nodeRes, field.getName().replaceAll("XML_ATTR_CELL_", ""));
                        }
                    }
                }
            }
            projectTree.setModel(new DefaultTreeModel(root));
        } catch (Exception e) {
            Logger.error(e.getMessage(), e);
        }

    }