本文整理了Java中com.sun.syndication.io.WireFeedInput.createSAXBuilder()
方法的一些代码示例,展示了WireFeedInput.createSAXBuilder()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。WireFeedInput.createSAXBuilder()
方法的具体详情如下:
包路径:com.sun.syndication.io.WireFeedInput
类名称:WireFeedInput
方法名:createSAXBuilder
[英]Creates and sets up a org.jdom2.input.SAXBuilder for parsing.
[中]创建并建立一个组织。jdom2。输入用于解析的SAXBuilder。
代码示例来源:origin: org.apache.marmotta/sesame-tools-rio-rss
/**
* Builds an WireFeed (RSS or Atom) from an W3C SAX InputSource.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom2.Document)'.
* <p>
* @param is W3C SAX InputSource to read to create the WireFeed.
* @return the WireFeed read from the W3C SAX InputSource.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(InputSource is) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
Document document = saxBuilder.build(is);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: rome/rome
/**
* Builds an WireFeed (RSS or Atom) from an W3C SAX InputSource.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom.Document)'.
* <p>
* @param is W3C SAX InputSource to read to create the WireFeed.
* @return the WireFeed read from the W3C SAX InputSource.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(InputSource is) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
Document document = saxBuilder.build(is);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: com.sun.syndication/com.springsource.com.sun.syndication
/**
* Builds an WireFeed (RSS or Atom) from an W3C SAX InputSource.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom.Document)'.
* <p>
* @param is W3C SAX InputSource to read to create the WireFeed.
* @return the WireFeed read from the W3C SAX InputSource.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(InputSource is) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
Document document = saxBuilder.build(is);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: apache/marmotta
/**
* Builds an WireFeed (RSS or Atom) from an W3C SAX InputSource.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom2.Document)'.
* <p>
* @param is W3C SAX InputSource to read to create the WireFeed.
* @return the WireFeed read from the W3C SAX InputSource.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(InputSource is) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
Document document = saxBuilder.build(is);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: rome/rome
/**
* Builds an WireFeed (RSS or Atom) from an Reader.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom.Document)'.
* <p>
* @param reader Reader to read to create the WireFeed.
* @return the WireFeed read from the Reader.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(Reader reader) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
if (_xmlHealerOn) {
reader = new XmlFixerReader(reader);
}
Document document = saxBuilder.build(reader);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: com.sun.syndication/com.springsource.com.sun.syndication
/**
* Builds an WireFeed (RSS or Atom) from an Reader.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom.Document)'.
* <p>
* @param reader Reader to read to create the WireFeed.
* @return the WireFeed read from the Reader.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(Reader reader) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
if (_xmlHealerOn) {
reader = new XmlFixerReader(reader);
}
Document document = saxBuilder.build(reader);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: org.apache.marmotta/sesame-tools-rio-rss
/**
* Builds an WireFeed (RSS or Atom) from an Reader.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom2.Document)'.
* <p>
* @param reader Reader to read to create the WireFeed.
* @return the WireFeed read from the Reader.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(Reader reader) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
if (_xmlHealerOn) {
reader = new XmlFixerReader(reader);
}
Document document = saxBuilder.build(reader);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
代码示例来源:origin: apache/marmotta
/**
* Builds an WireFeed (RSS or Atom) from an Reader.
* <p>
* NOTE: This method delages to the 'AsbtractFeed WireFeedInput#build(org.jdom2.Document)'.
* <p>
* @param reader Reader to read to create the WireFeed.
* @return the WireFeed read from the Reader.
* @throws IllegalArgumentException thrown if feed type could not be understood by any of the underlying parsers.
* @throws FeedException if the feed could not be parsed
*
*/
public WireFeed build(Reader reader) throws IllegalArgumentException,FeedException {
SAXBuilder saxBuilder = createSAXBuilder();
try {
if (_xmlHealerOn) {
reader = new XmlFixerReader(reader);
}
Document document = saxBuilder.build(reader);
return build(document);
}
catch (JDOMParseException ex) {
throw new ParsingFeedException("Invalid XML: " + ex.getMessage(), ex);
}
catch (IllegalArgumentException ex) {
throw ex;
}
catch (Exception ex) {
throw new ParsingFeedException("Invalid XML",ex);
}
}
内容来源于网络,如有侵权,请联系作者删除!