You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by to...@apache.org on 2010/02/17 13:06:20 UTC

svn commit: r910938 [1/18] - in /incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src: main/java/org/ main/java/org/apache/ main/java/org/apache/uima/ main/java/org/apache/uima/alchemy/ main/java/org/apache/uima/alchemy/annotator/ main/java/org/apache/...

Author: tommaso
Date: Wed Feb 17 12:06:17 2010
New Revision: 910938

URL: http://svn.apache.org/viewvc?rev=910938&view=rev
Log:
[UIMA-1733] - java code imported

Added:
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/LanguageDetectionResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Microformat.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/MicroformatsResults.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Quotations.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Results.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/annotated/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/annotated/AnnotatedEntityDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/annotated/XMLAnnotatedEntityExtractionDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/ranked/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/ranked/JsonTextRankedEntityExtractionDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/ranked/RankedEntityDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/entity/ranked/XMLRankedEntityExtractionDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/exception/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/exception/ResultDigestingException.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/exception/UnsupportedResultFormatException.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/json/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/json/JsonDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/json/JsonXMLReader.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/json/package-info.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/keyword/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/keyword/KeywordDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/keyword/XMLTextKeywordExctractionDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/language/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/language/LanguageDetectionDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/language/XMLLanguageDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/microformats/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/microformats/MicroformatsDigesterProvider.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/microformats/XMLMicroformatsDigester.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/categorization/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/categorization/Category.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/categorization/Category_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/AlchemyAnnotation.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/AlchemyAnnotation_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Anniversary.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Anniversary_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/City.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/City_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Company.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Company_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Continent.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Continent_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Country.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Country_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Drug.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Drug_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/EntertainmentAward.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/EntertainmentAward_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Facility.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Facility_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/FieldTerminology.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/FieldTerminology_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/FinancialMarketIndex.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/FinancialMarketIndex_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/GeographicFeature.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/GeographicFeature_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/HealthCondition.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/HealthCondition_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Holiday.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Holiday_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Movie.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Movie_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/MusicGroup.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/MusicGroup_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/NaturalDisaster.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/NaturalDisaster_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/OperatingSystem.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/OperatingSystem_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Organization.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Organization_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Person.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Person_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/PrintMedia.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/PrintMedia_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Product.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Product_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/RadioProgram.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/RadioProgram_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Region.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Region_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Sport.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Sport_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/SportingEvent.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/SportingEvent_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/StateOrCounty.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/StateOrCounty_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Technology.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/Technology_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/TelevisionShow.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/TelevisionShow_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/TelevisionStation.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/entity/TelevisionStation_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/keywords/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/keywords/KeywordFS.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/keywords/KeywordFS_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/language/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/language/LanguageFS.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/language/LanguageFS_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/microformats/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/microformats/MicroformatFS.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/ts/microformats/MicroformatFS_Type.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/utils/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/utils/Alchemy2TypeSystemMapper.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/utils/exception/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/utils/exception/MappingException.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/TextAnnotatedEntityExtractionAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/TextRankedEntityExtractionAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotatorTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/digester/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/digester/CategorizationJsonDigesterTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/digester/KeywordXMLDigesterTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/digester/RankedEntityJsonDigesterTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/digester/RankedEntityXMLDigesterTest.java   (with props)
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/utils/
    incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/test/java/org/apache/uima/alchemy/utils/TestUtils.java   (with props)

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,158 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import org.apache.commons.lang.Validate;
+import org.apache.uima.UimaContext;
+import org.apache.uima.alchemy.annotator.exception.AlchemyCallFailedException;
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.OutputDigester;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.exception.ResultDigestingException;
+import org.apache.uima.alchemy.digester.exception.UnsupportedResultFormatException;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.analysis_component.JCasAnnotator_ImplBase;
+import org.apache.uima.analysis_engine.AnalysisEngineProcessException;
+import org.apache.uima.jcas.JCas;
+import org.apache.uima.resource.ResourceInitializationException;
+import org.xml.sax.SAXException;
+
+import javax.xml.parsers.ParserConfigurationException;
+import java.io.*;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.net.URLConnection;
+
+public abstract class AbstractAlchemyAnnotator extends JCasAnnotator_ImplBase {
+
+  private static final String STATUS_OK = "OK";
+
+  private URL alchemyService;
+
+  protected String serviceParams;
+
+  private final String[] charsToReplace = { "<", ">", "\"", "'", "&" };
+
+  private OutputDigester digester;
+
+  private DigesterProvider digesterProvider;
+
+  @Override
+  public void initialize(UimaContext aContext) throws ResourceInitializationException {
+
+    digesterProvider = createDigester();
+
+    try {
+      this.digester = digesterProvider.getDigester(String.valueOf(aContext
+              .getConfigParameterValue("outputMode")));
+    } catch (UnsupportedResultFormatException e1) {
+      throw new ResourceInitializationException(e1);
+    }
+
+    try {
+      this.alchemyService = createServiceURI();
+    } catch (Exception e) {
+      throw new ResourceInitializationException(e);
+    }
+
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&apikey=");
+    serviceParamsBuf.append(aContext.getConfigParameterValue("apikey"));
+
+    for (String param : this.getServiceParameters()) {
+      serviceParamsBuf.append("&").append(param).append("=");
+      serviceParamsBuf.append(aContext.getConfigParameterValue(param));
+    }
+
+    this.serviceParams = serviceParamsBuf.toString();
+  }
+
+  protected String cleanText(JCas aJCas) {
+    String modifiedText = aJCas.getDocumentText();
+    for (int i = 0; i < this.charsToReplace.length; i++) {
+      modifiedText = modifiedText.replaceAll(this.charsToReplace[i], "");
+    }
+    modifiedText = modifiedText.replaceAll("\n", " ");
+    modifiedText = modifiedText.replaceAll("\r", " ");
+    return modifiedText;
+  }
+
+  public void process(JCas aJCas) throws AnalysisEngineProcessException {
+    // initialize service parameters
+    initializeRuntimeParameters(aJCas);
+    try {
+      // open connection and send data
+      URLConnection connection = this.alchemyService.openConnection();
+      connection.setDoOutput(true);
+      BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(connection
+              .getOutputStream(), "UTF-8"));
+      writer.write(this.serviceParams);
+
+      writer.flush();
+      writer.close();
+
+      InputStream bufByteIn = parseOutput(connection);
+
+      // map alchemy api results to UIMA type system
+      try {
+        Results results = this.digester.parseAlchemyXML(bufByteIn);
+        Validate.notNull(results);
+        Validate.notNull(results.getStatus());
+        if (results.getStatus().equalsIgnoreCase(STATUS_OK)) {
+          mapResultsToTypeSystem(results, aJCas); // annotations from results
+        } else {
+          throw new AlchemyCallFailedException(results.getStatus());
+        }
+
+      } catch (Exception e) {
+        throw new ResultDigestingException(e);
+      } finally {
+        bufByteIn.close();
+      }
+    } catch (Exception e) {
+      throw new AnalysisEngineProcessException(e);
+    }
+
+  }
+
+  private InputStream parseOutput(URLConnection connection) throws IOException {
+    return new BufferedInputStream(connection.getInputStream());
+  }
+
+  public void setDigesterProvider(DigesterProvider digesterProvider) {
+    this.digesterProvider = digesterProvider;
+  }
+
+  public DigesterProvider getDigesterProvider() {
+    return digesterProvider;
+  }
+
+  protected abstract DigesterProvider createDigester();
+
+  protected abstract URL createServiceURI() throws MalformedURLException;
+
+  protected abstract String[] getServiceParameters();
+
+  protected abstract void mapResultsToTypeSystem(Results results, JCas aJCas)
+          throws MappingException;
+
+  protected abstract void initializeRuntimeParameters(JCas aJCas)
+          throws AnalysisEngineProcessException;
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/AbstractAlchemyAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,65 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.io.UnsupportedEncodingException;
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+import java.net.URLEncoder;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.MicroformatsResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.microformats.MicroformatsDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.analysis_engine.AnalysisEngineProcessException;
+import org.apache.uima.jcas.JCas;
+
+public class HtmlMicroformatsAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/html/HTMLGetMicroformatData").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "url" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapMicroformats((MicroformatsResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new MicroformatsDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) throws AnalysisEngineProcessException {
+    try {
+      // fill html parameter
+      StringBuffer serviceParamsBuf = new StringBuffer();
+      serviceParamsBuf.append("&html=");
+      serviceParamsBuf.append(URLEncoder.encode(aJCas.getDocumentText(), "UTF-8"));
+      this.serviceParams += (serviceParamsBuf.toString());
+    } catch (UnsupportedEncodingException e) {
+      throw new AnalysisEngineProcessException(e);
+    }
+  }
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/HtmlMicroformatsAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,68 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.AnnotatedResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.entity.annotated.AnnotatedEntityDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.jcas.JCas;
+
+/**
+ * 
+ * This functionality has been disabled for free API keys
+ *
+ */
+@Deprecated
+public class TextAnnotatedNamedEntityExtractionAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/text/TextGetAnnotatedNamedEntityText")
+            .toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "baseUrl", "disambiguate", "quotations",
+        "showSourceText", "coreference" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapAnnotatedEntities((AnnotatedResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new AnnotatedEntityDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) {
+    // create parameters string
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&text=");
+    String modifiedText = cleanText(aJCas);
+    serviceParamsBuf.append(modifiedText);
+    this.serviceParams += (serviceParamsBuf.toString());
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextAnnotatedNamedEntityExtractionAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,60 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.categorization.CategorizationDigesterProvider;
+import org.apache.uima.alchemy.digester.domain.CategorizationResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.jcas.JCas;
+
+public class TextCategorizationAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/text/TextGetCategory").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "baseUrl", "url" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapCategorizationEntity((CategorizationResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new CategorizationDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) {
+    // create parameters string
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&text=");
+    String modifiedText = cleanText(aJCas);
+    serviceParamsBuf.append(modifiedText);
+    this.serviceParams += (serviceParamsBuf.toString());
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextCategorizationAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,60 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.KeywordResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.keyword.KeywordDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.jcas.JCas;
+
+public class TextKeywordExtractionAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/text/TextGetKeywords").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "baseUrl", "url", "maxRetrieve",
+        "showSourceText" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapKeywordEntity((KeywordResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new KeywordDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) {
+    // create parameters string
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&text=");
+    String modifiedText = cleanText(aJCas);
+    serviceParamsBuf.append(modifiedText);
+    this.serviceParams += (serviceParamsBuf.toString());
+  }
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextKeywordExtractionAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,60 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.LanguageDetectionResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.language.LanguageDetectionDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.jcas.JCas;
+
+public class TextLanguageDetectionAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/text/TextGetLanguage").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "url" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapLanguageDetection((LanguageDetectionResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new LanguageDetectionDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) {
+    // create parameters string
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&text=");
+    String modifiedText = cleanText(aJCas);
+    serviceParamsBuf.append(modifiedText);
+    this.serviceParams += (serviceParamsBuf.toString());
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextLanguageDetectionAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,60 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.EntitiesResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.entity.ranked.RankedEntityDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.jcas.JCas;
+
+public class TextRankedNamedEntityExtractionAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/text/TextGetRankedNamedEntities").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode", "baseUrl", "disambiguate", "linkedData",
+        "showSourceText" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapRankedEntities((EntitiesResults) results, aJCas); // create
+  }
+
+  protected DigesterProvider createDigester() {
+    return new RankedEntityDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) {
+    // create parameters string
+    StringBuffer serviceParamsBuf = new StringBuffer();
+    serviceParamsBuf.append("&text=");
+    String modifiedText = cleanText(aJCas);
+    serviceParamsBuf.append(modifiedText);
+    this.serviceParams += (serviceParamsBuf.toString());
+  }
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/TextRankedNamedEntityExtractionAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,65 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator;
+
+import java.io.UnsupportedEncodingException;
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URL;
+import java.net.URLEncoder;
+
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.domain.MicroformatsResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.apache.uima.alchemy.digester.microformats.MicroformatsDigesterProvider;
+import org.apache.uima.alchemy.utils.Alchemy2TypeSystemMapper;
+import org.apache.uima.alchemy.utils.exception.MappingException;
+import org.apache.uima.analysis_engine.AnalysisEngineProcessException;
+import org.apache.uima.jcas.JCas;
+
+public class URLMicroformatsAnnotator extends AbstractAlchemyAnnotator {
+
+  protected URL createServiceURI() throws MalformedURLException {
+    return URI.create("http://access.alchemyapi.com/calls/url/URLGetMicroformatData").toURL();
+  }
+
+  protected String[] getServiceParameters() {
+    return new String[] { "outputMode" };
+  }
+
+  protected void mapResultsToTypeSystem(Results results, JCas aJCas) throws MappingException {
+    Alchemy2TypeSystemMapper.mapMicroformats((MicroformatsResults) results, aJCas);
+  }
+
+  protected DigesterProvider createDigester() {
+    return new MicroformatsDigesterProvider();
+  }
+
+  protected void initializeRuntimeParameters(JCas aJCas) throws AnalysisEngineProcessException {
+    try {
+      // fill url parameter
+      StringBuffer serviceParamsBuf = new StringBuffer();
+      serviceParamsBuf.append("&url=");
+      serviceParamsBuf.append(URLEncoder.encode(aJCas.getDocumentText(), "UTF-8"));
+      this.serviceParams += (serviceParamsBuf.toString());
+    } catch (UnsupportedEncodingException e) {
+      throw new AnalysisEngineProcessException(e);
+    }
+  }
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/URLMicroformatsAnnotator.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,32 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.annotator.exception;
+
+public class AlchemyCallFailedException extends Exception {
+
+  /**
+	 * 
+	 */
+  private static final long serialVersionUID = 1L;
+
+  public AlchemyCallFailedException(String status) {
+    super(status);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/annotator/exception/AlchemyCallFailedException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,27 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester;
+
+import org.apache.uima.alchemy.digester.exception.UnsupportedResultFormatException;
+
+public interface DigesterProvider {
+
+  public OutputDigester getDigester(String type) throws UnsupportedResultFormatException;
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/DigesterProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,33 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URISyntaxException;
+
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.xml.sax.SAXException;
+
+public interface OutputDigester {
+
+  public Results parseAlchemyXML(InputStream xmlReader) throws IOException, SAXException,
+          URISyntaxException;
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/OutputDigester.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,40 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.categorization;
+
+import org.apache.commons.lang.Validate;
+import org.apache.uima.alchemy.digester.DigesterProvider;
+import org.apache.uima.alchemy.digester.OutputDigester;
+import org.apache.uima.alchemy.digester.exception.UnsupportedResultFormatException;
+
+public class CategorizationDigesterProvider implements DigesterProvider {
+
+  public OutputDigester getDigester(String type) throws UnsupportedResultFormatException {
+    Validate.notEmpty(type);
+    OutputDigester digester = null;
+    if (type.equals("json")) {
+      digester = new JsonTextCategorizationDigester();
+    } else if (type.equals("xml")) {
+      digester = new XMLTextCategorizationDigester();
+    } else
+      throw new UnsupportedResultFormatException(type);
+    return digester;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/CategorizationDigesterProvider.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,49 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.categorization;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URISyntaxException;
+
+import org.apache.commons.digester.Digester;
+import org.apache.uima.alchemy.digester.OutputDigester;
+import org.apache.uima.alchemy.digester.domain.CategorizationResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.xml.sax.SAXException;
+
+import org.apache.uima.alchemy.digester.json.JsonDigester;
+
+public class JsonTextCategorizationDigester implements OutputDigester {
+
+  public Results parseAlchemyXML(InputStream stream) throws IOException, SAXException,
+          URISyntaxException {
+
+    Digester digester = new JsonDigester();
+    digester.setValidating(false);
+    digester.addObjectCreate("$", CategorizationResults.class);
+    digester.addBeanPropertySetter("$/status", "status");
+    digester.addBeanPropertySetter("$/url", "url");
+    digester.addBeanPropertySetter("$/language", "language");
+    digester.addBeanPropertySetter("$/category", "category");
+    digester.addBeanPropertySetter("$/score", "score");
+    return (Results) digester.parse(stream);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/JsonTextCategorizationDigester.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,46 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.categorization;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URISyntaxException;
+
+import org.apache.commons.digester.Digester;
+import org.apache.uima.alchemy.digester.OutputDigester;
+import org.apache.uima.alchemy.digester.domain.CategorizationResults;
+import org.apache.uima.alchemy.digester.domain.Results;
+import org.xml.sax.SAXException;
+
+public class XMLTextCategorizationDigester implements OutputDigester {
+
+  public Results parseAlchemyXML(InputStream stream) throws IOException, SAXException,
+          URISyntaxException {
+    Digester digester = new Digester();
+    digester.setValidating(false);
+
+    digester.addObjectCreate("results", CategorizationResults.class);
+    digester.addBeanPropertySetter("results/status", "status");
+    digester.addBeanPropertySetter("results/url", "url");
+    digester.addBeanPropertySetter("results/category", "category");
+    digester.addBeanPropertySetter("results/score", "score");
+    return (Results) digester.parse(stream);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/categorization/XMLTextCategorizationDigester.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,43 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class AnnotatedResults extends Results {
+
+  private String text;
+
+  private String annotatedText;
+
+  public String getText() {
+    return text;
+  }
+
+  public void setText(String text) {
+    this.text = text;
+  }
+
+  public String getAnnotatedText() {
+    return annotatedText;
+  }
+
+  public void setAnnotatedText(String annotatedText) {
+    this.annotatedText = annotatedText;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/AnnotatedResults.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,53 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class CategorizationResults extends Results {
+
+  private String category;
+
+  private String score;
+
+  private String url;
+
+  public String getCategory() {
+    return category;
+  }
+
+  public void setCategory(String category) {
+    this.category = category;
+  }
+
+  public String getScore() {
+    return score;
+  }
+
+  public void setScore(String score) {
+    this.score = score;
+  }
+
+  public void setUrl(String url) {
+    this.url = url;
+  }
+
+  public String getUrl() {
+    return url;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/CategorizationResults.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,153 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class Disambiguated {
+
+  private String name;
+
+  private String subType;
+
+  private String website;
+
+  private String geo;
+
+  private String dbpedia;
+
+  private String yago;
+
+  private String opencyc;
+
+  private String umbel;
+
+  private String freebase;
+
+  private String ciaFactbook;
+
+  private String census;
+
+  private String geonames;
+
+  private String musicBrainz;
+
+  public String getName() {
+    return name;
+  }
+
+  public void setName(String name) {
+    this.name = name;
+  }
+
+  public String getSubType() {
+    return subType;
+  }
+
+  public void setSubType(String subType) {
+    this.subType = subType;
+  }
+
+  public String getWebsite() {
+    return website;
+  }
+
+  public void setWebsite(String website) {
+    this.website = website;
+  }
+
+  public String getGeo() {
+    return geo;
+  }
+
+  public void setGeo(String geo) {
+    this.geo = geo;
+  }
+
+  public String getDbpedia() {
+    return dbpedia;
+  }
+
+  public void setDbpedia(String dbpedia) {
+    this.dbpedia = dbpedia;
+  }
+
+  public String getYago() {
+    return yago;
+  }
+
+  public void setYago(String yago) {
+    this.yago = yago;
+  }
+
+  public String getOpencyc() {
+    return opencyc;
+  }
+
+  public void setOpencyc(String opencyc) {
+    this.opencyc = opencyc;
+  }
+
+  public String getUmbel() {
+    return umbel;
+  }
+
+  public void setUmbel(String umbel) {
+    this.umbel = umbel;
+  }
+
+  public String getFreebase() {
+    return freebase;
+  }
+
+  public void setFreebase(String freebase) {
+    this.freebase = freebase;
+  }
+
+  public String getCiaFactbook() {
+    return ciaFactbook;
+  }
+
+  public void setCiaFactbook(String ciaFactbook) {
+    this.ciaFactbook = ciaFactbook;
+  }
+
+  public String getCensus() {
+    return census;
+  }
+
+  public void setCensus(String census) {
+    this.census = census;
+  }
+
+  public String getGeonames() {
+    return geonames;
+  }
+
+  public void setGeonames(String geonames) {
+    this.geonames = geonames;
+  }
+
+  public String getMusicBrainz() {
+    return musicBrainz;
+  }
+
+  public void setMusicBrainz(String musicBrainz) {
+    this.musicBrainz = musicBrainz;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Disambiguated.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,44 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class Entities {
+
+  private List<Entity> entities;
+
+  public Entities() {
+    this.entities = new ArrayList<Entity>();
+  }
+
+  public void setEntities(List<Entity> entities) {
+    this.entities = entities;
+  }
+
+  public List<Entity> getEntities() {
+    return entities;
+  }
+
+  public void addEntity(Entity entity) {
+    this.entities.add(entity);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entities.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,37 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class EntitiesResults extends Results {
+
+  private Entities entities = new Entities();
+
+  public Entities getEntities() {
+    return entities;
+  }
+
+  public void setEntities(Entities entities) {
+    this.entities = entities;
+  }
+
+  public void addEntity(Entity entity) {
+    this.getEntities().addEntity(entity);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/EntitiesResults.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,83 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class Entity {
+
+  private String type;
+
+  private String relevance;
+
+  private String count;
+
+  private String text;
+
+  private Disambiguated disambiguated;
+
+  private Quotations quotations;
+
+  public String getType() {
+    return type;
+  }
+
+  public void setType(String type) {
+    this.type = type;
+  }
+
+  public String getRelevance() {
+    return relevance;
+  }
+
+  public void setRelevance(String relevance) {
+    this.relevance = relevance;
+  }
+
+  public String getCount() {
+    return count;
+  }
+
+  public void setCount(String count) {
+    this.count = count;
+  }
+
+  public String getText() {
+    return text;
+  }
+
+  public void setText(String text) {
+    this.text = text;
+  }
+
+  public void setDisambiguated(Disambiguated disambiguated) {
+    this.disambiguated = disambiguated;
+  }
+
+  public Disambiguated getDisambiguated() {
+    return disambiguated;
+  }
+
+  public void setQuotations(Quotations quotations) {
+    this.quotations = quotations;
+  }
+
+  public Quotations getQuotations() {
+    return quotations;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Entity.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,33 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+public class Keyword {
+
+  private String text;
+
+  public void setText(String text) {
+    this.text = text;
+  }
+
+  public String getText() {
+    return text;
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/Keyword.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java
URL: http://svn.apache.org/viewvc/incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java?rev=910938&view=auto
==============================================================================
--- incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java (added)
+++ incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java Wed Feb 17 12:06:17 2010
@@ -0,0 +1,44 @@
+/**
+ * 	Licensed to the Apache Software Foundation (ASF) under one
+ * 	or more contributor license agreements.  See the NOTICE file
+ * 	distributed with this work for additional information
+ * 	regarding copyright ownership.  The ASF licenses this file
+ * 	to you under the Apache License, Version 2.0 (the
+ * 	"License"); you may not use this file except in compliance
+ * 	with the License.  You may obtain a copy of the License at
+ *
+ * 	http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * 	Unless required by applicable law or agreed to in writing,
+ * 	software distributed under the License is distributed on an
+ * 	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * 	KIND, either express or implied.  See the License for the
+ * 	specific language governing permissions and limitations
+ * 	under the License.
+ */
+package org.apache.uima.alchemy.digester.domain;
+
+import java.util.ArrayList;
+import java.util.List;
+
+public class KeywordResults extends Results {
+
+  private List<Keyword> keywords;
+
+  public KeywordResults() {
+    keywords = new ArrayList<Keyword>();
+  }
+
+  public void setKeywords(List<Keyword> keywords) {
+    this.keywords = keywords;
+  }
+
+  public List<Keyword> getKeywords() {
+    return keywords;
+  }
+
+  public void addKeyword(Keyword k) {
+    keywords.add(k);
+  }
+
+}

Propchange: incubator/uima/sandbox/trunk/AlchemyAPIAnnotator/src/main/java/org/apache/uima/alchemy/digester/domain/KeywordResults.java
------------------------------------------------------------------------------
    svn:eol-style = native