Package org.eweb4j.util.xml

Examples of org.eweb4j.util.xml.XMLReader


        continue;

      File configFile = new File(ConfigConstant.CONFIG_BASE_PATH
          + filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("dataSource");
        reader.setClass("dataSource", DBInfoConfigBean.class);
        DBInfoConfigBean dcb = reader.readOne();
        if (dcb == null) {
          error = rebuildXmlFile(configFile,
              ConfigInfoCons.REPAIR_FILE_INFO);
        } else {
          String error1 = CheckConfigBean.checkORMDBInfo(dcb,
View Full Code Here


      if (filePath == null || filePath.length() == 0)
        continue;

      File configFile = new File("orm" + filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("orm");
        reader.setClass("orm", ORMConfigBean.class);
        List<ORMConfigBean> ormList = reader.read();
        if (ormList == null || ormList.isEmpty()) {
          error = rebuildXmlFile(configFile,
              ConfigInfoCons.CANNOT_READ_ANY_CONFIG_INFO);
        } else {
          for (ORMConfigBean orm : ormList) {
View Full Code Here

        continue;

      File configFile = new File(ConfigConstant.CONFIG_BASE_PATH
          + filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("ioc");
        reader.setClass("ioc", IOCConfigBean.class);
        List<IOCConfigBean> iocList = reader.read();
        if (iocList == null || iocList.isEmpty()){
          error = rebuildXmlFile( ConfigInfoCons.CANNOT_READ_CONFIG_FILE, configFile);
        }else {
          for (IOCConfigBean ioc : iocList) {
            String error1 = CheckConfigBean.checkIOC(ioc, filePath);
View Full Code Here

      // 解决中文文件夹名
      File configFile = new File(ConfigConstant.CONFIG_BASE_PATH
          + filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("action");
        reader.setClass("action", ActionConfigBean.class);
        List<ActionConfigBean> mvcList = reader.read();

        if (mvcList == null || mvcList.isEmpty()) {
          error = rebuildXmlFile(configFile,
              ConfigErrCons.CANNOT_READ_CONFIG_INFO);
        } else {
View Full Code Here

    if (cb != null) {
      for (String filePath : cb.getMvc().getInterXmlFiles().getPath()) {
        if (filePath != null && filePath.length() > 0) {
          File configFile = new File(ConfigConstant.CONFIG_BASE_PATH + filePath);
          try {
            XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
            reader.setBeanName("interceptor");
            reader.setClass("interceptor", InterConfigBean.class);
            List<InterConfigBean> interList = reader.read();

            if (interList == null || interList.isEmpty()) {
              error = rebuildXmlFile(configFile, ConfigErrCons.CANNOT_READ_CONFIG_INFO);
            } else {
              for (Iterator<InterConfigBean> it = interList.iterator(); it.hasNext();) {
View Full Code Here

        continue;

      // 解决中文文件夹名
      File configFile = new File(ConfigConstant.CONFIG_BASE_PATH + filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("action");
        reader.setClass("action", ActionConfigBean.class);
        List<ActionConfigBean> mvcList = reader.read();

        if (mvcList == null || mvcList.isEmpty()) {
          error = rebuildXmlFile(configFile, ConfigErrCons.CANNOT_READ_CONFIG_INFO);
        } else {
          for (Iterator<ActionConfigBean> it = mvcList.iterator(); it.hasNext();) {
View Full Code Here

      if (filePath == null || filePath.length() == 0)
        continue;

      File configFile = new File(ConfigConstant.CONFIG_BASE_PATH+filePath);
      try {
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(configFile);
        reader.setBeanName("orm");
        reader.setClass("orm", ORMConfigBean.class);
        List<ORMConfigBean> ormList = reader.read();
        if (ormList == null || ormList.isEmpty()) {
          error = rebuildXmlFile(configFile, ConfigInfoCons.CANNOT_READ_ANY_CONFIG_INFO);
        } else {
          for (ORMConfigBean orm : ormList) {
            String error1 = CheckConfigBean.checkORM(orm, filePath);
View Full Code Here

      for (String filePath : cb.getMvc().getInterXmlFiles().getPath()) {
        if (filePath != null && filePath.length() > 0) {
          File configFile = new File(ConfigConstant.CONFIG_BASE_PATH
              + filePath);
          try {
            XMLReader reader = BeanXMLUtil
                .getBeanXMLReader(configFile);
            reader.setBeanName("interceptor");
            reader.setClass("interceptor", InterConfigBean.class);
            List<InterConfigBean> interList = reader.read();

            if (interList == null || interList.isEmpty()) {
              error = rebuildXmlFile(configFile,
                  "InterConfig.class : 读取不了任何配置文件信息!已经重写了配置文件,请重新填写完整,然后启动框架。");
            } else {
View Full Code Here

    if (readXml) {
      // 1.读取配置文件
      try {
        file = new File(startXmlPath);
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(file);
        reader.setBeanName("eweb4j");
        reader.setClass("eweb4j", ConfigBean.class);
        ConfigBean cb = reader.readOne();
        if (cb == null) {
          error = "EWeb4JConfig.class : 读取不了任何配置文件信息!已经重写了配置文件,请重新填写完整,然后启动框架。";
        } else {

          StringBuilder infos = new StringBuilder(
View Full Code Here

    if (readXml) {
      // 1.读取配置文件
      try {
        file = new File(startXmlPath);
        XMLReader reader = BeanXMLUtil.getBeanXMLReader(file);
        reader.setBeanName("eweb4j");
        reader.setClass("eweb4j", ConfigBean.class);
        ConfigBean cb = reader.readOne();
        if (cb == null) {
          error = " can not read any configuration info! But now have bean repaired, please restart.";
        } else {

          StringBuilder infos = new StringBuilder("EWeb4JConfig.start \n");
View Full Code Here

TOP

Related Classes of org.eweb4j.util.xml.XMLReader

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.