org.crsh.util.Utils.rethrow()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(2.5k)|赞(0)|评价(0)|浏览(95)

本文整理了Java中org.crsh.util.Utils.rethrow()方法的一些代码示例,展示了Utils.rethrow()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Utils.rethrow()方法的具体详情如下:
包路径:org.crsh.util.Utils
类名称:Utils
方法名:rethrow

Utils.rethrow介绍

暂无

代码示例

代码示例来源:origin: org.crashub/crash.plugins.jcr.core

public void file(String fileName, int length, InputStream data) throws IOException {
 try {
  SAXParserFactory factory = SAXParserFactory.newInstance();
  factory.setNamespaceAware(true);
  factory.setValidating(true);
  SAXParser parser = factory.newSAXParser();
  parser.parse(data, attributesHandler);
 }
 catch (Exception e) {
  Utils.rethrow(IOException.class, e);
 }
}

代码示例来源:origin: org.crashub/jcr.core

public void file(String fileName, int length, InputStream data) throws IOException {
 try {
  SAXParserFactory factory = SAXParserFactory.newInstance();
  factory.setNamespaceAware(true);
  factory.setValidating(true);
  SAXParser parser = factory.newSAXParser();
  parser.parse(data, attributesHandler);
 }
 catch (Exception e) {
  Utils.rethrow(IOException.class, e);
 }
}

代码示例来源:origin: org.crashub/crash.plugins.jcr.core

public void endDirectory(String directoryName) throws IOException {
 try {
  EndElement end = stack.removeLast();
  handler.endElement(end.uri, end.localName, end.qName);
  if (stack.isEmpty()) {
   for (String prefix : prefixes) {
    log.log(Level.FINE, "Removing prefix mapping " + prefix);
    handler.endPrefixMapping(prefix);
   }
   prefixes.clear();
  }
 }
 catch (Exception e) {
  Utils.rethrow(IOException.class, e);
 }
}

代码示例来源:origin: org.crashub/jcr.core

public void endDirectory(String directoryName) throws IOException {
 try {
  EndElement end = stack.removeLast();
  handler.endElement(end.uri, end.localName, end.qName);
  if (stack.isEmpty()) {
   for (String prefix : prefixes) {
    log.log(Level.FINE, "Removing prefix mapping " + prefix);
    handler.endPrefixMapping(prefix);
   }
   prefixes.clear();
  }
 }
 catch (Exception e) {
  Utils.rethrow(IOException.class, e);
 }
}

代码示例来源:origin: org.crashub/jcr.core

public void file(String fileName, int length, InputStream data) throws IOException {
 try {
  session.getWorkspace().importXML(path, data, ImportUUIDBehavior.IMPORT_UUID_COLLISION_REPLACE_EXISTING);
 }
 catch (RepositoryException e) {
  Utils.rethrow(IOException.class, e);
 }
}
public void endDirectory(String directoryName) throws IOException {

代码示例来源:origin: org.crashub/crash.plugins.jcr.core

public void file(String fileName, int length, InputStream data) throws IOException {
 try {
  session.getWorkspace().importXML(path, data, ImportUUIDBehavior.IMPORT_UUID_COLLISION_REPLACE_EXISTING);
 }
 catch (RepositoryException e) {
  Utils.rethrow(IOException.class, e);
 }
}
public void endDirectory(String directoryName) throws IOException {

相关文章