@Test public void testGetXML() { System.out.println(parser.getXML("process", 0)); }
public Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion) { SAXReader reader = new SAXReader(); URL url = this.getClass().getResource("/" + processName.replaceAll("\\.", "/") + ".xml"); Document document; try { document = reader.read(url); } catch (Exception e) { logger.error("xml流程文件读取失败!模板名：" + processName); throw new NullPointerException("xml流程文件读取失败!模板名：" + processName + "\n" + e); } return document; }
Parser implements BaseParser { public Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion) { SAXReader reader = new SAXReader(); URL url = this.getClass().getResource("/" + processName.replaceAll("\\.", "/") + ".xml"); Document document; try { document = reader.read(url); } catch (Exception e) { logger.error("xml流程文件读取失败!模板名：" + processName); throw new NullPointerException("xml流程文件读取失败!模板名：" + processName + "\n" + e); } return document; } }
Parser implements BaseParser { public Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion) { SAXReader reader = new SAXReader(); URL url = this.getClass().getResource("/" + processName.replaceAll("\\.", "/") + ".xml"); Document document; try { document = reader.read(url); } catch (Exception e) { logger.error("xml流程文件读取失败!模板名：" + processName); throw new NullPointerException("xml流程文件读取失败!模板名：" + processName + "\n" + e); } return document; }  }
Parser implements BaseParser { public Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion) { SAXReader reader = new SAXReader(); URL url = this.getClass().getResource("/" + processName.replaceAll("\\.", "/") + ".xml"); Document document; try { document = reader.read(url); } catch (Exception e) { logger.error("xml流程文件读取失败!模板名：" + processName); throw new NullPointerException("xml流程文件读取失败!模板名：" + processName + "\n" + e); } return document; }  @Override boolean needRefresh(String processName, int processVersion, Definition oldDefinition); @Override Definition parse(String processName, int processVersion); Definition parser0(String name, int version, Document processXML, boolean status); Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion); }
Parser implements BaseParser { public Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion) { SAXReader reader = new SAXReader(); URL url = this.getClass().getResource("/" + processName.replaceAll("\\.", "/") + ".xml"); Document document; try { document = reader.read(url); } catch (Exception e) { logger.error("xml流程文件读取失败!模板名：" + processName); throw new NullPointerException("xml流程文件读取失败!模板名：" + processName + "\n" + e); } return document; }  @Override boolean needRefresh(String processName, int processVersion, Definition oldDefinition); @Override Definition parse(String processName, int processVersion); Definition parser0(String name, int version, Document processXML, boolean status); Document getXML(String processName, @SuppressWarnings("UnusedParameters") int processVersion); static Map<String, StateAround> stateLifeMap; }