本文整理了Java中org.sakaiproject.util.Xml.readDocument()
方法的一些代码示例,展示了Xml.readDocument()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Xml.readDocument()
方法的具体详情如下:
包路径:org.sakaiproject.util.Xml
类名称:Xml
方法名:readDocument
[英]Read a DOM Document from xml in a file.
[中]从文件中的xml读取DOM文档。
代码示例来源:origin: org.sakaiproject.kernel/sakai-kernel-impl
/**
* {@inheritDoc}
*/
public void register(File toolXmlFile)
{
String path = toolXmlFile.getAbsolutePath();
if (!path.endsWith(".xml"))
{
log.info("register: skipping non .xml file: " + path);
return;
}
log.info("register: file: " + path);
Document doc = Xml.readDocument(path);
register(doc);
}
代码示例来源:origin: org.sakaiproject.kernel/sakai-kernel-impl
/**
* @inheritDoc
*/
public void register(File toolXmlFile, ServletContext context)
{
String path = toolXmlFile.getAbsolutePath();
if (!path.endsWith(".xml"))
{
log.info("register: skiping non .xml file: " + path);
return;
}
log.info("register: file: " + path);
Document doc = Xml.readDocument(path);
register(doc, context);
}
代码示例来源:origin: org.sakaiproject.kernel/sakai-kernel-impl
/**
* @inheritDoc
*/
public List<Tool> parseTools(File toolXmlFile)
{
if ( ! toolXmlFile.canRead() ) return null;
String path = toolXmlFile.getAbsolutePath();
if (!path.endsWith(".xml"))
{
log.info("register: skiping non .xml file: " + path);
return null;
}
log.info("parse-file: " + path);
Document doc = Xml.readDocument(path);
if ( doc == null ) return null;
return parseTools(doc);
}
代码示例来源:origin: org.sakaiproject.common/archive-impl2
Document doc = Xml.readDocument(fileName);
if (doc == null)
代码示例来源:origin: org.sakaiproject.common/archive-impl
Document doc = Xml.readDocument(fileName);
if (doc == null)
内容来源于网络,如有侵权,请联系作者删除!