Package org.apache.uima.alchemy.digester.keyword

Examples of org.apache.uima.alchemy.digester.keyword.XMLTextKeywordExctractionDigester.parseAlchemyXML()


  public void testParseAlchemyXML() {
    try {
      String xmlString = "<results><status>OK</status><language>english</language><keywords><keyword>pluto</keyword><keyword>pippo</keyword></keywords></results>";
      XMLTextKeywordExctractionDigester digester = new XMLTextKeywordExctractionDigester();
      KeywordResults results = (KeywordResults) digester.parseAlchemyXML(new ByteArrayInputStream(
              xmlString.getBytes()));
      assertTrue(results != null);
      assertTrue(results.getLanguage() != null);
      assertTrue(results.getStatus() != null);
      assertTrue(results.getKeywords().size() == 2);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.