You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@any23.apache.org by le...@apache.org on 2020/10/12 01:46:28 UTC
[any23] branch master updated: ANY23-455 Format entire Any23
codebase with formatter-maven-plugin
This is an automated email from the ASF dual-hosted git repository.
lewismc pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/any23.git
The following commit(s) were added to refs/heads/master by this push:
new 1897b06 ANY23-455 Format entire Any23 codebase with formatter-maven-plugin
new 7e0eb59 Merge pull request #162 from lewismc/ANY23-455
1897b06 is described below
commit 1897b0647652d548cc3732e8c1eed2a62c78f082
Author: Lewis John McGibbney <le...@gmail.com>
AuthorDate: Tue Oct 6 22:34:04 2020 -0700
ANY23-455 Format entire Any23 codebase with formatter-maven-plugin
---
api/src/main/java/org/apache/any23/cli/Tool.java | 4 +-
.../apache/any23/configuration/Configuration.java | 54 +-
.../any23/configuration/DefaultConfiguration.java | 59 +-
.../DefaultModifiableConfiguration.java | 9 +-
.../configuration/ModifiableConfiguration.java | 10 +-
.../org/apache/any23/configuration/Setting.java | 212 ++-
.../org/apache/any23/configuration/Settings.java | 77 +-
.../apache/any23/encoding/EncodingDetector.java | 27 +-
.../apache/any23/extractor/ExtractionContext.java | 30 +-
.../any23/extractor/ExtractionException.java | 6 +-
.../any23/extractor/ExtractionParameters.java | 167 +-
.../apache/any23/extractor/ExtractionResult.java | 47 +-
.../java/org/apache/any23/extractor/Extractor.java | 46 +-
.../any23/extractor/ExtractorDescription.java | 5 +-
.../apache/any23/extractor/ExtractorFactory.java | 20 +-
.../org/apache/any23/extractor/ExtractorGroup.java | 13 +-
.../apache/any23/extractor/ExtractorRegistry.java | 30 +-
.../org/apache/any23/extractor/IssueReport.java | 23 +-
.../main/java/org/apache/any23/mime/MIMEType.java | 26 +-
.../org/apache/any23/mime/MIMETypeDetector.java | 13 +-
.../org/apache/any23/mime/purifier/Purifier.java | 10 +-
.../apache/any23/mime/purifier/package-info.java | 6 +-
.../apache/any23/plugin/Any23PluginManager.java | 217 ++-
.../org/apache/any23/plugin/ExtractorPlugin.java | 15 +-
.../main/java/org/apache/any23/rdf/Prefixes.java | 29 +-
.../org/apache/any23/source/DocumentSource.java | 22 +-
api/src/main/java/org/apache/any23/vocab/CSV.java | 17 +-
.../main/java/org/apache/any23/vocab/DCTerms.java | 17 +-
api/src/main/java/org/apache/any23/vocab/DOAC.java | 68 +-
api/src/main/java/org/apache/any23/vocab/DOAP.java | 112 +-
api/src/main/java/org/apache/any23/vocab/FOAF.java | 134 +-
.../main/java/org/apache/any23/vocab/GeoNames.java | 6 +-
.../main/java/org/apache/any23/vocab/HCard.java | 79 +-
.../main/java/org/apache/any23/vocab/HEntry.java | 27 +-
.../main/java/org/apache/any23/vocab/HEvent.java | 18 +-
.../main/java/org/apache/any23/vocab/HItem.java | 9 +-
.../main/java/org/apache/any23/vocab/HListing.java | 58 +-
.../main/java/org/apache/any23/vocab/HProduct.java | 16 +-
.../main/java/org/apache/any23/vocab/HRecipe.java | 42 +-
.../main/java/org/apache/any23/vocab/HResume.java | 14 +-
api/src/main/java/org/apache/any23/vocab/ICAL.java | 224 +--
.../org/apache/any23/vocab/LKIFCoreAction.java | 92 +-
.../org/apache/any23/vocab/LKIFCoreExpression.java | 175 +-
.../apache/any23/vocab/LKIFCoreLegalAction.java | 87 +-
.../org/apache/any23/vocab/LKIFCoreLegalRole.java | 48 +-
.../org/apache/any23/vocab/LKIFCoreMereology.java | 81 +-
.../java/org/apache/any23/vocab/LKIFCoreNorm.java | 180 +-
.../org/apache/any23/vocab/LKIFCoreProcess.java | 81 +-
.../apache/any23/vocab/LKIFCoreRelativePlaces.java | 81 +-
.../java/org/apache/any23/vocab/LKIFCoreRole.java | 67 +-
.../java/org/apache/any23/vocab/LKIFCoreRules.java | 60 +-
.../java/org/apache/any23/vocab/LKIFCoreTime.java | 71 +-
.../any23/vocab/LKIFCoreTimeModification.java | 160 +-
.../java/org/apache/any23/vocab/LKIFCoreTop.java | 53 +-
api/src/main/java/org/apache/any23/vocab/OGP.java | 127 +-
.../java/org/apache/any23/vocab/OGPArticle.java | 15 +-
.../main/java/org/apache/any23/vocab/OGPBook.java | 17 +-
.../main/java/org/apache/any23/vocab/OGPMusic.java | 38 +-
.../java/org/apache/any23/vocab/OGPProfile.java | 11 +-
.../main/java/org/apache/any23/vocab/OGPVideo.java | 29 +-
.../java/org/apache/any23/vocab/Programme.java | 705 ++++----
.../main/java/org/apache/any23/vocab/Review.java | 6 +-
.../org/apache/any23/vocab/ReviewAggregate.java | 21 +-
.../main/java/org/apache/any23/vocab/SINDICE.java | 17 +-
.../java/org/apache/any23/vocab/SchemaOrg.java | 4 +-
.../main/java/org/apache/any23/vocab/VCard.java | 11 +-
.../java/org/apache/any23/vocab/Vocabulary.java | 94 +-
api/src/main/java/org/apache/any23/vocab/WO.java | 666 ++++----
api/src/main/java/org/apache/any23/vocab/XFN.java | 44 +-
.../main/java/org/apache/any23/vocab/XHTML.java | 12 +-
api/src/main/java/org/apache/any23/vocab/YAML.java | 122 +-
.../any23/writer/DecoratingWriterFactory.java | 15 +-
.../java/org/apache/any23/writer/FormatWriter.java | 13 +-
.../java/org/apache/any23/writer/TripleFormat.java | 43 +-
.../org/apache/any23/writer/TripleHandler.java | 86 +-
.../any23/writer/TripleHandlerException.java | 1 -
.../java/org/apache/any23/writer/TripleWriter.java | 44 +-
.../apache/any23/writer/TripleWriterFactory.java | 41 +-
.../org/apache/any23/writer/WriterFactory.java | 17 +-
.../apache/any23/writer/WriterFactoryRegistry.java | 95 +-
.../apache/any23/configuration/SettingsTest.java | 72 +-
.../org/apache/any23/writer/TripleFormatTest.java | 8 +-
.../main/java/org/apache/any23/cli/BaseTool.java | 17 +-
.../apache/any23/cli/ExtractorDocumentation.java | 64 +-
.../java/org/apache/any23/cli/MicrodataParser.java | 29 +-
.../java/org/apache/any23/cli/MimeDetector.java | 32 +-
.../java/org/apache/any23/cli/PluginVerifier.java | 11 +-
cli/src/main/java/org/apache/any23/cli/Rover.java | 99 +-
.../main/java/org/apache/any23/cli/ToolRunner.java | 100 +-
.../java/org/apache/any23/cli/VocabPrinter.java | 12 +-
.../java/org/apache/any23/cli/package-info.java | 4 +-
.../org/apache/any23/cli/ExtractorsFlowTest.java | 26 +-
.../test/java/org/apache/any23/cli/RoverTest.java | 77 +-
.../java/org/apache/any23/cli/SimpleRoverTest.java | 53 +-
.../java/org/apache/any23/cli/ToolRunnerTest.java | 23 +-
.../java/org/apache/any23/cli/ToolTestBase.java | 38 +-
.../java/org/apache/any23/cli/YAMLRoverTest.java | 20 +-
.../apache/any23/cli/flows/PeopleExtractor.java | 15 +-
core/src/main/java/org/apache/any23/Any23.java | 368 ++--
.../java/org/apache/any23/ExtractionReport.java | 55 +-
.../apache/any23/extractor/ExampleInputOutput.java | 23 +-
.../any23/extractor/ExtractionResultImpl.java | 108 +-
.../any23/extractor/ExtractorRegistryImpl.java | 62 +-
.../any23/extractor/SimpleExtractorFactory.java | 15 +-
.../any23/extractor/SingleDocumentExtraction.java | 633 ++++---
.../extractor/SingleDocumentExtractionReport.java | 15 +-
.../any23/extractor/TagSoupExtractionResult.java | 104 +-
.../extractor/calendar/BaseCalendarExtractor.java | 77 +-
.../extractor/calendar/JCalExtractorFactory.java | 1 -
.../apache/any23/extractor/csv/CSVExtractor.java | 95 +-
.../any23/extractor/csv/CSVExtractorFactory.java | 17 +-
.../apache/any23/extractor/csv/package-info.java | 4 +-
.../apache/any23/extractor/html/AdrExtractor.java | 31 +-
.../any23/extractor/html/AdrExtractorFactory.java | 17 +-
.../any23/extractor/html/DocumentReport.java | 5 +-
.../org/apache/any23/extractor/html/DomUtils.java | 329 ++--
.../extractor/html/EmbeddedJSONLDExtractor.java | 286 ++--
.../html/EmbeddedJSONLDExtractorFactory.java | 17 +-
.../html/EntityBasedMicroformatExtractor.java | 25 +-
.../apache/any23/extractor/html/GeoExtractor.java | 21 +-
.../any23/extractor/html/GeoExtractorFactory.java | 17 +-
.../any23/extractor/html/HCalendarExtractor.java | 70 +-
.../extractor/html/HCalendarExtractorFactory.java | 17 +-
.../any23/extractor/html/HCardExtractor.java | 155 +-
.../extractor/html/HCardExtractorFactory.java | 17 +-
.../org/apache/any23/extractor/html/HCardName.java | 116 +-
.../any23/extractor/html/HListingExtractor.java | 103 +-
.../extractor/html/HListingExtractorFactory.java | 17 +-
.../any23/extractor/html/HRecipeExtractor.java | 62 +-
.../extractor/html/HRecipeExtractorFactory.java | 17 +-
.../any23/extractor/html/HResumeExtractor.java | 55 +-
.../extractor/html/HResumeExtractorFactory.java | 17 +-
.../extractor/html/HReviewAggregateExtractor.java | 49 +-
.../html/HReviewAggregateExtractorFactory.java | 18 +-
.../any23/extractor/html/HReviewExtractor.java | 52 +-
.../extractor/html/HReviewExtractorFactory.java | 17 +-
.../apache/any23/extractor/html/HTMLDocument.java | 147 +-
.../any23/extractor/html/HTMLMetaExtractor.java | 74 +-
.../extractor/html/HTMLMetaExtractorFactory.java | 17 +-
.../any23/extractor/html/HeadLinkExtractor.java | 45 +-
.../extractor/html/HeadLinkExtractorFactory.java | 17 +-
.../apache/any23/extractor/html/ICBMExtractor.java | 14 +-
.../any23/extractor/html/ICBMExtractorFactory.java | 17 +-
.../apache/any23/extractor/html/JsoupUtils.java | 19 +-
.../any23/extractor/html/LicenseExtractor.java | 23 +-
.../extractor/html/LicenseExtractorFactory.java | 17 +-
.../any23/extractor/html/MicroformatExtractor.java | 174 +-
.../extractor/html/SpanCloserInputStream.java | 36 +-
.../any23/extractor/html/SpeciesExtractor.java | 62 +-
.../extractor/html/SpeciesExtractorFactory.java | 17 +-
.../apache/any23/extractor/html/TagSoupParser.java | 53 +-
.../html/TagSoupParsingConfiguration.java | 11 +-
.../any23/extractor/html/TitleExtractor.java | 20 +-
.../extractor/html/TitleExtractorFactory.java | 17 +-
.../any23/extractor/html/TurtleHTMLExtractor.java | 59 +-
.../extractor/html/TurtleHTMLExtractorFactory.java | 17 +-
.../apache/any23/extractor/html/XFNExtractor.java | 27 +-
.../any23/extractor/html/XFNExtractorFactory.java | 17 +-
.../any23/extractor/html/annotations/Includes.java | 4 +-
.../extractor/html/annotations/package-info.java | 6 +-
.../html/microformats2/HAdrExtractor.java | 61 +-
.../html/microformats2/HAdrExtractorFactory.java | 17 +-
.../html/microformats2/HCardExtractor.java | 265 +--
.../html/microformats2/HCardExtractorFactory.java | 17 +-
.../html/microformats2/HEntryExtractor.java | 147 +-
.../html/microformats2/HEntryExtractorFactory.java | 15 +-
.../html/microformats2/HEventExtractor.java | 146 +-
.../html/microformats2/HEventExtractorFactory.java | 17 +-
.../html/microformats2/HGeoExtractor.java | 45 +-
.../html/microformats2/HGeoExtractorFactory.java | 17 +-
.../html/microformats2/HItemExtractor.java | 38 +-
.../html/microformats2/HItemExtractorFactory.java | 11 +-
.../html/microformats2/HProductExtractor.java | 87 +-
.../microformats2/HProductExtractorFactory.java | 11 +-
.../html/microformats2/HRecipeExtractor.java | 113 +-
.../microformats2/HRecipeExtractorFactory.java | 17 +-
.../html/microformats2/HResumeExtractor.java | 82 +-
.../microformats2/HResumeExtractorFactory.java | 17 +-
.../html/microformats2/annotations/Includes.java | 4 +-
.../microformats2/annotations/package-info.java | 6 +-
.../extractor/html/microformats2/package-info.java | 4 +-
.../apache/any23/extractor/html/package-info.java | 4 +-
.../org/apache/any23/extractor/microdata/Item.java | 11 +-
.../apache/any23/extractor/microdata/ItemProp.java | 32 +-
.../any23/extractor/microdata/ItemPropValue.java | 108 +-
.../any23/extractor/microdata/ItemScope.java | 75 +-
.../extractor/microdata/MicrodataExtractor.java | 113 +-
.../microdata/MicrodataExtractorFactory.java | 17 +-
.../any23/extractor/microdata/MicrodataParser.java | 327 ++--
.../microdata/MicrodataParserException.java | 27 +-
.../extractor/microdata/MicrodataParserReport.java | 6 +-
.../any23/extractor/microdata/package-info.java | 3 +-
.../any23/extractor/rdf/BaseRDFExtractor.java | 25 +-
.../extractor/rdf/FunctionalSyntaxExtractor.java | 9 +-
.../rdf/FunctionalSyntaxExtractorFactory.java | 19 +-
.../any23/extractor/rdf/JSONLDExtractor.java | 53 +-
.../extractor/rdf/JSONLDExtractorFactory.java | 17 +-
.../apache/any23/extractor/rdf/JSONLDJavaSink.java | 7 +-
.../extractor/rdf/JsonCleaningInputStream.java | 247 ++-
.../extractor/rdf/ManchesterSyntaxExtractor.java | 9 +-
.../rdf/ManchesterSyntaxExtractorFactory.java | 19 +-
.../any23/extractor/rdf/NQuadsExtractor.java | 9 +-
.../extractor/rdf/NQuadsExtractorFactory.java | 24 +-
.../any23/extractor/rdf/NTriplesExtractor.java | 9 +-
.../extractor/rdf/NTriplesExtractorFactory.java | 21 +-
.../any23/extractor/rdf/RDFHandlerAdapter.java | 9 +-
.../any23/extractor/rdf/RDFParserFactory.java | 266 +--
.../any23/extractor/rdf/RDFXMLExtractor.java | 19 +-
.../extractor/rdf/RDFXMLExtractorFactory.java | 27 +-
.../apache/any23/extractor/rdf/TriXExtractor.java | 19 +-
.../any23/extractor/rdf/TriXExtractorFactory.java | 17 +-
.../any23/extractor/rdf/TurtleExtractor.java | 14 +-
.../extractor/rdf/TurtleExtractorFactory.java | 24 +-
.../apache/any23/extractor/rdf/package-info.java | 4 +-
.../any23/extractor/rdfa/BaseRDFaExtractor.java | 14 +-
.../apache/any23/extractor/rdfa/JsoupScanner.java | 37 +-
.../any23/extractor/rdfa/RDFa11Extractor.java | 32 +-
.../extractor/rdfa/RDFa11ExtractorFactory.java | 10 +-
.../apache/any23/extractor/rdfa/RDFa11Parser.java | 537 +++---
.../extractor/rdfa/RDFa11ParserException.java | 3 +-
.../apache/any23/extractor/rdfa/RDFaExtractor.java | 32 +-
.../any23/extractor/rdfa/RDFaExtractorFactory.java | 17 +-
.../any23/extractor/rdfa/XSLTStylesheet.java | 49 +-
.../extractor/rdfa/XSLTStylesheetException.java | 8 +-
.../apache/any23/extractor/rdfa/package-info.java | 3 +-
.../apache/any23/extractor/xpath/QuadTemplate.java | 60 +-
.../any23/extractor/xpath/TemplateGraph.java | 7 +-
.../any23/extractor/xpath/TemplateObject.java | 50 +-
.../any23/extractor/xpath/TemplatePredicate.java | 11 +-
.../any23/extractor/xpath/TemplateSubject.java | 37 +-
.../xpath/TemplateXPathExtractionRule.java | 21 +-
.../xpath/TemplateXPathExtractionRuleImpl.java | 33 +-
.../org/apache/any23/extractor/xpath/Term.java | 28 +-
.../org/apache/any23/extractor/xpath/Variable.java | 1 +
.../any23/extractor/xpath/XPathExtractionRule.java | 11 +-
.../any23/extractor/xpath/XPathExtractor.java | 22 +-
.../extractor/xpath/XPathExtractorFactory.java | 17 +-
.../apache/any23/extractor/xpath/package-info.java | 5 +-
.../any23/extractor/yaml/ElementsProcessor.java | 74 +-
.../apache/any23/extractor/yaml/YAMLExtractor.java | 15 +-
.../any23/extractor/yaml/YAMLExtractorFactory.java | 29 +-
.../extractor/yaml/YAMLProcessorException.java | 10 +-
.../apache/any23/extractor/yaml/package-info.java | 3 +-
.../any23/filter/ExtractionContextBlocker.java | 44 +-
.../apache/any23/filter/IgnoreAccidentalRDFa.java | 23 +-
.../any23/filter/IgnoreTitlesOfEmptyDocuments.java | 17 +-
.../java/org/apache/any23/filter/package-info.java | 4 +-
.../org/apache/any23/http/AcceptHeaderBuilder.java | 23 +-
.../org/apache/any23/http/DefaultHTTPClient.java | 53 +-
.../any23/http/DefaultHTTPClientConfiguration.java | 51 +-
.../java/org/apache/any23/http/HTTPClient.java | 32 +-
.../java/org/apache/any23/http/package-info.java | 5 +-
.../main/java/org/apache/any23/package-info.java | 3 +-
.../apache/any23/rdf/Any23ValueFactoryWrapper.java | 49 +-
.../java/org/apache/any23/rdf/PopularPrefixes.java | 57 +-
.../main/java/org/apache/any23/rdf/RDFUtils.java | 381 +++--
.../java/org/apache/any23/rdf/package-info.java | 3 +-
.../any23/source/ByteArrayDocumentSource.java | 6 +-
.../apache/any23/source/FileDocumentSource.java | 4 +-
.../apache/any23/source/HTTPDocumentSource.java | 3 +-
.../org/apache/any23/source/LocalCopyFactory.java | 5 +-
.../org/apache/any23/source/MemCopyFactory.java | 8 +-
.../apache/any23/source/StringDocumentSource.java | 2 +-
.../java/org/apache/any23/source/package-info.java | 3 +-
.../java/org/apache/any23/util/DiscoveryUtils.java | 96 +-
.../main/java/org/apache/any23/util/FileUtils.java | 116 +-
.../main/java/org/apache/any23/util/LogUtils.java | 1 +
.../main/java/org/apache/any23/util/MathUtils.java | 3 +-
.../org/apache/any23/util/ReaderInputStream.java | 63 +-
.../java/org/apache/any23/util/StreamUtils.java | 57 +-
.../java/org/apache/any23/util/StringUtils.java | 80 +-
.../main/java/org/apache/any23/util/URLUtils.java | 13 +-
.../org/apache/any23/validator/DOMDocument.java | 27 +-
.../apache/any23/validator/DefaultDOMDocument.java | 17 +-
.../apache/any23/validator/DefaultRuleContext.java | 2 +-
.../any23/validator/DefaultValidationReport.java | 12 +-
.../validator/DefaultValidationReportBuilder.java | 38 +-
.../apache/any23/validator/DefaultValidator.java | 27 +-
.../any23/validator/EmptyValidationReport.java | 5 +-
.../main/java/org/apache/any23/validator/Fix.java | 10 +-
.../main/java/org/apache/any23/validator/Rule.java | 11 +-
.../org/apache/any23/validator/RuleContext.java | 19 +-
.../any23/validator/SerializationException.java | 3 +-
.../apache/any23/validator/ValidationReport.java | 75 +-
.../any23/validator/ValidationReportBuilder.java | 36 +-
.../validator/ValidationReportSerializer.java | 10 +-
.../java/org/apache/any23/validator/Validator.java | 49 +-
.../apache/any23/validator/ValidatorException.java | 3 +-
.../validator/XMLValidationReportSerializer.java | 71 +-
.../org/apache/any23/validator/package-info.java | 5 +-
.../any23/validator/rule/AboutNotURIRule.java | 25 +-
.../any23/validator/rule/MetaNameMisuseFix.java | 1 +
.../any23/validator/rule/MetaNameMisuseRule.java | 19 +-
.../rule/MissingItemscopeAttributeValueFix.java | 59 +-
.../rule/MissingItemscopeAttributeValueRule.java | 84 +-
.../rule/MissingOpenGraphNamespaceRule.java | 23 +-
.../validator/rule/OpenGraphNamespaceFix.java | 1 +
.../apache/any23/validator/rule/package-info.java | 4 +-
.../org/apache/any23/vocab/RDFSchemaUtils.java | 113 +-
.../any23/writer/BenchmarkTripleHandler.java | 29 +-
.../any23/writer/CompositeTripleHandler.java | 19 +-
.../apache/any23/writer/CountingTripleHandler.java | 15 +-
.../java/org/apache/any23/writer/JSONLDWriter.java | 9 +-
.../java/org/apache/any23/writer/JSONWriter.java | 12 +-
.../org/apache/any23/writer/JSONWriterFactory.java | 2 +-
.../apache/any23/writer/LoggingTripleHandler.java | 29 +-
.../java/org/apache/any23/writer/NQuadsWriter.java | 8 +-
.../org/apache/any23/writer/NTriplesWriter.java | 8 +-
.../any23/writer/RDFWriterTripleHandler.java | 40 +-
.../java/org/apache/any23/writer/RDFXMLWriter.java | 6 +-
.../any23/writer/ReportingTripleHandler.java | 27 +-
.../org/apache/any23/writer/RepositoryWriter.java | 34 +-
.../java/org/apache/any23/writer/TriXWriter.java | 3 +-
.../apache/any23/writer/TripleWriterHandler.java | 121 +-
.../java/org/apache/any23/writer/TurtleWriter.java | 14 +-
.../org/apache/any23/writer/URIListWriter.java | 18 +-
.../apache/any23/writer/URIListWriterFactory.java | 1 -
.../org/apache/any23/writer/WriterSettings.java | 18 +-
.../java/org/apache/any23/writer/package-info.java | 4 +-
.../org/apache/any23/AbstractAny23TestBase.java | 47 +-
.../java/org/apache/any23/Any23OnlineTestBase.java | 5 +-
core/src/test/java/org/apache/any23/Any23Test.java | 342 ++--
.../configuration/DefaultConfigurationTest.java | 12 +-
.../apache/any23/extractor/ExtractionAPITest.java | 12 +-
.../any23/extractor/ExtractionParametersTest.java | 25 +-
.../any23/extractor/ExtractionResultImplTest.java | 25 +-
.../apache/any23/extractor/MockTripleHandler.java | 16 +-
.../extractor/SingleDocumentExtractionTest.java | 148 +-
.../calendar/BaseCalendarExtractorTest.java | 12 +-
.../extractor/calendar/ICalExtractorTest.java | 1 -
.../any23/extractor/csv/CSVExtractorTest.java | 169 +-
.../any23/extractor/csv/CSVReaderBuilderTest.java | 44 +-
.../any23/extractor/example/ExampleExtractor.java | 9 +-
.../extractor/example/ExampleExtractorFactory.java | 15 +-
.../any23/extractor/example/package-info.java | 3 +-
.../extractor/html/AbstractExtractorTestCase.java | 1667 +++++++++---------
.../any23/extractor/html/AdrExtractorTest.java | 8 +-
.../apache/any23/extractor/html/DomUtilsTest.java | 81 +-
.../html/EmbeddedJSONLDExtractorTest.java | 127 +-
.../apache/any23/extractor/html/EncodingTest.java | 17 +-
.../extractor/html/HCalendarExtractorTest.java | 729 ++++----
.../any23/extractor/html/HCardExtractorTest.java | 1804 ++++++++++----------
.../extractor/html/HListingExtractorTest.java | 591 +++----
.../any23/extractor/html/HRecipeExtractorTest.java | 56 +-
.../any23/extractor/html/HResumeExtractorTest.java | 228 ++-
.../any23/extractor/html/HReviewExtractorTest.java | 521 +++---
.../any23/extractor/html/HTMLDocumentTest.java | 12 +-
.../extractor/html/HTMLMetaExtractorTest.java | 84 +-
.../extractor/html/HeadLinkExtractorTest.java | 14 +-
.../any23/extractor/html/LicenseExtractorTest.java | 7 +-
.../apache/any23/extractor/html/RDFMergerTest.java | 827 +++++----
.../extractor/html/SpanCloserInputStreamTest.java | 84 +-
.../any23/extractor/html/SpeciesExtractorTest.java | 3 +-
.../any23/extractor/html/TagSoupParserTest.java | 60 +-
.../any23/extractor/html/TitleExtractorTest.java | 9 +-
.../extractor/html/TurtleHTMLExtractorTest.java | 13 +-
.../any23/extractor/html/XFNExtractorTest.java | 7 +-
.../html/microformats2/HAdrExtractorTest.java | 2 +-
.../html/microformats2/HCardExtractorTest.java | 2 +-
.../html/microformats2/HGeoExtractorTest.java | 3 +-
.../microdata/MicrodataExtractorTest.java | 237 +--
.../extractor/microdata/MicrodataParserTest.java | 144 +-
.../rdf/FunctionalSyntaxExtractorTest.java | 3 +-
.../any23/extractor/rdf/JSONLDExtractorTest.java | 125 +-
.../rdf/ManchesterSyntaxExtractorTest.java | 11 +-
.../any23/extractor/rdf/TurtleExtractorTest.java | 19 +-
.../rdfa/AbstractRDFaExtractorTestCase.java | 213 ++-
.../extractor/rdfa/ExtractionExceptionTest.java | 18 +-
.../any23/extractor/rdfa/RDFa11ExtractorTest.java | 216 ++-
.../any23/extractor/rdfa/RDFa11ParserTest.java | 18 +-
.../any23/extractor/rdfa/RDFaExtractorTest.java | 32 +-
.../xpath/TemplateXPathExtractorRuleImplTest.java | 71 +-
.../extractor/yaml/ElementsProcessorTest.java | 27 +-
.../any23/extractor/yaml/YAMLExtractorTest.java | 57 +-
.../any23/extractor/yaml/YAMLTikaParserTest.java | 17 +-
.../any23/filter/ExtractionContextBlockerTest.java | 1 -
.../any23/filter/IgnoreAccidentalRDFaTest.java | 30 +-
.../apache/any23/http/AcceptHeaderBuilderTest.java | 56 +-
.../any23/plugin/Any23PluginManagerTest.java | 15 +-
.../java/org/apache/any23/rdf/PrefixesTest.java | 2 -
.../java/org/apache/any23/rdf/RDFUtilsTest.java | 29 +-
.../org/apache/any23/util/DiscoveryUtilsTest.java | 16 +-
.../any23/validator/DefaultValidatorTest.java | 13 +-
.../XMLValidationReportSerializerTest.java | 21 +-
.../org/apache/any23/vocab/RDFSchemaUtilsTest.java | 10 +-
.../org/apache/any23/vocab/VocabularyTest.java | 23 +-
.../org/apache/any23/writer/JSONWriterTest.java | 127 +-
.../apache/any23/writer/WriterRegistryTest.java | 18 +-
.../any23/extractor/csv/CSVReaderBuilder.java | 62 +-
.../org/apache/any23/encoding/EncodingUtils.java | 278 ++-
.../any23/encoding/TikaEncodingDetector.java | 33 +-
.../any23/encoding/TikaEncodingDetectorTest.java | 20 +-
.../apache/any23/mime/NaiveMIMETypeDetector.java | 35 +-
.../apache/any23/mime/TikaMIMETypeDetector.java | 188 +-
.../any23/mime/purifier/WhiteSpacesPurifier.java | 12 +-
.../any23/mime/TikaMIMETypeDetectorTest.java | 112 +-
.../mime/purifier/WhiteSpacesPurifierTest.java | 15 +-
pom.xml | 15 +
398 files changed, 12934 insertions(+), 13785 deletions(-)
diff --git a/api/src/main/java/org/apache/any23/cli/Tool.java b/api/src/main/java/org/apache/any23/cli/Tool.java
index b25a029..4fb4419 100644
--- a/api/src/main/java/org/apache/any23/cli/Tool.java
+++ b/api/src/main/java/org/apache/any23/cli/Tool.java
@@ -26,7 +26,9 @@ public interface Tool {
/**
* Runs the tool and retrieves the exit code.
- * @throws Exception if there is an error running the tool.
+ *
+ * @throws Exception
+ * if there is an error running the tool.
*/
void run() throws Exception;
diff --git a/api/src/main/java/org/apache/any23/configuration/Configuration.java b/api/src/main/java/org/apache/any23/configuration/Configuration.java
index d280f37..20cae60 100644
--- a/api/src/main/java/org/apache/any23/configuration/Configuration.java
+++ b/api/src/main/java/org/apache/any23/configuration/Configuration.java
@@ -32,7 +32,9 @@ public interface Configuration {
/**
* Checks whether a property is defined or not in configuration.
*
- * @param propertyName name of property to check.
+ * @param propertyName
+ * name of property to check.
+ *
* @return <code>true</code> if defined, <code>false</code> otherwise.
*/
boolean defineProperty(String propertyName);
@@ -40,45 +42,61 @@ public interface Configuration {
/**
* Returns the value of a specified property, of the default value if property is not defined.
*
- * @param propertyName name of property
- * @param defaultValue default value if not found.
+ * @param propertyName
+ * name of property
+ * @param defaultValue
+ * default value if not found.
+ *
* @return the value associated to <i>propertyName</i>.
*/
String getProperty(String propertyName, String defaultValue);
/**
- * Returns the value of the specified <code>propertyName</code> or raises an exception
- * if <code>propertyName</code> is not defined.
+ * Returns the value of the specified <code>propertyName</code> or raises an exception if <code>propertyName</code>
+ * is not defined.
*
- * @param propertyName name of property to be returned.
+ * @param propertyName
+ * name of property to be returned.
+ *
* @return property value.
- * @throws IllegalArgumentException if the property name is not defined
- * or the found property value is blank or empty.
+ *
+ * @throws IllegalArgumentException
+ * if the property name is not defined or the found property value is blank or empty.
*/
String getPropertyOrFail(String propertyName);
/**
- * Returns the {@link Integer} value of the specified <code>propertyName</code> or raises an exception
- * if <code>propertyName</code> is not defined.
+ * Returns the {@link Integer} value of the specified <code>propertyName</code> or raises an exception if
+ * <code>propertyName</code> is not defined.
*
- * @param propertyName name of property to be returned.
+ * @param propertyName
+ * name of property to be returned.
+ *
* @return property value.
- * @throws NullPointerException if the property name is not defined.
- * @throws IllegalArgumentException if the found property value is blank or empty.
- * @throws NumberFormatException if the found property value is not a valid {@link Integer}.
+ *
+ * @throws NullPointerException
+ * if the property name is not defined.
+ * @throws IllegalArgumentException
+ * if the found property value is blank or empty.
+ * @throws NumberFormatException
+ * if the found property value is not a valid {@link Integer}.
*/
int getPropertyIntOrFail(String propertyName);
/**
* Returns the value of a <i> flag property</i>. Such properties can assume only two values:
* <ul>
- * <li><code>on</code> if flag is active (<code>true</code> is returned).
- * <li><code>off</code> if flag is inactive (<code>false</code> is returned).
+ * <li><code>on</code> if flag is active (<code>true</code> is returned).
+ * <li><code>off</code> if flag is inactive (<code>false</code> is returned).
* </ul>
*
- * @param propertyName name of property flag.
+ * @param propertyName
+ * name of property flag.
+ *
* @return <code>true</code> for <code>on</code>, <code>false</code> for <code>off</code>.
- * @throws IllegalArgumentException if the <code>propertyName</code> is not declared.
+ *
+ * @throws IllegalArgumentException
+ * if the <code>propertyName</code> is not declared.
*/
boolean getFlagProperty(final String propertyName);
diff --git a/api/src/main/java/org/apache/any23/configuration/DefaultConfiguration.java b/api/src/main/java/org/apache/any23/configuration/DefaultConfiguration.java
index ce346b5..a8d34d7 100644
--- a/api/src/main/java/org/apache/any23/configuration/DefaultConfiguration.java
+++ b/api/src/main/java/org/apache/any23/configuration/DefaultConfiguration.java
@@ -24,10 +24,8 @@ import java.io.IOException;
import java.util.Properties;
/**
- * Default implementation of {@link Configuration}.
- * The default property values are read from the
- * <i>/default-configuration.properties</i> properties file
- * in classpath.
+ * Default implementation of {@link Configuration}. The default property values are read from the
+ * <i>/default-configuration.properties</i> properties file in classpath.
*
* @author Michele Mostarda (michele.mostarda@gmail.com)
*/
@@ -38,7 +36,7 @@ public class DefaultConfiguration implements Configuration {
*/
public static final String DEFAULT_CONFIG_FILE = "/default-configuration.properties";
- public static final String FLAG_PROPERTY_ON = "on";
+ public static final String FLAG_PROPERTY_ON = "on";
public static final String FLAG_PROPERTY_OFF = "off";
@@ -53,12 +51,11 @@ public class DefaultConfiguration implements Configuration {
}
private DefaultConfiguration() {
- this( loadDefaultProperties() );
+ this(loadDefaultProperties());
}
/**
- * @return the singleton configuration instance.
- * Such instance is unmodifiable.
+ * @return the singleton configuration instance. Such instance is unmodifiable.
*/
public static synchronized DefaultConfiguration singleton() {
return singleton;
@@ -75,7 +72,7 @@ public class DefaultConfiguration implements Configuration {
private static Properties loadDefaultProperties() {
final Properties properties = new Properties();
try {
- properties.load( DefaultConfiguration.class.getResourceAsStream(DEFAULT_CONFIG_FILE) );
+ properties.load(DefaultConfiguration.class.getResourceAsStream(DEFAULT_CONFIG_FILE));
} catch (IOException ioe) {
throw new IllegalStateException("Error while loading default configuration.", ioe);
}
@@ -84,7 +81,7 @@ public class DefaultConfiguration implements Configuration {
@Override
public synchronized String[] getProperties() {
- return properties.keySet().toArray( new String[properties.size()] );
+ return properties.keySet().toArray(new String[properties.size()]);
}
@Override
@@ -95,7 +92,7 @@ public class DefaultConfiguration implements Configuration {
@Override
public synchronized String getProperty(String propertyName, String defaultValue) {
final String value = getPropertyValue(propertyName);
- if(value == null) {
+ if (value == null) {
return defaultValue;
}
return value;
@@ -104,13 +101,12 @@ public class DefaultConfiguration implements Configuration {
@Override
public synchronized String getPropertyOrFail(String propertyName) {
final String propertyValue = getPropertyValue(propertyName);
- if(propertyValue == null) {
+ if (propertyValue == null) {
throw new IllegalArgumentException("The property '" + propertyName + "' is expected to be declared.");
}
- if( propertyValue.trim().length() == 0) {
+ if (propertyValue.trim().length() == 0) {
throw new IllegalArgumentException(
- "Invalid value '" + propertyValue + "' for property '" + propertyName + "'"
- );
+ "Invalid value '" + propertyValue + "' for property '" + propertyName + "'");
}
return propertyValue;
}
@@ -129,22 +125,18 @@ public class DefaultConfiguration implements Configuration {
@Override
public synchronized boolean getFlagProperty(final String propertyName) {
final String value = getPropertyOrFail(propertyName);
- if(value == null) {
+ if (value == null) {
return false;
}
- if(FLAG_PROPERTY_ON.equals(value)) {
+ if (FLAG_PROPERTY_ON.equals(value)) {
return true;
}
- if(FLAG_PROPERTY_OFF.equals(value)) {
+ if (FLAG_PROPERTY_OFF.equals(value)) {
return false;
}
- throw new IllegalArgumentException(
- String.format(
- java.util.Locale.ROOT,
- "Invalid value [%s] for flag property [%s]. Supported values are %s|%s",
- value, propertyName, FLAG_PROPERTY_ON, FLAG_PROPERTY_OFF
- )
- );
+ throw new IllegalArgumentException(String.format(java.util.Locale.ROOT,
+ "Invalid value [%s] for flag property [%s]. Supported values are %s|%s", value, propertyName,
+ FLAG_PROPERTY_ON, FLAG_PROPERTY_OFF));
}
@Override
@@ -160,21 +152,16 @@ public class DefaultConfiguration implements Configuration {
}
private String getPropertyValue(String propertyName) {
- if( ! defineProperty(propertyName) ) {
- if(logger.isDebugEnabled()) {
- logger.debug(
- String.format(
- java.util.Locale.ROOT,
- "Property '%s' is not declared in default configuration file [%s]",
- propertyName,
- DEFAULT_CONFIG_FILE
- )
- );
+ if (!defineProperty(propertyName)) {
+ if (logger.isDebugEnabled()) {
+ logger.debug(String.format(java.util.Locale.ROOT,
+ "Property '%s' is not declared in default configuration file [%s]", propertyName,
+ DEFAULT_CONFIG_FILE));
}
return null;
}
final String systemValue = System.getProperties().getProperty(propertyName);
- if(systemValue == null) {
+ if (systemValue == null) {
return properties.getProperty(propertyName);
}
return systemValue;
diff --git a/api/src/main/java/org/apache/any23/configuration/DefaultModifiableConfiguration.java b/api/src/main/java/org/apache/any23/configuration/DefaultModifiableConfiguration.java
index 470a167..2f8e94a 100644
--- a/api/src/main/java/org/apache/any23/configuration/DefaultModifiableConfiguration.java
+++ b/api/src/main/java/org/apache/any23/configuration/DefaultModifiableConfiguration.java
@@ -24,7 +24,7 @@ import java.util.Properties;
*
* @author Michele Mostarda (mostarda@fbk.eu)
*/
-public class DefaultModifiableConfiguration extends DefaultConfiguration implements ModifiableConfiguration{
+public class DefaultModifiableConfiguration extends DefaultConfiguration implements ModifiableConfiguration {
protected DefaultModifiableConfiguration(Properties properties) {
super(properties);
@@ -32,10 +32,9 @@ public class DefaultModifiableConfiguration extends DefaultConfiguration impleme
@Override
public synchronized String setProperty(String propertyName, String propertyValue) {
- if( ! defineProperty(propertyName) )
- throw new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Property '%s' is not defined in configuration.", propertyName)
- );
+ if (!defineProperty(propertyName))
+ throw new IllegalArgumentException(String.format(java.util.Locale.ROOT,
+ "Property '%s' is not defined in configuration.", propertyName));
return (String) properties.setProperty(propertyName, propertyValue);
}
diff --git a/api/src/main/java/org/apache/any23/configuration/ModifiableConfiguration.java b/api/src/main/java/org/apache/any23/configuration/ModifiableConfiguration.java
index b238bd8..f0720a2 100644
--- a/api/src/main/java/org/apache/any23/configuration/ModifiableConfiguration.java
+++ b/api/src/main/java/org/apache/any23/configuration/ModifiableConfiguration.java
@@ -25,11 +25,13 @@ package org.apache.any23.configuration;
public interface ModifiableConfiguration extends Configuration {
/**
- * Sets a new value <code>propertyValue</code> for
- * property which name <code>propertyName</code>.
+ * Sets a new value <code>propertyValue</code> for property which name <code>propertyName</code>.
*
- * @param propertyName name of property.
- * @param propertyValue value of property.
+ * @param propertyName
+ * name of property.
+ * @param propertyValue
+ * value of property.
+ *
* @return the old property value.
*/
String setProperty(String propertyName, String propertyValue);
diff --git a/api/src/main/java/org/apache/any23/configuration/Setting.java b/api/src/main/java/org/apache/any23/configuration/Setting.java
index 0e17209..cebba6b 100644
--- a/api/src/main/java/org/apache/any23/configuration/Setting.java
+++ b/api/src/main/java/org/apache/any23/configuration/Setting.java
@@ -37,11 +37,16 @@ public abstract class Setting<V> implements Cloneable {
private V value;
/**
- * Constructs a new setting with the specified identifier and default value. This constructor must be called
- * with concrete type arguments.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
- * @throws IllegalArgumentException if the identifier or any of the type arguments were invalid
+ * Constructs a new setting with the specified identifier and default value. This constructor must be called with
+ * concrete type arguments.
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
+ * @throws IllegalArgumentException
+ * if the identifier or any of the type arguments were invalid
*/
protected Setting(String identifier, V defaultValue) {
checkIdentifier(identifier);
@@ -51,22 +56,27 @@ public abstract class Setting<V> implements Cloneable {
/**
* Constructs a new setting with the specified identifier, value type, and default value.
- * @param identifier the identifier for this setting
- * @param valueType the value type for this setting
- * @param defaultValue the default value for this setting
- * @throws IllegalArgumentException if the identifier is invalid, or
- * the value type is primitive, mutable, or has type parameters
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param valueType
+ * the value type for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid, or the value type is primitive, mutable, or has type parameters
*/
protected Setting(String identifier, Class<V> valueType, V defaultValue) {
this(identifier, defaultValue, valueType);
if (valueType.isArray()) {
throw new IllegalArgumentException(identifier + " value class must be immutable");
} else if (valueType.getTypeParameters().length != 0) {
- throw new IllegalArgumentException(identifier + " setting key must fill in type parameters for "
- + valueType.toGenericString());
+ throw new IllegalArgumentException(
+ identifier + " setting key must fill in type parameters for " + valueType.toGenericString());
} else if (valueType.isPrimitive()) {
- //ensure using primitive wrapper classes
- //so that Class.isInstance(), etc. will work as expected
+ // ensure using primitive wrapper classes
+ // so that Class.isInstance(), etc. will work as expected
throw new IllegalArgumentException(identifier + " value class cannot be primitive");
}
}
@@ -85,12 +95,15 @@ public abstract class Setting<V> implements Cloneable {
}
/**
- * Subclasses may override this method to check that new values for this setting are valid.
- * The default implementation of this method throws a {@link NullPointerException} if the
- * new value is null and the original default value for this setting was non-null.
+ * Subclasses may override this method to check that new values for this setting are valid. The default
+ * implementation of this method throws a {@link NullPointerException} if the new value is null and the original
+ * default value for this setting was non-null.
*
- * @param newValue the new value for this setting
- * @throws Exception if the new value for this setting is invalid
+ * @param newValue
+ * the new value for this setting
+ *
+ * @throws Exception
+ * if the new value for this setting is invalid
*/
protected void checkValue(V newValue) throws Exception {
if (newValue == null && key.nonnull) {
@@ -113,23 +126,30 @@ public abstract class Setting<V> implements Cloneable {
}
/**
- * @param setting a setting that may or may not have the same key as this setting
- * @param <S> the type of the supplied setting
+ * @param setting
+ * a setting that may or may not have the same key as this setting
+ * @param <S>
+ * the type of the supplied setting
+ *
* @return this setting, if this setting has the same key as the supplied setting
*/
@SuppressWarnings("unchecked")
public final <S extends Setting<?>> Optional<S> as(S setting) {
- return key == ((Setting<?>)setting).key ? Optional.of((S)this) : Optional.empty();
+ return key == ((Setting<?>) setting).key ? Optional.of((S) this) : Optional.empty();
}
/**
- * @param newValue a value for a new setting
+ * @param newValue
+ * a value for a new setting
+ *
* @return a new {@link Setting} object with this setting's key and the supplied value.
*
- * @throws IllegalArgumentException if the new value was invalid, as determined by:
- * <pre>
+ * @throws IllegalArgumentException
+ * if the new value was invalid, as determined by:
+ *
+ * <pre>
* {@code this.checkValue(newValue)}
- * </pre>
+ * </pre>
*
* @see Setting#checkValue(Object)
*/
@@ -140,7 +160,7 @@ public abstract class Setting<V> implements Cloneable {
@Override
protected final Object clone() {
try {
- //ensure no subclasses override this incorrectly
+ // ensure no subclasses override this incorrectly
return super.clone();
} catch (CloneNotSupportedException e) {
throw new AssertionError(e);
@@ -148,13 +168,15 @@ public abstract class Setting<V> implements Cloneable {
}
/**
- * @return true if the supplied object is an instance of {@link Setting}
- * and has the same key and value as this setting.
+ * @return true if the supplied object is an instance of {@link Setting} and has the same key and value as this
+ * setting.
*/
@Override
public final boolean equals(Object o) {
- if (this == o) return true;
- if (!(o instanceof Setting)) return false;
+ if (this == o)
+ return true;
+ if (!(o instanceof Setting))
+ return false;
Setting<?> setting = (Setting<?>) o;
return key == setting.key && Objects.equals(value, setting.value);
@@ -170,13 +192,18 @@ public abstract class Setting<V> implements Cloneable {
return key.identifier + "=" + value;
}
-
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<Boolean> create(String identifier, Boolean defaultValue) {
return new Impl<>(identifier, defaultValue, Boolean.class);
@@ -184,10 +211,16 @@ public abstract class Setting<V> implements Cloneable {
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<String> create(String identifier, String defaultValue) {
return new Impl<>(identifier, defaultValue, String.class);
@@ -195,10 +228,16 @@ public abstract class Setting<V> implements Cloneable {
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<Integer> create(String identifier, Integer defaultValue) {
return new Impl<>(identifier, defaultValue, Integer.class);
@@ -206,10 +245,16 @@ public abstract class Setting<V> implements Cloneable {
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<Long> create(String identifier, Long defaultValue) {
return new Impl<>(identifier, defaultValue, Long.class);
@@ -217,10 +262,16 @@ public abstract class Setting<V> implements Cloneable {
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<Float> create(String identifier, Float defaultValue) {
return new Impl<>(identifier, defaultValue, Float.class);
@@ -228,25 +279,37 @@ public abstract class Setting<V> implements Cloneable {
/**
* Convenience method to create a new setting with the specified identifier and default value.
- * @param identifier the identifier for this setting
- * @param defaultValue the default value for this setting
+ *
+ * @param identifier
+ * the identifier for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid
*/
public static Setting<Double> create(String identifier, Double defaultValue) {
return new Impl<>(identifier, defaultValue, Double.class);
}
/**
- * Convenience method to create a new setting with the specified identifier,
- * value type, and default value.
- * @param <V> generic setting value type
- * @param identifier the identifier for this setting
- * @param valueType the value type for this setting
- * @param defaultValue the default value for this setting
+ * Convenience method to create a new setting with the specified identifier, value type, and default value.
+ *
+ * @param <V>
+ * generic setting value type
+ * @param identifier
+ * the identifier for this setting
+ * @param valueType
+ * the value type for this setting
+ * @param defaultValue
+ * the default value for this setting
+ *
* @return the new setting
- * @throws IllegalArgumentException if the identifier is invalid, or
- * the value type is primitive, mutable, or has type parameters
+ *
+ * @throws IllegalArgumentException
+ * if the identifier is invalid, or the value type is primitive, mutable, or has type parameters
*/
public static <V> Setting<V> create(String identifier, Class<V> valueType, V defaultValue) {
return new Impl<>(identifier, valueType, defaultValue);
@@ -259,11 +322,12 @@ public abstract class Setting<V> implements Cloneable {
// Use Impl when possible to avoid creating an anonymous class (and class file) for
// every single existing setting, and to avoid the overhead of value type lookup.
private static class Impl<V> extends Setting<V> {
- //this constructor does not check the value type
+ // this constructor does not check the value type
private Impl(String identifier, V defaultValue, Class<V> valueType) {
super(identifier, defaultValue, valueType);
}
- //this constructor does check the value type
+
+ // this constructor does check the value type
private Impl(String identifier, Class<V> valueType, V defaultValue) {
super(identifier, valueType, defaultValue);
}
@@ -286,21 +350,22 @@ public abstract class Setting<V> implements Cloneable {
try {
setting.checkValue(newValue);
} catch (Exception e) {
- throw new IllegalArgumentException("invalid value for key '"
- + ((Setting<V>)setting).key.identifier + "': " + ((Setting<V>)setting).value, e);
+ throw new IllegalArgumentException("invalid value for key '" + ((Setting<V>) setting).key.identifier + "': "
+ + ((Setting<V>) setting).value, e);
}
- //important to clone so that we can retain checkValue(), toString() behavior on returned instance
- S s = (S)setting.clone();
+ // important to clone so that we can retain checkValue(), toString() behavior on returned instance
+ S s = (S) setting.clone();
- assert ((Setting<V>)s).key == ((Setting<V>)setting).key;
- assert ((Setting<V>)s).getClass().equals(setting.getClass());
+ assert ((Setting<V>) s).key == ((Setting<V>) setting).key;
+ assert ((Setting<V>) s).getClass().equals(setting.getClass());
- ((Setting<V>)s).value = newValue;
+ ((Setting<V>) s).value = newValue;
return s;
}
private static final Pattern identifierPattern = Pattern.compile("[a-z][0-9a-z]*(\\.[a-z][0-9a-z]*)*");
+
private static void checkIdentifier(String identifier) {
if (identifier == null) {
throw new IllegalArgumentException("identifier cannot be null");
@@ -316,7 +381,7 @@ public abstract class Setting<V> implements Cloneable {
for (;;) {
Type superclass = rawType.getGenericSuperclass();
if (superclass instanceof ParameterizedType) {
- rawType = (Class<?>)((ParameterizedType) superclass).getRawType();
+ rawType = (Class<?>) ((ParameterizedType) superclass).getRawType();
Type[] args = ((ParameterizedType) superclass).getActualTypeArguments();
if (Setting.class.equals(rawType)) {
Type type = args[0];
@@ -325,14 +390,17 @@ public abstract class Setting<V> implements Cloneable {
if (((Class<?>) type).isArray()) {
throw new IllegalArgumentException(identifier + " value class must be immutable");
} else if (((Class<?>) type).getTypeParameters().length != 0) {
- throw new IllegalArgumentException(identifier + " setting must fill in type parameters for " + ((Class<?>) type).toGenericString());
+ throw new IllegalArgumentException(identifier + " setting must fill in type parameters for "
+ + ((Class<?>) type).toGenericString());
}
} else if (type instanceof GenericArrayType) {
throw new IllegalArgumentException(identifier + " value class must be immutable");
} else if (type instanceof TypeVariable) {
- throw new IllegalArgumentException("Invalid setting type 'Key<" + type.getTypeName() + ">' for identifier " + identifier);
+ throw new IllegalArgumentException(
+ "Invalid setting type 'Key<" + type.getTypeName() + ">' for identifier " + identifier);
} else if (!(type instanceof ParameterizedType)) {
- throw new IllegalArgumentException(identifier + " invalid type " + type + " (" + type.getClass().getName() + ")");
+ throw new IllegalArgumentException(
+ identifier + " invalid type " + type + " (" + type.getClass().getName() + ")");
}
return type;
}
@@ -342,7 +410,7 @@ public abstract class Setting<V> implements Cloneable {
mapping.put(vars[i], t instanceof TypeVariable ? mapping.get(t) : t);
}
} else {
- rawType = (Class<?>)superclass;
+ rawType = (Class<?>) superclass;
if (Setting.class.equals(rawType)) {
throw new IllegalArgumentException(rawType + " does not supply type arguments");
}
diff --git a/api/src/main/java/org/apache/any23/configuration/Settings.java b/api/src/main/java/org/apache/any23/configuration/Settings.java
index 2be73fa..bd9c4f9 100644
--- a/api/src/main/java/org/apache/any23/configuration/Settings.java
+++ b/api/src/main/java/org/apache/any23/configuration/Settings.java
@@ -27,9 +27,9 @@ import java.util.Optional;
import java.util.Set;
/**
- * This class represents an <i>immutable</i> {@link Set} of {@link Setting} objects,
- * with the additional property that no two settings having the same {@link Setting#getIdentifier() identifier}
- * can be simultaneously present in a {@code Settings} object.
+ * This class represents an <i>immutable</i> {@link Set} of {@link Setting} objects, with the additional property that
+ * no two settings having the same {@link Setting#getIdentifier() identifier} can be simultaneously present in a
+ * {@code Settings} object.
*
* @author Hans Brende (hansbrende@apache.org)
*/
@@ -44,7 +44,9 @@ public final class Settings extends AbstractSet<Setting<?>> {
}
/**
- * @param identifier the identifier of the setting to find
+ * @param identifier
+ * the identifier of the setting to find
+ *
* @return the setting with the identifier supplied, if present
*/
public Optional<Setting<?>> find(String identifier) {
@@ -52,13 +54,18 @@ public final class Settings extends AbstractSet<Setting<?>> {
}
/**
- * This method is semantically equivalent to:
- * <br><br>
+ * This method is semantically equivalent to: <br>
+ * <br>
+ *
* <pre>
* {@code find(setting.getIdentifier()).flatMap(s -> s.as(setting))}
* </pre>
- * @param <S> generic setting type
- * @param setting a setting key
+ *
+ * @param <S>
+ * generic setting type
+ * @param setting
+ * a setting key
+ *
* @return the setting with the same setting key as the supplied setting, if present.
*/
public <S extends Setting<?>> Optional<S> find(S setting) {
@@ -67,15 +74,20 @@ public final class Settings extends AbstractSet<Setting<?>> {
}
/**
- * This method is semantically equivalent to:
- * <br><br>
+ * This method is semantically equivalent to: <br>
+ * <br>
+ *
* <pre>
* {@code find(defaultSetting).orElse(defaultSetting).getValue()}
* </pre>
- * @param <E> generic setting type
- * @param defaultSetting a default key for which to obtain a value set
- * @return the value set for {@code defaultSetting}'s key, if present.
- * Otherwise, returns {@code defaultSetting}'s value.
+ *
+ * @param <E>
+ * generic setting type
+ * @param defaultSetting
+ * a default key for which to obtain a value set
+ *
+ * @return the value set for {@code defaultSetting}'s key, if present. Otherwise, returns {@code defaultSetting}'s
+ * value.
*/
public <E> E get(Setting<E> defaultSetting) {
return find(defaultSetting).orElse(defaultSetting).getValue();
@@ -109,6 +121,7 @@ public final class Settings extends AbstractSet<Setting<?>> {
/**
* Returns an empty {@link Settings} object.
+ *
* @return an empty {@link Settings} object
*/
public static Settings of() {
@@ -117,7 +130,10 @@ public final class Settings extends AbstractSet<Setting<?>> {
/**
* Returns a singleton {@link Settings} object, containing only the supplied Setting.
- * @param s one {@link org.apache.any23.configuration.Setting}
+ *
+ * @param s
+ * one {@link org.apache.any23.configuration.Setting}
+ *
* @return a {@link Settings} object containing the supplied Setting.
*/
public static Settings of(Setting<?> s) {
@@ -125,32 +141,42 @@ public final class Settings extends AbstractSet<Setting<?>> {
}
/**
- * @param settings one or more {@link org.apache.any23.configuration.Setting}'s
- * @return a {@link Settings} object containing the supplied settings.
- * For any two settings having the same key, the first will be overwritten by the second.
- * @throws IllegalArgumentException if any two settings have the same identifier
+ * @param settings
+ * one or more {@link org.apache.any23.configuration.Setting}'s
+ *
+ * @return a {@link Settings} object containing the supplied settings. For any two settings having the same key, the
+ * first will be overwritten by the second.
+ *
+ * @throws IllegalArgumentException
+ * if any two settings have the same identifier
*/
public static Settings of(Setting<?>... settings) {
Map<String, Setting<?>> map = mapForSize(settings.length);
- for (Setting<?> s : settings) put(map, s);
+ for (Setting<?> s : settings)
+ put(map, s);
return ofModifiable(map);
}
/**
- * @param c a populated {@link java.util.Collection} of {@link org.apache.any23.configuration.Setting}'s
+ * @param c
+ * a populated {@link java.util.Collection} of {@link org.apache.any23.configuration.Setting}'s
+ *
* @return a {@link Settings} object containing the supplied settings.
- * @throws IllegalArgumentException if any two settings have the same identifier
+ *
+ * @throws IllegalArgumentException
+ * if any two settings have the same identifier
*/
public static Settings of(Collection<? extends Setting<?>> c) {
if (c instanceof Settings) {
- return (Settings)c;
+ return (Settings) c;
}
int size = c.size();
if (size == 0) {
return EMPTY_SETTINGS;
}
Map<String, Setting<?>> map = mapForSize(size);
- for (Setting<?> s : c) put(map, s);
+ for (Setting<?> s : c)
+ put(map, s);
return ofModifiable(map);
}
@@ -170,8 +196,9 @@ public final class Settings extends AbstractSet<Setting<?>> {
}
private static final float loadFactor = 0.75f;
+
private static Map<String, Setting<?>> mapForSize(int size) {
- return new HashMap<>((int)(size / loadFactor) + 1, loadFactor);
+ return new HashMap<>((int) (size / loadFactor) + 1, loadFactor);
}
}
diff --git a/api/src/main/java/org/apache/any23/encoding/EncodingDetector.java b/api/src/main/java/org/apache/any23/encoding/EncodingDetector.java
index b9de1ba..c71e30e 100644
--- a/api/src/main/java/org/apache/any23/encoding/EncodingDetector.java
+++ b/api/src/main/java/org/apache/any23/encoding/EncodingDetector.java
@@ -30,21 +30,30 @@ public interface EncodingDetector {
/**
* Guesses the data encoding.
*
- * @param input the input stream containing the data.
- * @return a string compliant to
- * <a href="http://www.iana.org/assignments/character-sets">IANA Charset Specification</a>.
- * @throws IOException if there is an error whilst guessing the encoding.
+ * @param input
+ * the input stream containing the data.
+ *
+ * @return a string compliant to <a href="http://www.iana.org/assignments/character-sets">IANA Charset
+ * Specification</a>.
+ *
+ * @throws IOException
+ * if there is an error whilst guessing the encoding.
*/
String guessEncoding(InputStream input) throws IOException;
/**
* Guesses the data encoding.
*
- * @param input the input stream containing the data.
- * @param contentType the declared content type of the data.
- * @return a string compliant to
- * <a href="http://www.iana.org/assignments/character-sets">IANA Charset Specification</a>.
- * @throws IOException if there is an error whilst guessing the encoding.
+ * @param input
+ * the input stream containing the data.
+ * @param contentType
+ * the declared content type of the data.
+ *
+ * @return a string compliant to <a href="http://www.iana.org/assignments/character-sets">IANA Charset
+ * Specification</a>.
+ *
+ * @throws IOException
+ * if there is an error whilst guessing the encoding.
*/
default String guessEncoding(InputStream input, String contentType) throws IOException {
return guessEncoding(input);
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractionContext.java b/api/src/main/java/org/apache/any23/extractor/ExtractionContext.java
index b144b5b..c7b8a2c 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractionContext.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractionContext.java
@@ -20,8 +20,7 @@ package org.apache.any23.extractor;
import org.eclipse.rdf4j.model.IRI;
/**
- * This class provides the context for the processing of
- * a single {@link Extractor}.
+ * This class provides the context for the processing of a single {@link Extractor}.
*/
public class ExtractionContext {
@@ -48,14 +47,12 @@ public class ExtractionContext {
private final String uniqueID;
public ExtractionContext(String extractorName, IRI documentIRI, String defaultLanguage, String localID) {
- checkNotNull(extractorName , "extractor name");
- checkNotNull(documentIRI , "document IRI");
- this.extractorName = extractorName;
- this.documentIRI = documentIRI;
+ checkNotNull(extractorName, "extractor name");
+ checkNotNull(documentIRI, "document IRI");
+ this.extractorName = extractorName;
+ this.documentIRI = documentIRI;
this.defaultLanguage = defaultLanguage;
- this.uniqueID =
- "urn:x-any23:" + extractorName + ":" +
- (localID == null ? "" : localID) + ":" + documentIRI;
+ this.uniqueID = "urn:x-any23:" + extractorName + ":" + (localID == null ? "" : localID) + ":" + documentIRI;
}
public ExtractionContext(String extractorName, IRI documentIRI, String defaultLanguage) {
@@ -67,12 +64,7 @@ public class ExtractionContext {
}
public ExtractionContext copy(String localID) {
- return new ExtractionContext(
- getExtractorName(),
- getDocumentIRI(),
- getDefaultLanguage(),
- localID
- );
+ return new ExtractionContext(getExtractorName(), getDocumentIRI(), getDefaultLanguage(), localID);
}
public String getExtractorName() {
@@ -96,7 +88,8 @@ public class ExtractionContext {
}
public boolean equals(Object other) {
- if (!(other instanceof ExtractionContext)) return false;
+ if (!(other instanceof ExtractionContext))
+ return false;
return ((ExtractionContext) other).uniqueID.equals(uniqueID);
}
@@ -105,7 +98,8 @@ public class ExtractionContext {
}
private void checkNotNull(Object data, String desc) {
- if(data == null) throw new NullPointerException(desc + " cannot be null.");
+ if (data == null)
+ throw new NullPointerException(desc + " cannot be null.");
}
-
+
}
\ No newline at end of file
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractionException.java b/api/src/main/java/org/apache/any23/extractor/ExtractionException.java
index f174582..4b71c77 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractionException.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractionException.java
@@ -46,7 +46,7 @@ public class ExtractionException extends Exception {
@Override
public void printStackTrace(PrintStream ps) {
- printExceptionResult( new PrintWriter(new OutputStreamWriter(ps, StandardCharsets.UTF_8), true));
+ printExceptionResult(new PrintWriter(new OutputStreamWriter(ps, StandardCharsets.UTF_8), true));
super.printStackTrace(ps);
}
@@ -57,12 +57,12 @@ public class ExtractionException extends Exception {
}
private void printExceptionResult(PrintWriter ps) {
- if(extractionResult == null) {
+ if (extractionResult == null) {
return;
}
ps.println();
ps.println("------------ BEGIN Exception context ------------");
- ps.print( extractionResult.toString() );
+ ps.print(extractionResult.toString());
ps.println("------------ END Exception context ------------");
ps.println();
ps.flush();
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractionParameters.java b/api/src/main/java/org/apache/any23/extractor/ExtractionParameters.java
index 9aeb6c7..874de48 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractionParameters.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractionParameters.java
@@ -24,8 +24,8 @@ import java.util.HashMap;
import java.util.Map;
/**
- * This class models the parameters to be used to perform an extraction.
- * See org.apache.any23.Any23 for more details.
+ * This class models the parameters to be used to perform an extraction. See org.apache.any23.Any23 for more details.
+ *
* @author Michele Mostarda (mostarda@fbk.eu)
*/
public class ExtractionParameters {
@@ -36,89 +36,83 @@ public class ExtractionParameters {
private final Map<String, Boolean> extractionFlags;
- private final Map<String,String> extractionProperties;
+ private final Map<String, String> extractionProperties;
- public static final String METADATA_DOMAIN_PER_ENTITY_FLAG = "any23.extraction.metadata.domain.per.entity";
+ public static final String METADATA_DOMAIN_PER_ENTITY_FLAG = "any23.extraction.metadata.domain.per.entity";
- public static final String METADATA_NESTING_FLAG = "any23.extraction.metadata.nesting";
+ public static final String METADATA_NESTING_FLAG = "any23.extraction.metadata.nesting";
- public static final String METADATA_TIMESIZE_FLAG = "any23.extraction.metadata.timesize";
+ public static final String METADATA_TIMESIZE_FLAG = "any23.extraction.metadata.timesize";
public static final String EXTRACTION_CONTEXT_IRI_PROPERTY = "any23.extraction.context.iri";
/**
* Constructor.
*
- * @param configuration underlying configuration.
- * @param extractionMode specifies the required extraction mode.
- * @param extractionFlags map of specific flags used for extraction. If not specified they will
- * be retrieved by the default {@link org.apache.any23.configuration.Configuration}.
- * @param extractionProperties map of specific properties used for extraction. If not specified
- * they will ne retrieved by the default {@link org.apache.any23.configuration.Configuration}.
+ * @param configuration
+ * underlying configuration.
+ * @param extractionMode
+ * specifies the required extraction mode.
+ * @param extractionFlags
+ * map of specific flags used for extraction. If not specified they will be retrieved by the default
+ * {@link org.apache.any23.configuration.Configuration}.
+ * @param extractionProperties
+ * map of specific properties used for extraction. If not specified they will ne retrieved by the default
+ * {@link org.apache.any23.configuration.Configuration}.
*/
- public ExtractionParameters(
- Configuration configuration,
- ValidationMode extractionMode,
- Map<String, Boolean> extractionFlags,
- Map<String,String> extractionProperties
- ) {
- if(configuration == null) {
+ public ExtractionParameters(Configuration configuration, ValidationMode extractionMode,
+ Map<String, Boolean> extractionFlags, Map<String, String> extractionProperties) {
+ if (configuration == null) {
throw new NullPointerException("Configuration cannot be null.");
}
- if(extractionMode == null) {
+ if (extractionMode == null) {
throw new NullPointerException("Extraction mode cannot be null.");
}
- this.configuration = configuration;
+ this.configuration = configuration;
this.extractionMode = extractionMode;
- this.extractionFlags =
- extractionFlags == null
- ?
- new HashMap<>()
- :
- new HashMap<>(extractionFlags);
- this.extractionProperties =
- extractionProperties == null
- ?
- new HashMap<>()
- :
- new HashMap<>(extractionProperties);
+ this.extractionFlags = extractionFlags == null ? new HashMap<>() : new HashMap<>(extractionFlags);
+ this.extractionProperties = extractionProperties == null ? new HashMap<>()
+ : new HashMap<>(extractionProperties);
}
/**
* Constructor.
*
- * @param configuration underlying configuration.
- * @param extractionMode specifies the required extraction mode.
+ * @param configuration
+ * underlying configuration.
+ * @param extractionMode
+ * specifies the required extraction mode.
*/
public ExtractionParameters(Configuration configuration, ValidationMode extractionMode) {
this(configuration, extractionMode, null, null);
}
/**
- * Constructor, allows to set explicitly the value for flag
- * SingleDocumentExtraction#METADATA_NESTING_FLAG.
+ * Constructor, allows to set explicitly the value for flag SingleDocumentExtraction#METADATA_NESTING_FLAG.
*
- * @param configuration the underlying configuration.
- * @param extractionMode specifies the required extraction mode.
- * @param nesting if <code>true</code> nesting triples will be expressed.
+ * @param configuration
+ * the underlying configuration.
+ * @param extractionMode
+ * specifies the required extraction mode.
+ * @param nesting
+ * if <code>true</code> nesting triples will be expressed.
*/
public ExtractionParameters(Configuration configuration, ValidationMode extractionMode, final boolean nesting) {
- this(
- configuration,
- extractionMode,
- new HashMap<String, Boolean>(){
- /**
- *
- */
- private static final long serialVersionUID = 1L; {
- put(ExtractionParameters.METADATA_NESTING_FLAG, nesting);
- }},
- null
- );
+ this(configuration, extractionMode, new HashMap<String, Boolean>() {
+ /**
+ *
+ */
+ private static final long serialVersionUID = 1L;
+ {
+ put(ExtractionParameters.METADATA_NESTING_FLAG, nesting);
+ }
+ }, null);
}
/**
- * @param c the underlying configuration.
+ * @param c
+ * the underlying configuration.
+ *
* @return the default extraction parameters.
*/
public static final ExtractionParameters newDefault(Configuration c) {
@@ -138,9 +132,7 @@ public class ExtractionParameters {
* Declares the supported validation actions.
*/
public enum ValidationMode {
- NONE,
- VALIDATE,
- VALIDATE_AND_FIX
+ NONE, VALIDATE, VALIDATE_AND_FIX
}
/**
@@ -158,15 +150,17 @@ public class ExtractionParameters {
}
/**
- * Returns the value of the specified extraction flag, if the flag is undefined
- * it will be retrieved by the default {@link org.apache.any23.configuration.Configuration}.
+ * Returns the value of the specified extraction flag, if the flag is undefined it will be retrieved by the default
+ * {@link org.apache.any23.configuration.Configuration}.
*
- * @param flagName name of flag.
+ * @param flagName
+ * name of flag.
+ *
* @return flag value.
*/
public boolean getFlag(String flagName) {
final Boolean value = extractionFlags.get(flagName);
- if(value == null) {
+ if (value == null) {
return configuration.getFlagProperty(flagName);
}
return value;
@@ -175,8 +169,11 @@ public class ExtractionParameters {
/**
* Sets the value for an extraction flag.
*
- * @param flagName flag name.
- * @param value new flag value.
+ * @param flagName
+ * flag name.
+ * @param value
+ * new flag value.
+ *
* @return the previous flag value.
*/
public Boolean setFlag(String flagName, boolean value) {
@@ -186,16 +183,20 @@ public class ExtractionParameters {
}
/**
- * Returns the value of the specified extraction property, if the property is undefined
- * it will be retrieved by the default {@link org.apache.any23.configuration.Configuration}.
+ * Returns the value of the specified extraction property, if the property is undefined it will be retrieved by the
+ * default {@link org.apache.any23.configuration.Configuration}.
*
- * @param propertyName the property name.
+ * @param propertyName
+ * the property name.
+ *
* @return the property value.
- * @throws IllegalArgumentException if the property name is not defined in configuration.
+ *
+ * @throws IllegalArgumentException
+ * if the property name is not defined in configuration.
*/
public String getProperty(String propertyName) {
final String propertyValue = extractionProperties.get(propertyName);
- if(propertyValue == null) {
+ if (propertyValue == null) {
return configuration.getPropertyOrFail(propertyName);
}
return propertyValue;
@@ -204,33 +205,32 @@ public class ExtractionParameters {
/**
* Sets the value for an extraction property.
*
- * @param propertyName the property name.
- * @param propertyValue the property value.
+ * @param propertyName
+ * the property name.
+ * @param propertyValue
+ * the property value.
+ *
* @return the previous property value.
*/
public String setProperty(String propertyName, String propertyValue) {
checkPropertyExists(propertyName);
- validateValue("property name" , propertyName);
+ validateValue("property name", propertyName);
validateValue("property value", propertyValue);
return extractionProperties.put(propertyName, propertyValue);
}
@Override
public boolean equals(Object obj) {
- if(obj == null) {
+ if (obj == null) {
return false;
}
- if(obj == this) {
+ if (obj == this) {
return true;
}
- if(obj instanceof ExtractionParameters) {
+ if (obj instanceof ExtractionParameters) {
ExtractionParameters other = (ExtractionParameters) obj;
- return
- extractionMode == other.extractionMode
- &&
- extractionFlags.equals( other.extractionFlags)
- &&
- extractionProperties.equals( other.extractionProperties );
+ return extractionMode == other.extractionMode && extractionFlags.equals(other.extractionFlags)
+ && extractionProperties.equals(other.extractionProperties);
}
return false;
}
@@ -241,15 +241,14 @@ public class ExtractionParameters {
}
private void checkPropertyExists(String propertyName) {
- if(! configuration.defineProperty(propertyName) ) {
+ if (!configuration.defineProperty(propertyName)) {
throw new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Property '%s' is unknown and cannot be set.", propertyName)
- );
+ String.format(java.util.Locale.ROOT, "Property '%s' is unknown and cannot be set.", propertyName));
}
}
private void validateValue(String desc, String value) {
- if(value == null || value.trim().length() == 0)
- throw new IllegalArgumentException( String.format(java.util.Locale.ROOT, "Invalid %s: '%s'", desc, value) );
+ if (value == null || value.trim().length() == 0)
+ throw new IllegalArgumentException(String.format(java.util.Locale.ROOT, "Invalid %s: '%s'", desc, value));
}
}
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractionResult.java b/api/src/main/java/org/apache/any23/extractor/ExtractionResult.java
index 22ebf08..6c33827 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractionResult.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractionResult.java
@@ -27,47 +27,56 @@ import org.eclipse.rdf4j.model.Value;
public interface ExtractionResult extends IssueReport {
/**
- * Writes a triple.
- * Parameters can be null, then the triple will be silently ignored.
+ * Writes a triple. Parameters can be null, then the triple will be silently ignored.
*
- * @param s subject
- * @param p predicate
- * @param o object
- * @param g graph
+ * @param s
+ * subject
+ * @param p
+ * predicate
+ * @param o
+ * object
+ * @param g
+ * graph
*/
void writeTriple(Resource s, IRI p, Value o, IRI g);
/**
- * Write a triple.
- * Parameters can be null, then the triple will be silently ignored.
+ * Write a triple. Parameters can be null, then the triple will be silently ignored.
*
- * @param s subject
- * @param p predicate
- * @param o object
+ * @param s
+ * subject
+ * @param p
+ * predicate
+ * @param o
+ * object
*/
void writeTriple(Resource s, IRI p, Value o);
/**
* Write a namespace.
*
- * @param prefix the prefix of the namespace
- * @param IRI the long IRI identifying the namespace
+ * @param prefix
+ * the prefix of the namespace
+ * @param IRI
+ * the long IRI identifying the namespace
*/
void writeNamespace(String prefix, String IRI);
/**
- * <p>Close the result.</p>
- * Extractors should close their results as soon as possible, but
- * don't have to, the environment will close any remaining ones.
- * Implementations should be robust against multiple close()
- * invocations.
+ * <p>
+ * Close the result.
+ * </p>
+ * Extractors should close their results as soon as possible, but don't have to, the environment will close any
+ * remaining ones. Implementations should be robust against multiple close() invocations.
*/
void close();
/**
* Open a result nested in the current one.
*
- * @param extractionContext the context to be used to open the sub result.
+ * @param extractionContext
+ * the context to be used to open the sub result.
+ *
* @return the instance of the nested extraction result.
*/
ExtractionResult openSubResult(ExtractionContext extractionContext);
diff --git a/api/src/main/java/org/apache/any23/extractor/Extractor.java b/api/src/main/java/org/apache/any23/extractor/Extractor.java
index 2d34084..313b9a5 100644
--- a/api/src/main/java/org/apache/any23/extractor/Extractor.java
+++ b/api/src/main/java/org/apache/any23/extractor/Extractor.java
@@ -26,53 +26,59 @@ import java.io.InputStream;
/**
* It defines the signature of a generic Extractor.
*
- * @param <Input> the type of the input data to be processed.
+ * @param <Input>
+ * the type of the input data to be processed.
*/
public interface Extractor<Input> {
/**
- * This interface specializes an {@link Extractor} able to handle
- * {@link java.net.URI} as input format. Use it if you need to fetch a document before the extraction
+ * This interface specializes an {@link Extractor} able to handle {@link java.net.URI} as input format. Use it if
+ * you need to fetch a document before the extraction
*/
public interface BlindExtractor extends Extractor<IRI> {
}
/**
- * This interface specializes an {@link Extractor} able to handle
- * {@link java.io.InputStream} as input format.
+ * This interface specializes an {@link Extractor} able to handle {@link java.io.InputStream} as input format.
*/
public interface ContentExtractor extends Extractor<InputStream> {
-
+
/**
- * If <code>true</code>, the extractor will stop at first parsing error,
- * if<code>false</code> the extractor will attempt to ignore all parsing errors.
+ * If <code>true</code>, the extractor will stop at first parsing error, if<code>false</code> the extractor will
+ * attempt to ignore all parsing errors.
*
- * @param f tolerance flag.
+ * @param f
+ * tolerance flag.
*/
void setStopAtFirstError(boolean f);
}
/**
- * This interface specializes an {@link Extractor} able to handle
- * {@link org.w3c.dom.Document} as input format.
+ * This interface specializes an {@link Extractor} able to handle {@link org.w3c.dom.Document} as input format.
*/
public interface TagSoupDOMExtractor extends Extractor<Document> {
}
/**
- * Executes the extractor. Will be invoked only once, extractors are
- * not reusable.
+ * Executes the extractor. Will be invoked only once, extractors are not reusable.
*
- * @param extractionParameters the parameters to be applied during the extraction.
- * @param context The document context.
- * @param in The extractor input data.
- * @param out the collector for the extracted data.
- * @throws IOException On error while reading from the input stream.
- * @throws ExtractionException On other error, such as parse errors.
+ * @param extractionParameters
+ * the parameters to be applied during the extraction.
+ * @param context
+ * The document context.
+ * @param in
+ * The extractor input data.
+ * @param out
+ * the collector for the extracted data.
+ *
+ * @throws IOException
+ * On error while reading from the input stream.
+ * @throws ExtractionException
+ * On other error, such as parse errors.
*/
void run(ExtractionParameters extractionParameters, ExtractionContext context, Input in, ExtractionResult out)
- throws IOException, ExtractionException;
+ throws IOException, ExtractionException;
/**
* Returns a {@link ExtractorDescription} of this extractor.
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractorDescription.java b/api/src/main/java/org/apache/any23/extractor/ExtractorDescription.java
index a601432..1c950e2 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractorDescription.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractorDescription.java
@@ -21,8 +21,7 @@ import org.apache.any23.rdf.Prefixes;
/**
*
- * It defines a minimal signature for an
- * {@link Extractor} description.
+ * It defines a minimal signature for an {@link Extractor} description.
*
*/
public interface ExtractorDescription {
@@ -40,7 +39,7 @@ public interface ExtractorDescription {
* @return A string label describing the type of extractors created from this factory.
*/
String getExtractorLabel();
-
+
/**
* An instance defining the prefixes supported by this extractor.
*
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractorFactory.java b/api/src/main/java/org/apache/any23/extractor/ExtractorFactory.java
index 6746490..9e71866 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractorFactory.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractorFactory.java
@@ -24,7 +24,8 @@ import java.util.Collection;
/**
* Interface defining a factory for {@link Extractor}.
*
- * @param <T> the type of the {@link Extractor} to be created by this factory.
+ * @param <T>
+ * the type of the {@link Extractor} to be created by this factory.
*/
public interface ExtractorFactory<T extends Extractor<?>> extends ExtractorDescription {
@@ -37,20 +38,19 @@ public interface ExtractorFactory<T extends Extractor<?>> extends ExtractorDescr
/**
* Supports wildcards, e.g. <code>"*/*"</code> for blind extractors that merely call a web service.
+ *
* @return a {@link java.util.Collection} of supported mimetypes.
*/
Collection<MIMEType> getSupportedMIMETypes();
/**
- * An example input file for the extractor, to be used in auto-generated
- * documentation. For the {@link Extractor.BlindExtractor},
- * this is an arbitrary IRI.
- * For extractors that require content, it is the name of a file, relative
- * to the factory's class file's location, it will be opened using
- * factory.getClass().getResourceAsStream(filename). The example should be
- * a short file that produces characteristic output if sent through the
- * extractor. The file will be read as UTF-8, so it should either use that
- * encoding or avoid characters outside of the US-ASCII range.
+ * An example input file for the extractor, to be used in auto-generated documentation. For the
+ * {@link Extractor.BlindExtractor}, this is an arbitrary IRI. For extractors that require content, it is the name
+ * of a file, relative to the factory's class file's location, it will be opened using
+ * factory.getClass().getResourceAsStream(filename). The example should be a short file that produces characteristic
+ * output if sent through the extractor. The file will be read as UTF-8, so it should either use that encoding or
+ * avoid characters outside of the US-ASCII range.
+ *
* @return a string representing sample input for a particular extractor.
*/
String getExampleInput();
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractorGroup.java b/api/src/main/java/org/apache/any23/extractor/ExtractorGroup.java
index 4e77690..c9252f7 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractorGroup.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractorGroup.java
@@ -24,8 +24,7 @@ import java.util.Collection;
import java.util.Iterator;
/**
- * It simple models a group of {@link ExtractorFactory} providing
- * simple accessing methods.
+ * It simple models a group of {@link ExtractorFactory} providing simple accessing methods.
*/
public class ExtractorGroup implements Iterable<ExtractorFactory<?>> {
@@ -44,10 +43,11 @@ public class ExtractorGroup implements Iterable<ExtractorFactory<?>> {
}
/**
- * Returns a {@link ExtractorGroup} with a set of {@link Extractor} able to
- * process the provided mime type.
+ * Returns a {@link ExtractorGroup} with a set of {@link Extractor} able to process the provided mime type.
+ *
+ * @param mimeType
+ * to perform the selection.
*
- * @param mimeType to perform the selection.
* @return an {@link ExtractorGroup} able to process the provided mime type.
*/
public ExtractorGroup filterByMIMEType(MIMEType mimeType) {
@@ -67,8 +67,7 @@ public class ExtractorGroup implements Iterable<ExtractorFactory<?>> {
}
/**
- * @return <code>true</code> if all the {@link Extractor} contained in the group
- * supports all the content types.
+ * @return <code>true</code> if all the {@link Extractor} contained in the group supports all the content types.
*/
public boolean allExtractorsSupportAllContentTypes() {
for (ExtractorFactory<?> factory : factories) {
diff --git a/api/src/main/java/org/apache/any23/extractor/ExtractorRegistry.java b/api/src/main/java/org/apache/any23/extractor/ExtractorRegistry.java
index dea9fca..9391e75 100644
--- a/api/src/main/java/org/apache/any23/extractor/ExtractorRegistry.java
+++ b/api/src/main/java/org/apache/any23/extractor/ExtractorRegistry.java
@@ -20,8 +20,7 @@ package org.apache.any23.extractor;
import java.util.List;
/**
- * An interface to the enable a registry for extractors to be implemented by
- * different implementors of this API.
+ * An interface to the enable a registry for extractors to be implemented by different implementors of this API.
*
* @author Peter Ansell p_ansell@yahoo.com
*/
@@ -30,10 +29,11 @@ public interface ExtractorRegistry {
/**
* Registers an {@link ExtractorFactory}.
*
- * @param factory an {@link ExtractorFactory} to register.
+ * @param factory
+ * an {@link ExtractorFactory} to register.
+ *
* @throws IllegalArgumentException
- * if trying to register a {@link ExtractorFactory} that already
- * exists in the registry.
+ * if trying to register a {@link ExtractorFactory} that already exists in the registry.
*/
void register(ExtractorFactory<?> factory);
@@ -43,26 +43,25 @@ public interface ExtractorRegistry {
*
* @param name
* The name of the desired factory
+ *
* @return The {@link ExtractorFactory} associated to the provided name
+ *
* @throws IllegalArgumentException
- * If there is not an {@link ExtractorFactory} associated to the
- * provided name.
+ * If there is not an {@link ExtractorFactory} associated to the provided name.
*/
ExtractorFactory<?> getFactory(String name);
/**
- * @return An {@link ExtractorGroup} with all the registered
- * {@link Extractor}.
+ * @return An {@link ExtractorGroup} with all the registered {@link Extractor}.
*/
ExtractorGroup getExtractorGroup();
/**
- * Returns an {@link ExtractorGroup} containing the {@link ExtractorFactory}
- * mathing the names provided as input.
+ * Returns an {@link ExtractorGroup} containing the {@link ExtractorFactory} mathing the names provided as input.
*
* @param names
- * A {@link java.util.List} containing the names of the desired
- * {@link ExtractorFactory}.
+ * A {@link java.util.List} containing the names of the desired {@link ExtractorFactory}.
+ *
* @return the extraction group.
*/
ExtractorGroup getExtractorGroup(List<String> names);
@@ -71,13 +70,14 @@ public interface ExtractorRegistry {
*
* @param name
* The name of the {@link ExtractorFactory}
- * @return <code>true</code> if is there a {@link ExtractorFactory}
- * associated to the provided name.
+ *
+ * @return <code>true</code> if is there a {@link ExtractorFactory} associated to the provided name.
*/
boolean isRegisteredName(String name);
/**
* Returns the names of all registered extractors, sorted alphabetically.
+ *
* @return an alphabetically sorted {@link java.util.List}
*/
List<String> getAllNames();
diff --git a/api/src/main/java/org/apache/any23/extractor/IssueReport.java b/api/src/main/java/org/apache/any23/extractor/IssueReport.java
index 6b4a722..63d4393 100644
--- a/api/src/main/java/org/apache/any23/extractor/IssueReport.java
+++ b/api/src/main/java/org/apache/any23/extractor/IssueReport.java
@@ -30,17 +30,22 @@ public interface IssueReport {
/**
* Notifies an issue occurred while performing an extraction on an input stream.
*
- * @param level issue level.
- * @param msg issue message.
- * @param row issue row.
- * @param col issue column.
+ * @param level
+ * issue level.
+ * @param msg
+ * issue message.
+ * @param row
+ * issue row.
+ * @param col
+ * issue column.
*/
void notifyIssue(IssueLevel level, String msg, long row, long col);
/**
* Prints out the content of the report.
*
- * @param ps a {@link java.io.PrintStream} to use for generating the report.
+ * @param ps
+ * a {@link java.io.PrintStream} to use for generating the report.
*/
void printReport(PrintStream ps);
@@ -55,9 +60,7 @@ public interface IssueReport {
* Possible issue levels.
*/
enum IssueLevel {
- WARNING,
- ERROR,
- FATAL
+ WARNING, ERROR, FATAL
}
/**
@@ -66,8 +69,8 @@ public interface IssueReport {
public class Issue {
private IssueLevel level;
- private String message;
- private long row, col;
+ private String message;
+ private long row, col;
Issue(IssueLevel l, String msg, long r, long c) {
level = l;
diff --git a/api/src/main/java/org/apache/any23/mime/MIMEType.java b/api/src/main/java/org/apache/any23/mime/MIMEType.java
index 210cbbb..035b03f 100644
--- a/api/src/main/java/org/apache/any23/mime/MIMEType.java
+++ b/api/src/main/java/org/apache/any23/mime/MIMEType.java
@@ -29,7 +29,7 @@ public class MIMEType implements Comparable<MIMEType> {
private final String type;
private final String subtype;
-
+
private final double q;
private MIMEType(String type, String subtype, double q) {
@@ -39,19 +39,21 @@ public class MIMEType implements Comparable<MIMEType> {
}
/**
- * Parses the given MIME type string returning an instance of
- * {@link MIMEType}.
- * The expected format for <code>mimeType</code> is
- * <code>type/subtype[;q=x.y]</code> .
- * An example of valid mime type is: <code>application/rdf+xml;q=0.9</code>
+ * Parses the given MIME type string returning an instance of {@link MIMEType}. The expected format for
+ * <code>mimeType</code> is <code>type/subtype[;q=x.y]</code> . An example of valid mime type is:
+ * <code>application/rdf+xml;q=0.9</code>
*
- * @param mimeType a provided mimetype string.
+ * @param mimeType
+ * a provided mimetype string.
+ *
* @return the mime type instance.
- * @throws IllegalArgumentException if the <code>mimeType</code> is not well formatted.
+ *
+ * @throws IllegalArgumentException
+ * if the <code>mimeType</code> is not well formatted.
*/
public static MIMEType parse(String mimeType) {
if (mimeType == null) {
- return null;
+ return null;
}
int i = mimeType.indexOf(';');
double q = 1.0;
@@ -60,10 +62,10 @@ public class MIMEType implements Comparable<MIMEType> {
for (String param : params) {
int i2 = param.indexOf('=');
if (i2 == -1) {
- continue;
+ continue;
}
- if (!"q".equals(param.substring(0, i2).trim().toLowerCase(java.util.Locale.ROOT))){
- continue;
+ if (!"q".equals(param.substring(0, i2).trim().toLowerCase(java.util.Locale.ROOT))) {
+ continue;
}
String value = param.substring(i2 + 1);
try {
diff --git a/api/src/main/java/org/apache/any23/mime/MIMETypeDetector.java b/api/src/main/java/org/apache/any23/mime/MIMETypeDetector.java
index 4686be4..8d08dd3 100644
--- a/api/src/main/java/org/apache/any23/mime/MIMETypeDetector.java
+++ b/api/src/main/java/org/apache/any23/mime/MIMETypeDetector.java
@@ -20,17 +20,20 @@ package org.apache.any23.mime;
import java.io.InputStream;
/**
- * This detector is able to estimate the <code>MIME</code> type of
- * some given raw data.
+ * This detector is able to estimate the <code>MIME</code> type of some given raw data.
*/
public interface MIMETypeDetector {
/**
* Estimates the <code>MIME</code> type of the content of input file.
*
- * @param fileName name of the file.
- * @param input content of the file.
- * @param mimeTypeFromMetadata mimetype declared in metadata.
+ * @param fileName
+ * name of the file.
+ * @param input
+ * content of the file.
+ * @param mimeTypeFromMetadata
+ * mimetype declared in metadata.
+ *
* @return the supposed mime type or <code>null</code> if nothing appropriate found.
*/
public MIMEType guessMIMEType(String fileName, InputStream input, MIMEType mimeTypeFromMetadata);
diff --git a/api/src/main/java/org/apache/any23/mime/purifier/Purifier.java b/api/src/main/java/org/apache/any23/mime/purifier/Purifier.java
index 5e072a5..df44b7d 100644
--- a/api/src/main/java/org/apache/any23/mime/purifier/Purifier.java
+++ b/api/src/main/java/org/apache/any23/mime/purifier/Purifier.java
@@ -21,8 +21,7 @@ import java.io.IOException;
import java.io.InputStream;
/**
- * This interface defines a minimum set of methods that
- * a TikaMIMETypeDetector could call in order to clean the input
+ * This interface defines a minimum set of methods that a TikaMIMETypeDetector could call in order to clean the input
* before performing the <i>MIME type</i> detection.
*
* @author Davide Palmisano ( dpalmisano@gmail.com )
@@ -32,8 +31,11 @@ public interface Purifier {
/**
* Performs the purification of the provided resettable {@link java.io.InputStream}.
*
- * @param inputStream a resettable {@link java.io.InputStream} to be cleaned.
- * @throws IOException if there is an error accessing the {@link java.io.InputStream}
+ * @param inputStream
+ * a resettable {@link java.io.InputStream} to be cleaned.
+ *
+ * @throws IOException
+ * if there is an error accessing the {@link java.io.InputStream}
*/
void purify(InputStream inputStream) throws IOException;
diff --git a/api/src/main/java/org/apache/any23/mime/purifier/package-info.java b/api/src/main/java/org/apache/any23/mime/purifier/package-info.java
index d1d7b3a..9c5d114 100644
--- a/api/src/main/java/org/apache/any23/mime/purifier/package-info.java
+++ b/api/src/main/java/org/apache/any23/mime/purifier/package-info.java
@@ -16,8 +16,8 @@
*/
/**
- * This package contains all the logic to implement your own {@link org.apache.any23.mime.purifier.Purifier}.
- * Each {@link org.apache.any23.mime.purifier.Purifier} is responsible for modifying the file <b>before</b>
- * its <i>MIME type</i> is detected.
+ * This package contains all the logic to implement your own {@link org.apache.any23.mime.purifier.Purifier}. Each
+ * {@link org.apache.any23.mime.purifier.Purifier} is responsible for modifying the file <b>before</b> its <i>MIME
+ * type</i> is detected.
*/
package org.apache.any23.mime.purifier;
\ No newline at end of file
diff --git a/api/src/main/java/org/apache/any23/plugin/Any23PluginManager.java b/api/src/main/java/org/apache/any23/plugin/Any23PluginManager.java
index f286874..4b9057e 100644
--- a/api/src/main/java/org/apache/any23/plugin/Any23PluginManager.java
+++ b/api/src/main/java/org/apache/any23/plugin/Any23PluginManager.java
@@ -39,8 +39,7 @@ import java.util.ServiceLoader;
import java.util.Set;
/**
- * The <i>Any23PluginManager</i> is responsible for inspecting
- * dynamically the classpath and retrieving useful classes.
+ * The <i>Any23PluginManager</i> is responsible for inspecting dynamically the classpath and retrieving useful classes.
*
* @author Michele Mostarda (mostarda@fbk.eu)
*/
@@ -93,18 +92,18 @@ public class Any23PluginManager {
/**
* Loads a <i>JAR</i> file in the classpath.
*
- * @param jar the JAR file to be loaded.
- * @return <code>true</code> if the JAR is added for the first time to the classpath,
- * <code>false</code> otherwise.
+ * @param jar
+ * the JAR file to be loaded.
+ *
+ * @return <code>true</code> if the JAR is added for the first time to the classpath, <code>false</code> otherwise.
*/
public synchronized boolean loadJAR(File jar) {
- if(jar == null) {
+ if (jar == null) {
throw new NullPointerException("jar file cannot be null.");
}
if (!jar.isFile() && !jar.exists()) {
- throw new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Invalid JAR [%s], must be an existing file.", jar.getAbsolutePath())
- );
+ throw new IllegalArgumentException(String.format(java.util.Locale.ROOT,
+ "Invalid JAR [%s], must be an existing file.", jar.getAbsolutePath()));
}
return dynamicClassLoader.addJAR(jar);
}
@@ -112,7 +111,9 @@ public class Any23PluginManager {
/**
* Loads a list of <i>JAR</i>s in the classpath.
*
- * @param jars list of JARs to be loaded.
+ * @param jars
+ * list of JARs to be loaded.
+ *
* @return list of exceptions raised during the loading.
*/
public synchronized Throwable[] loadJARs(File... jars) {
@@ -121,12 +122,9 @@ public class Any23PluginManager {
try {
loadJAR(jar);
} catch (Throwable t) {
- result.add(
- new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Error while loading jar [%s]", jar.getAbsolutePath()),
- t
- )
- );
+ result.add(new IllegalArgumentException(
+ String.format(java.util.Locale.ROOT, "Error while loading jar [%s]", jar.getAbsolutePath()),
+ t));
}
}
return result.toArray(new Throwable[result.size()]);
@@ -135,18 +133,19 @@ public class Any23PluginManager {
/**
* Loads a <i>classes</i> directory in the classpath.
*
- * @param classDir the directory to be loaded.
- * @return <code>true</code> if the directory is added for the first time to the classpath,
- * <code>false</code> otherwise.
+ * @param classDir
+ * the directory to be loaded.
+ *
+ * @return <code>true</code> if the directory is added for the first time to the classpath, <code>false</code>
+ * otherwise.
*/
public synchronized boolean loadClassDir(File classDir) {
- if(classDir == null) {
- throw new NullPointerException("classDir cannot be null.");
+ if (classDir == null) {
+ throw new NullPointerException("classDir cannot be null.");
}
if (!classDir.isDirectory() && !classDir.exists()) {
- throw new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Invalid class dir [%s], must be an existing file.", classDir.getAbsolutePath())
- );
+ throw new IllegalArgumentException(String.format(java.util.Locale.ROOT,
+ "Invalid class dir [%s], must be an existing file.", classDir.getAbsolutePath()));
}
return dynamicClassLoader.addClassDir(classDir);
}
@@ -154,8 +153,10 @@ public class Any23PluginManager {
/**
* Loads a list of class dirs in the classpath.
*
- * @param classDirs list of class dirs to be loaded.
- * @return list of exceptions raised during the loading.
+ * @param classDirs
+ * list of class dirs to be loaded.
+ *
+ * @return list of exceptions raised during the loading.
*/
public synchronized Throwable[] loadClassDirs(File... classDirs) {
final List<Throwable> result = new ArrayList<>();
@@ -163,12 +164,8 @@ public class Any23PluginManager {
try {
loadClassDir(classDir);
} catch (Throwable t) {
- result.add(
- new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Error while loading class dir [%s]", classDir.getAbsolutePath()),
- t
- )
- );
+ result.add(new IllegalArgumentException(String.format(java.util.Locale.ROOT,
+ "Error while loading class dir [%s]", classDir.getAbsolutePath()), t));
}
}
return result.toArray(new Throwable[result.size()]);
@@ -177,28 +174,27 @@ public class Any23PluginManager {
/**
* Loads all the JARs detected in a given directory.
*
- * @param jarDir directory containing the JARs to be loaded.
- * Example '/usr/local/apache-tomcat-7.0.72/webapps/apache-any23-service-2.2-SNAPSHOT/WEB-INF/lib/apache-any23-openie'
+ * @param jarDir
+ * directory containing the JARs to be loaded. Example
+ * '/usr/local/apache-tomcat-7.0.72/webapps/apache-any23-service-2.2-SNAPSHOT/WEB-INF/lib/apache-any23-openie'
+ *
* @return <code>true</code> if all JARs in dir are loaded.
*/
public synchronized boolean loadJARDir(File jarDir) {
- if(jarDir == null)
+ if (jarDir == null)
throw new NullPointerException("JAR dir must be not null.");
- if(!jarDir.exists() )
+ if (!jarDir.exists())
throw new IllegalArgumentException("Given directory doesn't exist:" + jarDir.getAbsolutePath());
- if(!jarDir.isDirectory() )
+ if (!jarDir.isDirectory())
throw new IllegalArgumentException(
- "given file exists and it is not a directory: " + jarDir.getAbsolutePath()
- );
+ "given file exists and it is not a directory: " + jarDir.getAbsolutePath());
boolean loaded = true;
- for (File jarFile : jarDir.listFiles(
- new FilenameFilter() {
- @Override
- public boolean accept(File dir, String name) {
- return name.endsWith(".jar");
- }
- })
- ) {
+ for (File jarFile : jarDir.listFiles(new FilenameFilter() {
+ @Override
+ public boolean accept(File dir, String name) {
+ return name.endsWith(".jar");
+ }
+ })) {
loaded &= loadJAR(jarFile);
}
return loaded;
@@ -207,12 +203,14 @@ public class Any23PluginManager {
/**
* Loads a generic list of files, trying to determine the type of every file.
*
- * @param files list of files to be loaded.
+ * @param files
+ * list of files to be loaded.
+ *
* @return list of errors occurred during loading.
*/
public synchronized Throwable[] loadFiles(File... files) {
final List<Throwable> errors = new ArrayList<>();
- for(File file : files) {
+ for (File file : files) {
try {
if (file.isFile() && file.getName().endsWith(".jar")) {
loadJAR(file);
@@ -233,17 +231,21 @@ public class Any23PluginManager {
}
/**
- * Returns all classes within the specified <code>packageName</code> satisfying the given class
- * <code>filter</code>. The search is performed on the static classpath (the one the application
- * started with) and the dynamic classpath (the one specified using the load methods).
+ * Returns all classes within the specified <code>packageName</code> satisfying the given class <code>filter</code>.
+ * The search is performed on the static classpath (the one the application started with) and the dynamic classpath
+ * (the one specified using the load methods).
*
- * @param <T> type of filtered class.
- * @param type of filtered class.
+ * @param <T>
+ * type of filtered class.
+ * @param type
+ * of filtered class.
+ *
* @return list of matching classes.
- * @throws IOException if there is an error obtaining plugins.
+ *
+ * @throws IOException
+ * if there is an error obtaining plugins.
*/
- public synchronized <T> Iterator<T> getPlugins(final Class<T> type)
- throws IOException {
+ public synchronized <T> Iterator<T> getPlugins(final Class<T> type) throws IOException {
return ServiceLoader.load(type, dynamicClassLoader).iterator();
}
@@ -251,8 +253,9 @@ public class Any23PluginManager {
* Returns the list of all the {@link Tool} classes declared within the classpath.
*
* @return not <code>null</code> list of tool classes.
- * @throws IOException if there is an error obtaining {@link org.apache.any23.cli.Tool}'s
- * from the classpath.
+ *
+ * @throws IOException
+ * if there is an error obtaining {@link org.apache.any23.cli.Tool}'s from the classpath.
*/
public synchronized Iterator<Tool> getTools() throws IOException {
return getPlugins(Tool.class);
@@ -262,7 +265,9 @@ public class Any23PluginManager {
* List of {@link ExtractorPlugin} classes declared within the classpath.
*
* @return not <code>null</code> list of plugin classes.
- * @throws IOException if there is an error obtaining Extractors.
+ *
+ * @throws IOException
+ * if there is an error obtaining Extractors.
*/
@SuppressWarnings("rawtypes")
public synchronized Iterator<ExtractorFactory> getExtractors() throws IOException {
@@ -272,7 +277,9 @@ public class Any23PluginManager {
/**
* Loads plugins from a list of specified locations.
*
- * @param pluginLocations list of locations.
+ * @param pluginLocations
+ * list of locations.
+ *
* @return a report about the loaded plugins.
*/
public synchronized String loadPlugins(File... pluginLocations) {
@@ -296,18 +303,23 @@ public class Any23PluginManager {
}
/**
- * Configures a new list of extractors containing the extractors declared in <code>initialExtractorGroup</code>
- * and also the extractors detected in classpath specified by <code>pluginLocations</code>.
- *
- * @param pluginLocations path locations of plugins.
- * @return full list of extractors.
- * @throws java.io.IOException if there is an error locating the plugin(s).
- * @throws IllegalAccessException if there are access permissions for plugin(s).
- * @throws InstantiationException if there is an error instantiating plugin(s).
- */
- public synchronized ExtractorGroup configureExtractors(
- final File... pluginLocations
- ) throws IOException, IllegalAccessException, InstantiationException {
+ * Configures a new list of extractors containing the extractors declared in <code>initialExtractorGroup</code> and
+ * also the extractors detected in classpath specified by <code>pluginLocations</code>.
+ *
+ * @param pluginLocations
+ * path locations of plugins.
+ *
+ * @return full list of extractors.
+ *
+ * @throws java.io.IOException
+ * if there is an error locating the plugin(s).
+ * @throws IllegalAccessException
+ * if there are access permissions for plugin(s).
+ * @throws InstantiationException
+ * if there is an error instantiating plugin(s).
+ */
+ public synchronized ExtractorGroup configureExtractors(final File... pluginLocations)
+ throws IOException, IllegalAccessException, InstantiationException {
final String pluginsReport = loadPlugins(pluginLocations);
logger.info(pluginsReport);
@@ -336,17 +348,23 @@ public class Any23PluginManager {
}
/**
- * Configures a new list of extractors containing the extractors declared in <code>initialExtractorGroup</code>
- * and also the extractors detected in classpath specified by the default configuration.
+ * Configures a new list of extractors containing the extractors declared in <code>initialExtractorGroup</code> and
+ * also the extractors detected in classpath specified by the default configuration.
*
- * @param initialExtractorGroup initial list of extractors.
+ * @param initialExtractorGroup
+ * initial list of extractors.
+ *
* @return full list of extractors.
- * @throws java.io.IOException if there is an error locating the extractor(s).
- * @throws IllegalAccessException if there are access permissions for extractor(s).
- * @throws InstantiationException if there is an error instantiating extractor(s).
+ *
+ * @throws java.io.IOException
+ * if there is an error locating the extractor(s).
+ * @throws IllegalAccessException
+ * if there are access permissions for extractor(s).
+ * @throws InstantiationException
+ * if there is an error instantiating extractor(s).
*/
public synchronized ExtractorGroup configureExtractors(ExtractorGroup initialExtractorGroup)
- throws IOException, InstantiationException, IllegalAccessException {
+ throws IOException, InstantiationException, IllegalAccessException {
final String pluginDirs = DefaultConfiguration.singleton().getPropertyOrFail(PLUGIN_DIRS_PROPERTY);
final File[] pluginLocations = getPluginLocations(pluginDirs);
return configureExtractors(pluginLocations);
@@ -355,25 +373,36 @@ public class Any23PluginManager {
/**
* Returns an extractor group containing both the default extractors declared by the
* {@link org.apache.any23.extractor.ExtractorRegistry} and the {@link ExtractorPlugin}s.
- * @param registry an {@link org.apache.any23.extractor.ExtractorRegistry}
- * @param pluginLocations optional list of plugin locations.
+ *
+ * @param registry
+ * an {@link org.apache.any23.extractor.ExtractorRegistry}
+ * @param pluginLocations
+ * optional list of plugin locations.
*
* @return a not <code>null</code> and not empty extractor group.
- * @throws java.io.IOException if there is an error locating the extractor group.
- * @throws IllegalAccessException if there are access permissions for the extractor group.
- * @throws InstantiationException if there is an error instantiating the extractor group.
+ *
+ * @throws java.io.IOException
+ * if there is an error locating the extractor group.
+ * @throws IllegalAccessException
+ * if there are access permissions for the extractor group.
+ * @throws InstantiationException
+ * if there is an error instantiating the extractor group.
*/
public synchronized ExtractorGroup getApplicableExtractors(ExtractorRegistry registry, File... pluginLocations)
- throws IOException, IllegalAccessException, InstantiationException {
+ throws IOException, IllegalAccessException, InstantiationException {
return configureExtractors(pluginLocations);
}
/**
* Returns an {@link Iterator} of tools that have been detected within the given list of locations.
*
- * @param pluginLocations list of plugin locations.
+ * @param pluginLocations
+ * list of plugin locations.
+ *
* @return set of detected tools.
- * @throws IOException if there is an error acessing {@link org.apache.any23.cli.Tool}'s.
+ *
+ * @throws IOException
+ * if there is an error acessing {@link org.apache.any23.cli.Tool}'s.
*/
public synchronized Iterator<Tool> getApplicableTools(File... pluginLocations) throws IOException {
final String report = loadPlugins(pluginLocations);
@@ -385,17 +414,17 @@ public class Any23PluginManager {
* Converts a column separated list of dirs in a list of files.
*
* @param pluginDirsList
+ *
* @return
*/
private File[] getPluginLocations(String pluginDirsList) {
final String[] locationsStr = pluginDirsList.split(PLUGIN_DIRS_LIST_SEPARATOR);
final List<File> locations = new ArrayList<>();
- for(String locationStr : locationsStr) {
+ for (String locationStr : locationsStr) {
final File location = new File(locationStr);
- if( ! location.exists()) {
+ if (!location.exists()) {
throw new IllegalArgumentException(
- String.format(java.util.Locale.ROOT, "Plugin location '%s' cannot be found.", locationStr)
- );
+ String.format(java.util.Locale.ROOT, "Plugin location '%s' cannot be found.", locationStr));
}
locations.add(location);
}
@@ -426,7 +455,7 @@ public class Any23PluginManager {
public boolean addClassDir(File classDir) {
final String urlPath = "file://" + classDir.getAbsolutePath() + "/";
try {
- if( addURL(urlPath) ) {
+ if (addURL(urlPath)) {
dirs.add(classDir);
return true;
}
@@ -450,7 +479,7 @@ public class Any23PluginManager {
}
private boolean addURL(String urlPath) throws MalformedURLException {
- if(addedURLs.contains(urlPath)) {
+ if (addedURLs.contains(urlPath)) {
return false;
}
super.addURL(new URL(urlPath));
diff --git a/api/src/main/java/org/apache/any23/plugin/ExtractorPlugin.java b/api/src/main/java/org/apache/any23/plugin/ExtractorPlugin.java
index 2620454..f998487 100644
--- a/api/src/main/java/org/apache/any23/plugin/ExtractorPlugin.java
+++ b/api/src/main/java/org/apache/any23/plugin/ExtractorPlugin.java
@@ -21,17 +21,16 @@ import org.apache.any23.extractor.Extractor;
import org.apache.any23.extractor.ExtractorFactory;
/**
- * This interface defines an Any23 extractor plugin that can be
- * detected and registered from the library classpath.
+ * This interface defines an Any23 extractor plugin that can be detected and registered from the library classpath.
*
* @author Michele Mostarda (mostarda@fbk.eu)
- * @deprecated ExtractorFactory now supports
- * <a href="https://docs.oracle.com/javase/8/docs/api/java/util/ServiceLoader.html">
- * META-INF/services</a> discovery via the {@link java.util.ServiceLoader},
- * deprecating this class.
*
- * Instead implement a subinterface of {@link org.apache.any23.extractor.Extractor} and
- * ensure that your plugin is in compliance with the META-INF/services mechanism.
+ * @deprecated ExtractorFactory now supports
+ * <a href="https://docs.oracle.com/javase/8/docs/api/java/util/ServiceLoader.html"> META-INF/services</a>
+ * discovery via the {@link java.util.ServiceLoader}, deprecating this class.
+ *
+ * Instead implement a subinterface of {@link org.apache.any23.extractor.Extractor} and ensure that your
+ * plugin is in compliance with the META-INF/services mechanism.
*/
@Deprecated
public interface ExtractorPlugin<T extends Extractor<?>> {
diff --git a/api/src/main/java/org/apache/any23/rdf/Prefixes.java b/api/src/main/java/org/apache/any23/rdf/Prefixes.java
index 706dc69..1027870 100644
--- a/api/src/main/java/org/apache/any23/rdf/Prefixes.java
+++ b/api/src/main/java/org/apache/any23/rdf/Prefixes.java
@@ -28,12 +28,10 @@ import java.util.Map.Entry;
import java.util.Set;
/**
- * A mapping from prefixes to namespace IRIs. Supports "volatile mappings",
- * which will be overwritten without notice when mappings are merged,
- * while for normal mappings this causes an exception. This allows
- * combining "hard" mappings (which must be retained or something breaks)
- * and "soft" mappings (which might be read from input RDF files and
- * should be retained only if they are not in conflict with the hard ones).
+ * A mapping from prefixes to namespace IRIs. Supports "volatile mappings", which will be overwritten without notice
+ * when mappings are merged, while for normal mappings this causes an exception. This allows combining "hard" mappings
+ * (which must be retained or something breaks) and "soft" mappings (which might be read from input RDF files and should
+ * be retained only if they are not in conflict with the hard ones).
*
* @author Richard Cyganiak (richard@cyganiak.de)
*/
@@ -57,7 +55,7 @@ public class Prefixes {
return result;
}
- public static Prefixes EMPTY = new Prefixes(Collections.<String, String>emptyMap());
+ public static Prefixes EMPTY = new Prefixes(Collections.<String, String> emptyMap());
private final Map<String, String> mappings;
private final Set<String> volatilePrefixes = new HashSet<String>();
@@ -80,15 +78,13 @@ public class Prefixes {
if (prefix == null || !hasPrefix(prefix)) {
return null;
}
- return SimpleValueFactory.getInstance().createIRI(
- getNamespaceIRIFor(prefix) + parseLocalName(curie));
+ return SimpleValueFactory.getInstance().createIRI(getNamespaceIRIFor(prefix) + parseLocalName(curie));
}
public String abbreviate(String uri) {
for (Entry<String, String> namespace : mappings.entrySet()) {
if (uri.startsWith(namespace.getValue())) {
- return namespace.getKey() + ":" +
- uri.substring(namespace.getValue().length());
+ return namespace.getKey() + ":" + uri.substring(namespace.getValue().length());
}
}
return null;
@@ -134,11 +130,10 @@ public class Prefixes {
} else {
if (hasPrefix(prefix)) {
if (getNamespaceIRIFor(prefix).equals(namespaceIRI)) {
- return; // re-assigned same prefix to same IRI, let's just ignore it
+ return; // re-assigned same prefix to same IRI, let's just ignore it
}
- throw new IllegalStateException("Attempted to re-assign prefix '" + prefix +
- "'; clashing values '" + getNamespaceIRIFor(prefix) + "' and '" +
- namespaceIRI);
+ throw new IllegalStateException("Attempted to re-assign prefix '" + prefix + "'; clashing values '"
+ + getNamespaceIRIFor(prefix) + "' and '" + namespaceIRI);
}
}
mappings.put(prefix, namespaceIRI);
@@ -172,7 +167,7 @@ public class Prefixes {
public void addVolatile(String prefix, String namespaceIRI) {
if (hasPrefix(prefix)) {
- return; // new prefix is volatile, so we don't overwrite the old one
+ return; // new prefix is volatile, so we don't overwrite the old one
}
mappings.put(prefix, namespaceIRI);
volatilePrefixes.add(prefix);
@@ -213,5 +208,5 @@ public class Prefixes {
}
return curie.substring(index + 1);
}
-
+
}
diff --git a/api/src/main/java/org/apache/any23/source/DocumentSource.java b/api/src/main/java/org/apache/any23/source/DocumentSource.java
index 9980da8..5672f3b 100644
--- a/api/src/main/java/org/apache/any23/source/DocumentSource.java
+++ b/api/src/main/java/org/apache/any23/source/DocumentSource.java
@@ -21,9 +21,7 @@ import java.io.IOException;
import java.io.InputStream;
/**
- * A source of input streams. Mostly intended for
- * situations where opening of an input stream is
- * to be delayed.
+ * A source of input streams. Mostly intended for situations where opening of an input stream is to be delayed.
*
* @author Richard Cyganiak (richard@cyganiak.de)
*/
@@ -33,8 +31,10 @@ public interface DocumentSource {
* Returns the input stream for accessing the content of the document.
*
* @return not <code>null</code> input stream for accessing document data.
- * @throws IOException if there is an error opening the
- * {@link org.apache.any23.source.DocumentSource} {@link java.io.InputStream}
+ *
+ * @throws IOException
+ * if there is an error opening the {@link org.apache.any23.source.DocumentSource}
+ * {@link java.io.InputStream}
*/
InputStream openInputStream() throws IOException;
@@ -54,13 +54,11 @@ public interface DocumentSource {
public String getDocumentIRI();
/**
- * A value of <i>false</i> indicates that the document
- * resides remotely, and that multiple successive accesses
- * to it should be avoided by copying it to local storage.
- * This can also be used for sources that do not support
- * multiple calls to {@link #openInputStream()}.
- * @return true if the {@link org.apache.any23.source.DocumentSource} is
- * cached locally.
+ * A value of <i>false</i> indicates that the document resides remotely, and that multiple successive accesses to it
+ * should be avoided by copying it to local storage. This can also be used for sources that do not support multiple
+ * calls to {@link #openInputStream()}.
+ *
+ * @return true if the {@link org.apache.any23.source.DocumentSource} is cached locally.
*/
public boolean isLocal();
}
diff --git a/api/src/main/java/org/apache/any23/vocab/CSV.java b/api/src/main/java/org/apache/any23/vocab/CSV.java
index c8ecfe7..6059762 100644
--- a/api/src/main/java/org/apache/any23/vocab/CSV.java
+++ b/api/src/main/java/org/apache/any23/vocab/CSV.java
@@ -20,8 +20,8 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * This vocabulary models the structure of a <i>CSV</i> file
- * according the <a href="http://www.ietf.org/rfc/rfc4180.txt">RFC 4180</a>.
+ * This vocabulary models the structure of a <i>CSV</i> file according the
+ * <a href="http://www.ietf.org/rfc/rfc4180.txt">RFC 4180</a>.
*
* @author Davide Palmisano (dpalmisano@gmail.com)
*/
@@ -29,19 +29,18 @@ public class CSV extends Vocabulary {
public static final String ROW = "row";
- public static final String ROW_POSITION= "rowPosition";
+ public static final String ROW_POSITION = "rowPosition";
public static final String NUMBER_OF_ROWS = "numberOfRows";
public static final String NUMBER_OF_COLUMNS = "numberOfColumns";
- public static final String COLUMN_POSITION= "columnPosition";
+ public static final String COLUMN_POSITION = "columnPosition";
public static final String ROW_TYPE = "Row";
/**
- * This property links the identifier of a <i>CSV</i> to an entity representing
- * a row.
+ * This property links the identifier of a <i>CSV</i> to an entity representing a row.
*/
public final IRI row = createProperty(ROW);
@@ -78,7 +77,7 @@ public class CSV extends Vocabulary {
private static CSV instance;
private CSV() {
- super(NS);
+ super(NS);
}
public static CSV getInstance() {
@@ -94,7 +93,9 @@ public class CSV extends Vocabulary {
/**
*
- * @param localName name to assign to namespace.
+ * @param localName
+ * name to assign to namespace.
+ *
* @return the new URI instance.
*/
public IRI createProperty(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/DCTerms.java b/api/src/main/java/org/apache/any23/vocab/DCTerms.java
index eff8cfe..46843d8 100644
--- a/api/src/main/java/org/apache/any23/vocab/DCTerms.java
+++ b/api/src/main/java/org/apache/any23/vocab/DCTerms.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <i>DCTERMS</i> vocabulary.
- * See <a href="http://dublincore.org/">Dublin Core</a>.
+ * The <i>DCTERMS</i> vocabulary. See <a href="http://dublincore.org/">Dublin Core</a>.
*/
public class DCTerms extends Vocabulary {
@@ -29,20 +28,20 @@ public class DCTerms extends Vocabulary {
// Properties
public final IRI license = createProperty(NS, "license");
- public final IRI title = createProperty(NS, "title" );
+ public final IRI title = createProperty(NS, "title");
public final IRI creator = createProperty(NS, "creator");
public final IRI related = createProperty(NS, "related");
- public final IRI date = createProperty(NS, "date" );
- public final IRI source = createProperty(NS, "source" );
+ public final IRI date = createProperty(NS, "date");
+ public final IRI source = createProperty(NS, "source");
- private DCTerms(){
- super(NS);
+ private DCTerms() {
+ super(NS);
}
- private static DCTerms instance;
+ private static DCTerms instance;
public static DCTerms getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new DCTerms();
}
return instance;
diff --git a/api/src/main/java/org/apache/any23/vocab/DOAC.java b/api/src/main/java/org/apache/any23/vocab/DOAC.java
index fcb00c4..3d8a505 100644
--- a/api/src/main/java/org/apache/any23/vocab/DOAC.java
+++ b/api/src/main/java/org/apache/any23/vocab/DOAC.java
@@ -29,50 +29,50 @@ public class DOAC extends Vocabulary {
private static DOAC instance;
public static DOAC getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new DOAC();
}
return instance;
}
// Properties.
- public final IRI summary = createProperty(NS, "summary");
- public final IRI end_date = createProperty(NS, "end-date");
- public final IRI publication = createProperty(NS, "publication");
- public final IRI title = createProperty(NS, "title");
- public final IRI reference = createProperty(NS, "reference");
- public final IRI language = createProperty(NS, "language");
- public final IRI experience = createProperty(NS, "experience");
- public final IRI organization = createProperty(NS, "organization");
- public final IRI affiliation = createProperty(NS, "affiliation");
- public final IRI writes = createProperty(NS, "writes");
- public final IRI start_date = createProperty(NS, "start-date");
- public final IRI education = createProperty(NS, "education");
- public final IRI skill = createProperty(NS, "skill");
- public final IRI referer = createProperty(NS, "referer");
- public final IRI isco88_code = createProperty(NS, "isco88-code");
- public final IRI speaks = createProperty(NS, "speaks");
- public final IRI reads = createProperty(NS, "reads");
- public final IRI reference_type = createProperty(NS, "reference-type");
+ public final IRI summary = createProperty(NS, "summary");
+ public final IRI end_date = createProperty(NS, "end-date");
+ public final IRI publication = createProperty(NS, "publication");
+ public final IRI title = createProperty(NS, "title");
+ public final IRI reference = createProperty(NS, "reference");
+ public final IRI language = createProperty(NS, "language");
+ public final IRI experience = createProperty(NS, "experience");
+ public final IRI organization = createProperty(NS, "organization");
+ public final IRI affiliation = createProperty(NS, "affiliation");
+ public final IRI writes = createProperty(NS, "writes");
+ public final IRI start_date = createProperty(NS, "start-date");
+ public final IRI education = createProperty(NS, "education");
+ public final IRI skill = createProperty(NS, "skill");
+ public final IRI referer = createProperty(NS, "referer");
+ public final IRI isco88_code = createProperty(NS, "isco88-code");
+ public final IRI speaks = createProperty(NS, "speaks");
+ public final IRI reads = createProperty(NS, "reads");
+ public final IRI reference_type = createProperty(NS, "reference-type");
// Resources.
- public final IRI Publication = createClass(NS, "Publication");
- public final IRI Education = createClass(NS, "Education");
+ public final IRI Publication = createClass(NS, "Publication");
+ public final IRI Education = createClass(NS, "Education");
public final IRI OrganisationalSkill = createClass(NS, "OrganisationalSkill");
- public final IRI PrimarySchool = createClass(NS, "PrimarySchool");
- public final IRI Reference = createClass(NS, "Reference");
- public final IRI DrivingSkill = createClass(NS, "DrivingSkill");
- public final IRI Degree = createClass(NS, "Degree");
- public final IRI LanguageSkill = createClass(NS, "LanguageSkill");
- public final IRI Skill = createClass(NS, "Skill");
- public final IRI SecondarySchool = createClass(NS, "SecondarySchool");
- public final IRI Course = createClass(NS, "Course");
- public final IRI Experience = createClass(NS, "Experience");
- public final IRI SocialSkill = createClass(NS, "SocialSkill");
- public final IRI ComputerSkill = createClass(NS, "ComputerSkill");
- public final IRI LanguageLevel = createClass(NS, "LanguageLevel");
+ public final IRI PrimarySchool = createClass(NS, "PrimarySchool");
+ public final IRI Reference = createClass(NS, "Reference");
+ public final IRI DrivingSkill = createClass(NS, "DrivingSkill");
+ public final IRI Degree = createClass(NS, "Degree");
+ public final IRI LanguageSkill = createClass(NS, "LanguageSkill");
+ public final IRI Skill = createClass(NS, "Skill");
+ public final IRI SecondarySchool = createClass(NS, "SecondarySchool");
+ public final IRI Course = createClass(NS, "Course");
+ public final IRI Experience = createClass(NS, "Experience");
+ public final IRI SocialSkill = createClass(NS, "SocialSkill");
+ public final IRI ComputerSkill = createClass(NS, "ComputerSkill");
+ public final IRI LanguageLevel = createClass(NS, "LanguageLevel");
- private DOAC(){
+ private DOAC() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/DOAP.java b/api/src/main/java/org/apache/any23/vocab/DOAP.java
index 485ca15..672803b 100644
--- a/api/src/main/java/org/apache/any23/vocab/DOAP.java
+++ b/api/src/main/java/org/apache/any23/vocab/DOAP.java
@@ -28,68 +28,68 @@ public class DOAP extends Vocabulary {
public static final String NS = "http://usefulinc.com/ns/doap#";
private static DOAP instance;
-
+
public static DOAP getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new DOAP();
}
return instance;
}
-
- //Resources
- public final IRI Project = createClass(NS, "Project");
- public final IRI Version = createClass(NS, "Version");
- public final IRI Specification = createClass(NS, "Specification");
- public final IRI Repository = createClass(NS, "Repository");
- public final IRI SVNRepository = createClass(NS, "SVNRepository");
- public final IRI BKRepository = createClass(NS, "BKRepository");
- public final IRI CVSRepository = createClass(NS, "CVSRepository");
- public final IRI ArchRepository = createClass(NS, "ArchRepository");
- public final IRI BazaarBranch = createClass(NS, "BazaarBranch");
- public final IRI GitRepository = createClass(NS, "GitRepository");
- public final IRI HgRepository = createClass(NS, "HgRepository");
- public final IRI DarcsRepository = createClass(NS, "DarcsRepository");
-
- //Properties
- public final IRI name = createProperty(NS, "name");
- public final IRI homepage = createProperty(NS, "homepage");
- public final IRI old_homepage = createProperty(NS, "old-homepage");
- public final IRI created = createProperty(NS, "created");
- public final IRI shortdesc = createProperty(NS, "shortdesc");
- public final IRI description = createProperty(NS, "description");
- public final IRI release = createProperty(NS, "release");
- public final IRI mailing_list = createProperty(NS, "mailing-list");
- public final IRI category = createProperty(NS, "category");
- public final IRI license = createProperty(NS, "license");
- public final IRI repository = createProperty(NS, "repository");
- public final IRI anon_root = createProperty(NS, "anon-root");
- public final IRI browse = createProperty(NS, "browse");
- public final IRI module = createProperty(NS, "module");
- public final IRI location = createProperty(NS, "location");
- public final IRI download_page = createProperty(NS, "download-page");
- public final IRI download_mirror = createProperty(NS, "download-mirror");
- public final IRI revision = createProperty(NS, "revision");
- public final IRI file_release = createProperty(NS, "file-release");
- public final IRI wiki = createProperty(NS, "wiki");
- public final IRI bug_database = createProperty(NS, "bug-database");
- public final IRI screenshots = createProperty(NS, "screenshots");
- public final IRI maintainer = createProperty(NS, "maintainer");
- public final IRI developer = createProperty(NS, "developer");
- public final IRI documenter = createProperty(NS, "documenter");
- public final IRI translator = createProperty(NS, "translator");
- public final IRI tester = createProperty(NS, "tester");
- public final IRI helper = createProperty(NS, "helper");
- public final IRI programming_language = createProperty(NS, "programming-language");
- public final IRI os = createProperty(NS, "os");
- public final IRI implement = createProperty(NS, "implement");
- public final IRI service_endpoint = createProperty(NS, "service-endpoint");
- public final IRI language = createProperty(NS, "language");
- public final IRI vendor = createProperty(NS, "vendor");
- public final IRI platform = createProperty(NS, "platform");
- public final IRI audience = createProperty(NS, "audience");
- public final IRI blog = createProperty(NS, "blog");
- private DOAP(){
+ // Resources
+ public final IRI Project = createClass(NS, "Project");
+ public final IRI Version = createClass(NS, "Version");
+ public final IRI Specification = createClass(NS, "Specification");
+ public final IRI Repository = createClass(NS, "Repository");
+ public final IRI SVNRepository = createClass(NS, "SVNRepository");
+ public final IRI BKRepository = createClass(NS, "BKRepository");
+ public final IRI CVSRepository = createClass(NS, "CVSRepository");
+ public final IRI ArchRepository = createClass(NS, "ArchRepository");
+ public final IRI BazaarBranch = createClass(NS, "BazaarBranch");
+ public final IRI GitRepository = createClass(NS, "GitRepository");
+ public final IRI HgRepository = createClass(NS, "HgRepository");
+ public final IRI DarcsRepository = createClass(NS, "DarcsRepository");
+
+ // Properties
+ public final IRI name = createProperty(NS, "name");
+ public final IRI homepage = createProperty(NS, "homepage");
+ public final IRI old_homepage = createProperty(NS, "old-homepage");
+ public final IRI created = createProperty(NS, "created");
+ public final IRI shortdesc = createProperty(NS, "shortdesc");
+ public final IRI description = createProperty(NS, "description");
+ public final IRI release = createProperty(NS, "release");
+ public final IRI mailing_list = createProperty(NS, "mailing-list");
+ public final IRI category = createProperty(NS, "category");
+ public final IRI license = createProperty(NS, "license");
+ public final IRI repository = createProperty(NS, "repository");
+ public final IRI anon_root = createProperty(NS, "anon-root");
+ public final IRI browse = createProperty(NS, "browse");
+ public final IRI module = createProperty(NS, "module");
+ public final IRI location = createProperty(NS, "location");
+ public final IRI download_page = createProperty(NS, "download-page");
+ public final IRI download_mirror = createProperty(NS, "download-mirror");
+ public final IRI revision = createProperty(NS, "revision");
+ public final IRI file_release = createProperty(NS, "file-release");
+ public final IRI wiki = createProperty(NS, "wiki");
+ public final IRI bug_database = createProperty(NS, "bug-database");
+ public final IRI screenshots = createProperty(NS, "screenshots");
+ public final IRI maintainer = createProperty(NS, "maintainer");
+ public final IRI developer = createProperty(NS, "developer");
+ public final IRI documenter = createProperty(NS, "documenter");
+ public final IRI translator = createProperty(NS, "translator");
+ public final IRI tester = createProperty(NS, "tester");
+ public final IRI helper = createProperty(NS, "helper");
+ public final IRI programming_language = createProperty(NS, "programming-language");
+ public final IRI os = createProperty(NS, "os");
+ public final IRI implement = createProperty(NS, "implement");
+ public final IRI service_endpoint = createProperty(NS, "service-endpoint");
+ public final IRI language = createProperty(NS, "language");
+ public final IRI vendor = createProperty(NS, "vendor");
+ public final IRI platform = createProperty(NS, "platform");
+ public final IRI audience = createProperty(NS, "audience");
+ public final IRI blog = createProperty(NS, "blog");
+
+ private DOAP() {
super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/FOAF.java b/api/src/main/java/org/apache/any23/vocab/FOAF.java
index 6162923..287b4d4 100644
--- a/api/src/main/java/org/apache/any23/vocab/FOAF.java
+++ b/api/src/main/java/org/apache/any23/vocab/FOAF.java
@@ -29,83 +29,83 @@ public class FOAF extends Vocabulary {
private static FOAF instance;
public static FOAF getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new FOAF();
}
return instance;
}
// Properties.
- public final IRI topic_interest = createProperty(NS, "topic_interest");
- public final IRI phone = createProperty(NS, "phone");
- public final IRI icqChatID = createProperty(NS, "icqChatID");
- public final IRI yahooChatID = createProperty(NS, "yahooChatID");
- public final IRI member = createProperty(NS, "member");
- public final IRI givenname = createProperty(NS, "givenname");
- public final IRI birthday = createProperty(NS, "birthday");
- public final IRI img = createProperty(NS, "img");
- public final IRI name = createProperty(NS, "name");
- public final IRI maker = createProperty(NS, "maker");
- public final IRI tipjar = createProperty(NS, "tipjar");
- public final IRI membershipClass = createProperty(NS, "membershipClass");
- public final IRI accountName = createProperty(NS, "accountName");
- public final IRI mbox_sha1sum = createProperty(NS, "mbox_sha1sum");
- public final IRI geekcode = createProperty(NS, "geekcode");
- public final IRI interest = createProperty(NS, "interest");
- public final IRI depicts = createProperty(NS, "depicts");
- public final IRI knows = createProperty(NS, "knows");
- public final IRI homepage = createProperty(NS, "homepage");
- public final IRI firstName = createProperty(NS, "firstName");
- public final IRI surname = createProperty(NS, "surname");
- public final IRI isPrimaryTopicOf = createProperty(NS, "isPrimaryTopicOf");
- public final IRI page = createProperty(NS, "page");
- public final IRI accountServiceHomepage = createProperty(NS, "accountServiceHomepage");
- public final IRI depiction = createProperty(NS, "depiction");
- public final IRI fundedBy = createProperty(NS, "fundedBy");
- public final IRI title = createProperty(NS, "title");
- public final IRI weblog = createProperty(NS, "weblog");
- public final IRI logo = createProperty(NS, "logo");
- public final IRI workplaceHomepage = createProperty(NS, "workplaceHomepage");
- public final IRI based_near = createProperty(NS, "based_near");
- public final IRI thumbnail = createProperty(NS, "thumbnail");
- public final IRI primaryTopic = createProperty(NS, "primaryTopic");
- public final IRI aimChatID = createProperty(NS, "aimChatID");
- public final IRI made = createProperty(NS, "made");
- public final IRI workInfoHomepage = createProperty(NS, "workInfoHomepage");
- public final IRI currentProject = createProperty(NS, "currentProject");
- public final IRI holdsAccount = createProperty(NS, "holdsAccount");
- public final IRI publications = createProperty(NS, "publications");
- public final IRI sha1 = createProperty(NS, "sha1");
- public final IRI gender = createProperty(NS, "gender");
- public final IRI mbox = createProperty(NS, "mbox");
- public final IRI myersBriggs = createProperty(NS, "myersBriggs");
- public final IRI plan = createProperty(NS, "plan");
- public final IRI pastProject = createProperty(NS, "pastProject");
- public final IRI schoolHomepage = createProperty(NS, "schoolHomepage");
- public final IRI family_name = createProperty(NS, "family_name");
- public final IRI msnChatID = createProperty(NS, "msnChatID");
- public final IRI theme = createProperty(NS, "theme");
- public final IRI topic = createProperty(NS, "topic");
- public final IRI dnaChecksum = createProperty(NS, "dnaChecksum");
- public final IRI nick = createProperty(NS, "nick");
- public final IRI jabberID = createProperty(NS, "jabberID");
+ public final IRI topic_interest = createProperty(NS, "topic_interest");
+ public final IRI phone = createProperty(NS, "phone");
+ public final IRI icqChatID = createProperty(NS, "icqChatID");
+ public final IRI yahooChatID = createProperty(NS, "yahooChatID");
+ public final IRI member = createProperty(NS, "member");
+ public final IRI givenname = createProperty(NS, "givenname");
+ public final IRI birthday = createProperty(NS, "birthday");
+ public final IRI img = createProperty(NS, "img");
+ public final IRI name = createProperty(NS, "name");
+ public final IRI maker = createProperty(NS, "maker");
+ public final IRI tipjar = createProperty(NS, "tipjar");
+ public final IRI membershipClass = createProperty(NS, "membershipClass");
+ public final IRI accountName = createProperty(NS, "accountName");
+ public final IRI mbox_sha1sum = createProperty(NS, "mbox_sha1sum");
+ public final IRI geekcode = createProperty(NS, "geekcode");
+ public final IRI interest = createProperty(NS, "interest");
+ public final IRI depicts = createProperty(NS, "depicts");
+ public final IRI knows = createProperty(NS, "knows");
+ public final IRI homepage = createProperty(NS, "homepage");
+ public final IRI firstName = createProperty(NS, "firstName");
+ public final IRI surname = createProperty(NS, "surname");
+ public final IRI isPrimaryTopicOf = createProperty(NS, "isPrimaryTopicOf");
+ public final IRI page = createProperty(NS, "page");
+ public final IRI accountServiceHomepage = createProperty(NS, "accountServiceHomepage");
+ public final IRI depiction = createProperty(NS, "depiction");
+ public final IRI fundedBy = createProperty(NS, "fundedBy");
+ public final IRI title = createProperty(NS, "title");
+ public final IRI weblog = createProperty(NS, "weblog");
+ public final IRI logo = createProperty(NS, "logo");
+ public final IRI workplaceHomepage = createProperty(NS, "workplaceHomepage");
+ public final IRI based_near = createProperty(NS, "based_near");
+ public final IRI thumbnail = createProperty(NS, "thumbnail");
+ public final IRI primaryTopic = createProperty(NS, "primaryTopic");
+ public final IRI aimChatID = createProperty(NS, "aimChatID");
+ public final IRI made = createProperty(NS, "made");
+ public final IRI workInfoHomepage = createProperty(NS, "workInfoHomepage");
+ public final IRI currentProject = createProperty(NS, "currentProject");
+ public final IRI holdsAccount = createProperty(NS, "holdsAccount");
+ public final IRI publications = createProperty(NS, "publications");
+ public final IRI sha1 = createProperty(NS, "sha1");
+ public final IRI gender = createProperty(NS, "gender");
+ public final IRI mbox = createProperty(NS, "mbox");
+ public final IRI myersBriggs = createProperty(NS, "myersBriggs");
+ public final IRI plan = createProperty(NS, "plan");
+ public final IRI pastProject = createProperty(NS, "pastProject");
+ public final IRI schoolHomepage = createProperty(NS, "schoolHomepage");
+ public final IRI family_name = createProperty(NS, "family_name");
+ public final IRI msnChatID = createProperty(NS, "msnChatID");
+ public final IRI theme = createProperty(NS, "theme");
+ public final IRI topic = createProperty(NS, "topic");
+ public final IRI dnaChecksum = createProperty(NS, "dnaChecksum");
+ public final IRI nick = createProperty(NS, "nick");
+ public final IRI jabberID = createProperty(NS, "jabberID");
// Resources.
- public final IRI Person = createClass(NS, "Person");
+ public final IRI Person = createClass(NS, "Person");
public final IRI PersonalProfileDocument = createClass(NS, "PersonalProfileDocument");
- public final IRI Project = createClass(NS, "Project");
- public final IRI OnlineChatAccount = createClass(NS, "OnlineChatAccount");
- public final IRI OnlineAccount = createClass(NS, "OnlineAccount");
- public final IRI Agent = createClass(NS, "Agent");
- public final IRI Group = createClass(NS, "Group");
- public final IRI OnlineGamingAccount = createClass(NS, "OnlineGamingAccount");
- public final IRI OnlineEcommerceAccount = createClass(NS, "OnlineEcommerceAccount");
- public final IRI Document = createClass(NS, "Document");
- public final IRI Organization = createClass(NS, "Organization");
- public final IRI Image = createClass(NS, "Image");
+ public final IRI Project = createClass(NS, "Project");
+ public final IRI OnlineChatAccount = createClass(NS, "OnlineChatAccount");
+ public final IRI OnlineAccount = createClass(NS, "OnlineAccount");
+ public final IRI Agent = createClass(NS, "Agent");
+ public final IRI Group = createClass(NS, "Group");
+ public final IRI OnlineGamingAccount = createClass(NS, "OnlineGamingAccount");
+ public final IRI OnlineEcommerceAccount = createClass(NS, "OnlineEcommerceAccount");
+ public final IRI Document = createClass(NS, "Document");
+ public final IRI Organization = createClass(NS, "Organization");
+ public final IRI Image = createClass(NS, "Image");
- private FOAF(){
+ private FOAF() {
super(NS);
}
-
+
}
diff --git a/api/src/main/java/org/apache/any23/vocab/GeoNames.java b/api/src/main/java/org/apache/any23/vocab/GeoNames.java
index 0c4a486..3c63675 100644
--- a/api/src/main/java/org/apache/any23/vocab/GeoNames.java
+++ b/api/src/main/java/org/apache/any23/vocab/GeoNames.java
@@ -29,7 +29,7 @@ public class GeoNames extends Vocabulary {
private static Vocabulary instance;
public static Vocabulary getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new GeoNames();
}
return instance;
@@ -39,10 +39,10 @@ public class GeoNames extends Vocabulary {
public final IRI Point = createClass(NS, "Point");
// Properties
- public final IRI lat = createProperty(NS, "lat" );
+ public final IRI lat = createProperty(NS, "lat");
public final IRI lon = createProperty(NS, "long");
- private GeoNames(){
+ private GeoNames() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/HCard.java b/api/src/main/java/org/apache/any23/vocab/HCard.java
index 75ba514..290c96c 100644
--- a/api/src/main/java/org/apache/any23/vocab/HCard.java
+++ b/api/src/main/java/org/apache/any23/vocab/HCard.java
@@ -30,55 +30,54 @@ public class HCard extends Vocabulary {
private static HCard instance;
public static HCard getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HCard();
}
return instance;
}
- public IRI Card = createClass(NS, "Card");
- public IRI Address = createClass(NS, "Address");
+ public IRI Card = createClass(NS, "Card");
+ public IRI Address = createClass(NS, "Address");
public IRI Geo = createClass(NS, "Geo");
+ public IRI name = createProperty(NS, "name");
+ public IRI honorific_prefix = createProperty(NS, "honorific-prefix");
+ public IRI given_name = createProperty(NS, "given-name");
+ public IRI additional_name = createProperty(NS, "additional-name");
+ public IRI family_name = createProperty(NS, "family-name");
+ public IRI sort_string = createProperty(NS, "sort-string");
+ public IRI honorific_suffix = createProperty(NS, "honorific-suffix");
+ public IRI nickname = createProperty(NS, "nickname");
+ public IRI email = createProperty(NS, "email");
+ public IRI logo = createProperty(NS, "logo");
+ public IRI photo = createProperty(NS, "photo");
+ public IRI url = createProperty(NS, "url");
+ public IRI uid = createProperty(NS, "uid");
+ public IRI category = createProperty(NS, "category");
+ public IRI tel = createProperty(NS, "tel");
+ public IRI note = createProperty(NS, "note");
+ public IRI bday = createProperty(NS, "bday");
+ public IRI key = createProperty(NS, "key");
+ public IRI org = createProperty(NS, "org");
+ public IRI job_title = createProperty(NS, "job-title");
+ public IRI role = createProperty(NS, "role");
+ public IRI impp = createProperty(NS, "impp");
+ public IRI sex = createProperty(NS, "sex");
+ public IRI gender_identity = createProperty(NS, "gender-identity");
+ public IRI anniversary = createProperty(NS, "anniversary");
+ public IRI geo = createProperty(NS, "geo");
+ public IRI adr = createProperty(NS, "adr");
- public IRI name = createProperty(NS, "name");
- public IRI honorific_prefix = createProperty(NS, "honorific-prefix");
- public IRI given_name = createProperty(NS, "given-name");
- public IRI additional_name = createProperty(NS, "additional-name");
- public IRI family_name = createProperty(NS, "family-name");
- public IRI sort_string = createProperty(NS, "sort-string");
- public IRI honorific_suffix = createProperty(NS, "honorific-suffix");
- public IRI nickname = createProperty(NS, "nickname");
- public IRI email = createProperty(NS, "email");
- public IRI logo = createProperty(NS, "logo");
- public IRI photo = createProperty(NS, "photo");
- public IRI url = createProperty(NS, "url");
- public IRI uid = createProperty(NS, "uid");
- public IRI category = createProperty(NS, "category");
- public IRI tel = createProperty(NS, "tel");
- public IRI note = createProperty(NS, "note");
- public IRI bday = createProperty(NS, "bday");
- public IRI key = createProperty(NS, "key");
- public IRI org = createProperty(NS, "org");
- public IRI job_title = createProperty(NS, "job-title");
- public IRI role = createProperty(NS, "role");
- public IRI impp = createProperty(NS, "impp");
- public IRI sex = createProperty(NS, "sex");
- public IRI gender_identity = createProperty(NS, "gender-identity");
- public IRI anniversary = createProperty(NS, "anniversary");
- public IRI geo = createProperty(NS, "geo");
- public IRI adr = createProperty(NS, "adr");
+ public IRI street_address = createProperty(NS, "street-address");
+ public IRI extended_address = createProperty(NS, "extended-address");
+ public IRI locality = createProperty(NS, "locality");
+ public IRI region = createProperty(NS, "region");
+ public IRI postal_code = createProperty(NS, "postal-code");
+ public IRI country_name = createProperty(NS, "country-name");
- public IRI street_address = createProperty(NS, "street-address");
- public IRI extended_address = createProperty(NS, "extended-address");
- public IRI locality = createProperty(NS, "locality");
- public IRI region = createProperty(NS, "region");
- public IRI postal_code = createProperty(NS, "postal-code");
- public IRI country_name = createProperty(NS, "country-name");
-
- public IRI latitude = createProperty(NS, "latitude");
- public IRI longitude = createProperty(NS, "longitude");
- public IRI altitude = createProperty(NS, "altitude");
+ public IRI latitude = createProperty(NS, "latitude");
+ public IRI longitude = createProperty(NS, "longitude");
+ public IRI altitude = createProperty(NS, "altitude");
private HCard() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/HEntry.java b/api/src/main/java/org/apache/any23/vocab/HEntry.java
index a5e6db9..63bbff2 100644
--- a/api/src/main/java/org/apache/any23/vocab/HEntry.java
+++ b/api/src/main/java/org/apache/any23/vocab/HEntry.java
@@ -31,27 +31,26 @@ public class HEntry extends Vocabulary {
private static HEntry instance;
public static HEntry getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HEntry();
}
return instance;
}
- public IRI Entry = createClass(NS, "Entry");
- public IRI author = createClass(NS, "author");
+ public IRI Entry = createClass(NS, "Entry");
+ public IRI author = createClass(NS, "author");
public IRI location = createClass(NS, "location");
-
- public IRI name = createProperty(NS, "name");
- public IRI summary = createProperty(NS, "summary");
- public IRI content = createProperty(NS, "content");
- public IRI published = createProperty(NS, "published");
- public IRI updated = createProperty(NS, "updated");
- public IRI category = createProperty(NS, "category");
- public IRI url = createProperty(NS, "url");
- public IRI uid = createProperty(NS, "uid");
- public IRI syndication = createProperty(NS, "syndication");
- public IRI in_reply_to = createProperty(NS, "in-reply-to");
+ public IRI name = createProperty(NS, "name");
+ public IRI summary = createProperty(NS, "summary");
+ public IRI content = createProperty(NS, "content");
+ public IRI published = createProperty(NS, "published");
+ public IRI updated = createProperty(NS, "updated");
+ public IRI category = createProperty(NS, "category");
+ public IRI url = createProperty(NS, "url");
+ public IRI uid = createProperty(NS, "uid");
+ public IRI syndication = createProperty(NS, "syndication");
+ public IRI in_reply_to = createProperty(NS, "in-reply-to");
private HEntry() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/HEvent.java b/api/src/main/java/org/apache/any23/vocab/HEvent.java
index b90fde2..bb38db3 100644
--- a/api/src/main/java/org/apache/any23/vocab/HEvent.java
+++ b/api/src/main/java/org/apache/any23/vocab/HEvent.java
@@ -30,26 +30,24 @@ public class HEvent extends Vocabulary {
private static HEvent instance;
public static HEvent getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HEvent();
}
return instance;
}
- public IRI event = createClass(NS, "Event");
+ public IRI event = createClass(NS, "Event");
-
- public IRI name = createProperty(NS, "name");
- public IRI summary = createProperty(NS, "summary");
+ public IRI name = createProperty(NS, "name");
+ public IRI summary = createProperty(NS, "summary");
public IRI start = createProperty(NS, "start");
- public IRI end = createProperty(NS, "end");
+ public IRI end = createProperty(NS, "end");
public IRI duration = createProperty(NS, "duration");
- public IRI description = createProperty(NS, "description");
+ public IRI description = createProperty(NS, "description");
public IRI url = createProperty(NS, "url");
- public IRI category = createProperty(NS, "category");
+ public IRI category = createProperty(NS, "category");
public IRI location = createProperty(NS, "location");
- public IRI attendee = createProperty(NS, "attendee");
-
+ public IRI attendee = createProperty(NS, "attendee");
private HEvent() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/HItem.java b/api/src/main/java/org/apache/any23/vocab/HItem.java
index 0843ead..1404821 100644
--- a/api/src/main/java/org/apache/any23/vocab/HItem.java
+++ b/api/src/main/java/org/apache/any23/vocab/HItem.java
@@ -31,16 +31,17 @@ public class HItem extends Vocabulary {
private static HItem instance;
public static HItem getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HItem();
}
return instance;
}
- public IRI Item = createClass(NS, "Item");
- public IRI name = createProperty(NS, "name");
- public IRI url = createProperty(NS, "url");
+ public IRI Item = createClass(NS, "Item");
+ public IRI name = createProperty(NS, "name");
+ public IRI url = createProperty(NS, "url");
public IRI photo = createProperty(NS, "photo");
+
private HItem() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/HListing.java b/api/src/main/java/org/apache/any23/vocab/HListing.java
index 5ef1286..0ef633e 100644
--- a/api/src/main/java/org/apache/any23/vocab/HListing.java
+++ b/api/src/main/java/org/apache/any23/vocab/HListing.java
@@ -32,7 +32,7 @@ public class HListing extends Vocabulary {
private static HListing instance;
public static HListing getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HListing();
}
return instance;
@@ -40,47 +40,47 @@ public class HListing extends Vocabulary {
// Resources.
public final IRI Listing = createClass("Listing");
- public final IRI Lister = createClass("Lister" ); // isa FOAF.Person
- public final IRI Item = createClass("Item" ); // isa ?
+ public final IRI Lister = createClass("Lister"); // isa FOAF.Person
+ public final IRI Item = createClass("Item"); // isa ?
// Properties.
public final IRI action = createProperty("action");
public final IRI lister = createProperty("lister"); // ranges over Lister
- public final IRI item = createProperty("item" );
+ public final IRI item = createProperty("item");
- public final IRI sell = createClass("sell" );
- public final IRI rent = createClass("rent" );
- public final IRI trade = createClass("trade" );
- public final IRI meet = createClass("meet" );
+ public final IRI sell = createClass("sell");
+ public final IRI rent = createClass("rent");
+ public final IRI trade = createClass("trade");
+ public final IRI meet = createClass("meet");
public final IRI announce = createClass("announce");
- public final IRI offer = createClass("offer" );
- public final IRI wanted = createClass("wanted" );
- public final IRI event = createClass("event" );
- public final IRI service = createClass("service" );
+ public final IRI offer = createClass("offer");
+ public final IRI wanted = createClass("wanted");
+ public final IRI event = createClass("event");
+ public final IRI service = createClass("service");
- public final IRI tel = VCard.getInstance().tel;
- public final IRI dtlisted = createProperty("dtlisted" );
+ public final IRI tel = VCard.getInstance().tel;
+ public final IRI dtlisted = createProperty("dtlisted");
public final IRI dtexpired = createProperty("dtexpired");
- public final IRI price = createProperty("price" );
+ public final IRI price = createProperty("price");
public final IRI description = createProperty("description");
- public final IRI summary = createProperty("summary" );
- public final IRI permalink = createProperty("permalink" );
+ public final IRI summary = createProperty("summary");
+ public final IRI permalink = createProperty("permalink");
- public final IRI region = VCard.getInstance().region;
- public final IRI postOfficeBox = VCard.getInstance().post_office_box;
- public final IRI locality = VCard.getInstance().locality;
+ public final IRI region = VCard.getInstance().region;
+ public final IRI postOfficeBox = VCard.getInstance().post_office_box;
+ public final IRI locality = VCard.getInstance().locality;
public final IRI extendedAddress = VCard.getInstance().extended_address;
- public final IRI streetAddress = VCard.getInstance().street_address;
- public final IRI postalCode = VCard.getInstance().postal_code;
- public final IRI countryName = VCard.getInstance().country_name;
+ public final IRI streetAddress = VCard.getInstance().street_address;
+ public final IRI postalCode = VCard.getInstance().postal_code;
+ public final IRI countryName = VCard.getInstance().country_name;
- public final IRI listerUrl = createProperty("listerUrl" );
+ public final IRI listerUrl = createProperty("listerUrl");
public final IRI listerName = createProperty("listerName");
- public final IRI itemName = createProperty("itemName" );
- public final IRI itemUrl = createProperty("itemUrl" );
- public final IRI itemPhoto = createProperty("itemPhoto" );
- public final IRI listerOrg = createProperty("listerOrg" );
+ public final IRI itemName = createProperty("itemName");
+ public final IRI itemUrl = createProperty("itemUrl");
+ public final IRI itemPhoto = createProperty("itemPhoto");
+ public final IRI listerOrg = createProperty("listerOrg");
public final IRI listerLogo = createProperty("listerLogo");
private IRI createProperty(String localName) {
@@ -91,7 +91,7 @@ public class HListing extends Vocabulary {
return createClass(NS, localName);
}
- private HListing(){
+ private HListing() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/HProduct.java b/api/src/main/java/org/apache/any23/vocab/HProduct.java
index ec251b2..c7ab05e 100644
--- a/api/src/main/java/org/apache/any23/vocab/HProduct.java
+++ b/api/src/main/java/org/apache/any23/vocab/HProduct.java
@@ -31,25 +31,23 @@ public class HProduct extends Vocabulary {
private static HProduct instance;
public static HProduct getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HProduct();
}
return instance;
}
- public IRI product = createClass(NS, "Product");
+ public IRI product = createClass(NS, "Product");
-
- public IRI name = createProperty(NS, "name");
- public IRI photo = createProperty(NS, "photo");
+ public IRI name = createProperty(NS, "name");
+ public IRI photo = createProperty(NS, "photo");
public IRI brand = createProperty(NS, "brand");
- public IRI category = createProperty(NS, "category");
- public IRI description = createProperty(NS, "description");
+ public IRI category = createProperty(NS, "category");
+ public IRI description = createProperty(NS, "description");
public IRI url = createProperty(NS, "url");
public IRI identifier = createProperty(NS, "identifier");
public IRI price = createProperty(NS, "price");
- public IRI review = createProperty(NS, "review");
-
+ public IRI review = createProperty(NS, "review");
private HProduct() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/HRecipe.java b/api/src/main/java/org/apache/any23/vocab/HRecipe.java
index 0124a54..2d0ecff 100644
--- a/api/src/main/java/org/apache/any23/vocab/HRecipe.java
+++ b/api/src/main/java/org/apache/any23/vocab/HRecipe.java
@@ -31,37 +31,37 @@ public class HRecipe extends Vocabulary {
private static HRecipe instance;
public static HRecipe getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HRecipe();
}
return instance;
}
// Resources.
- public IRI Recipe = createClass(NS, "Recipe");
- public IRI Duration = createClass(NS, "Duration");
+ public IRI Recipe = createClass(NS, "Recipe");
+ public IRI Duration = createClass(NS, "Duration");
public IRI Ingredient = createClass(NS, "Ingredient");
- public IRI Nutrition = createClass(NS, "Nutrition");
+ public IRI Nutrition = createClass(NS, "Nutrition");
// Properties.
- public IRI fn = createProperty(NS, "fn");
- public IRI duration = createProperty(NS, "duration");
- public IRI durationTitle = createProperty(NS, "durationTitle");
- public IRI durationTime = createProperty(NS, "durationTime");
- public IRI photo = createProperty(NS, "photo");
- public IRI summary = createProperty(NS, "summary");
- public IRI author = createProperty(NS, "author");
- public IRI published = createProperty(NS, "published");
- public IRI nutrition = createProperty(NS, "nutrition");
- public IRI nutritionValue = createProperty(NS, "nutritionValue");
- public IRI nutritionValueType = createProperty(NS, "nutritionValueType");
- public IRI tag = createProperty(NS, "tag");
- public IRI ingredient = createProperty(NS, "ingredient");
- public IRI ingredientName = createProperty(NS, "ingredientName");
- public IRI ingredientQuantity = createProperty(NS, "ingredientQuantity");
+ public IRI fn = createProperty(NS, "fn");
+ public IRI duration = createProperty(NS, "duration");
+ public IRI durationTitle = createProperty(NS, "durationTitle");
+ public IRI durationTime = createProperty(NS, "durationTime");
+ public IRI photo = createProperty(NS, "photo");
+ public IRI summary = createProperty(NS, "summary");
+ public IRI author = createProperty(NS, "author");
+ public IRI published = createProperty(NS, "published");
+ public IRI nutrition = createProperty(NS, "nutrition");
+ public IRI nutritionValue = createProperty(NS, "nutritionValue");
+ public IRI nutritionValueType = createProperty(NS, "nutritionValueType");
+ public IRI tag = createProperty(NS, "tag");
+ public IRI ingredient = createProperty(NS, "ingredient");
+ public IRI ingredientName = createProperty(NS, "ingredientName");
+ public IRI ingredientQuantity = createProperty(NS, "ingredientQuantity");
public IRI ingredientQuantityType = createProperty(NS, "ingredientQuantityType");
- public IRI instructions = createProperty(NS, "instructions");
- public IRI yield = createProperty(NS, "yield");
+ public IRI instructions = createProperty(NS, "instructions");
+ public IRI yield = createProperty(NS, "yield");
private HRecipe() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/HResume.java b/api/src/main/java/org/apache/any23/vocab/HResume.java
index f8ee68e..939903a 100644
--- a/api/src/main/java/org/apache/any23/vocab/HResume.java
+++ b/api/src/main/java/org/apache/any23/vocab/HResume.java
@@ -30,23 +30,21 @@ public class HResume extends Vocabulary {
private static HResume instance;
public static HResume getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new HResume();
}
return instance;
}
- public IRI Resume = createClass(NS, "Resume");
- public IRI education = createClass(NS, "education");
+ public IRI Resume = createClass(NS, "Resume");
+ public IRI education = createClass(NS, "education");
public IRI experience = createClass(NS, "experience");
public IRI contact = createClass(NS, "contact");
public IRI affiliation = createClass(NS, "affiliation");
-
- public IRI name = createProperty(NS, "name");
- public IRI summary = createProperty(NS, "summary");
- public IRI skill = createProperty(NS, "skill");
-
+ public IRI name = createProperty(NS, "name");
+ public IRI summary = createProperty(NS, "summary");
+ public IRI skill = createProperty(NS, "skill");
private HResume() {
super(NS);
diff --git a/api/src/main/java/org/apache/any23/vocab/ICAL.java b/api/src/main/java/org/apache/any23/vocab/ICAL.java
index ce5c559..746583a 100644
--- a/api/src/main/java/org/apache/any23/vocab/ICAL.java
+++ b/api/src/main/java/org/apache/any23/vocab/ICAL.java
@@ -48,31 +48,31 @@ public class ICAL extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
public final IRI DomainOf_rrule = createClass("DomainOf_rrule");
- public final IRI List_of_Float = createClass("List_of_Float");
+ public final IRI List_of_Float = createClass("List_of_Float");
/**
* Provide a grouping of component properties that define an alarm..
*/
- public final IRI Valarm = createClass("Valarm");
+ public final IRI Valarm = createClass("Valarm");
public final IRI Value_CAL_ADDRESS = createClass("Value_CAL-ADDRESS");
- public final IRI Value_DATE = createClass("Value_DATE");
+ public final IRI Value_DATE = createClass("Value_DATE");
- public final IRI Value_DATE_TIME = createClass("Value_DATE-TIME");
+ public final IRI Value_DATE_TIME = createClass("Value_DATE-TIME");
/**
* ICAL datatype for floating date-time values
*/
- public final IRI DATE_TIME = createIRI(NS + "dateTime");
+ public final IRI DATE_TIME = createIRI(NS + "dateTime");
- public final IRI Value_DURATION = createClass("Value_DURATION");
+ public final IRI Value_DURATION = createClass("Value_DURATION");
- public final IRI Value_PERIOD = createClass("Value_PERIOD");
+ public final IRI Value_PERIOD = createClass("Value_PERIOD");
- public final IRI Value_RECUR = createClass("Value_RECUR");
+ public final IRI Value_RECUR = createClass("Value_RECUR");
- public final IRI Vcalendar = createClass("Vcalendar");
+ public final IRI Vcalendar = createClass("Vcalendar");
/**
* Provide a grouping of component properties that describe an event..
@@ -80,9 +80,8 @@ public class ICAL extends Vocabulary {
public final IRI Vevent = createClass("Vevent");
/**
- * Provide a grouping of component properties that describe either a request
- * for free/busy time, describe a response to a request for free/busy time or
- * describe a published set of busy time..
+ * Provide a grouping of component properties that describe either a request for free/busy time, describe a response
+ * to a request for free/busy time or describe a published set of busy time..
*/
public final IRI Vfreebusy = createClass("Vfreebusy");
@@ -101,21 +100,18 @@ public class ICAL extends Vocabulary {
*/
public final IRI Vtodo = createClass("Vtodo");
-
/**
- * The IRI provides the capability to associate a document object with a
- * calendar component.default value type: IRI.
+ * The IRI provides the capability to associate a document object with a calendar component.default value type: IRI.
*/
public final IRI attach = createProperty("attach");
/**
- * The IRI defines an "Attendee" within a calendar component.value type:
- * CAL-ADDRESS.
+ * The IRI defines an "Attendee" within a calendar component.value type: CAL-ADDRESS.
*/
- public final IRI attendee = createProperty("attendee");
+ public final IRI attendee = createProperty("attendee");
public final IRI calAddress = createProperty("calAddress");
- public final IRI component = createProperty("component");
- public final IRI daylight = createProperty("daylight");
+ public final IRI component = createProperty("component");
+ public final IRI daylight = createProperty("daylight");
/**
* The IRI specifies a positive duration of time.value type: DURATION.
@@ -123,8 +119,7 @@ public class ICAL extends Vocabulary {
public final IRI duration = createProperty("duration");
/**
- * This IRI defines a rule or repeating pattern for an exception to a recurrence
- * set.value type: RECUR.
+ * This IRI defines a rule or repeating pattern for an exception to a recurrence set.value type: RECUR.
*/
public final IRI exrule = createProperty("exrule");
@@ -134,8 +129,8 @@ public class ICAL extends Vocabulary {
public final IRI freebusy = createProperty("freebusy");
/**
- * value type: list of FLOATThis IRI specifies information related to the
- * global position for the activity specified by a calendar component..
+ * value type: list of FLOATThis IRI specifies information related to the global position for the activity specified
+ * by a calendar component..
*/
public final IRI geo = createProperty("geo");
@@ -145,8 +140,8 @@ public class ICAL extends Vocabulary {
public final IRI organizer = createProperty("organizer");
/**
- * This IRI defines a rule or repeating pattern for recurring events, to-dos,
- * or time zone definitions.value type: RECUR.
+ * This IRI defines a rule or repeating pattern for recurring events, to-dos, or time zone definitions.value type:
+ * RECUR.
*/
public final IRI rrule = createProperty("rrule");
@@ -158,27 +153,23 @@ public class ICAL extends Vocabulary {
public final IRI trigger = createProperty("trigger");
/**
- * The TZURL provides a means for a VTIMEZONE component to point to a network
- * location that can be used to retrieve an up-to- date version of itself.value
- * type: IRI.
+ * The TZURL provides a means for a VTIMEZONE component to point to a network location that can be used to retrieve
+ * an up-to- date version of itself.value type: IRI.
*/
public final IRI tzurl = createProperty("tzurl");
/**
- * This IRI defines a Uniform IRI Locator (URL) associated with the
- * iCalendar object.value type: IRI.
+ * This IRI defines a Uniform IRI Locator (URL) associated with the iCalendar object.value type: IRI.
*/
public final IRI url = createProperty("url");
/**
- * value type: TEXTThis class of IRI provides a framework for defining non-standard
- * properties..
+ * value type: TEXTThis class of IRI provides a framework for defining non-standard properties..
*/
public final IRI X_ = createProperty("X-");
/**
- * value type: TEXTThis IRI defines the action to be invoked when an alarm
- * is triggered..
+ * value type: TEXTThis IRI defines the action to be invoked when an alarm is triggered..
*/
public final IRI action = createProperty("action");
@@ -206,8 +197,8 @@ public class ICAL extends Vocabulary {
public final IRI wkst = createProperty("wkst");
/**
- * value type: TEXTThis IRI defines the calendar scale used for the calendar
- * information specified in the iCalendar object..
+ * value type: TEXTThis IRI defines the calendar scale used for the calendar information specified in the iCalendar
+ * object..
*/
public final IRI calscale = createProperty("calscale");
@@ -217,41 +208,38 @@ public class ICAL extends Vocabulary {
public final IRI categories = createProperty("categories");
/**
- * value type: TEXTThis IRI defines the access classification for a calendar
- * component..
+ * value type: TEXTThis IRI defines the access classification for a calendar component..
*/
public final IRI class_ = createProperty("class");
/**
- * To specify the common name to be associated with the calendar user specified
- * by the IRI..
+ * To specify the common name to be associated with the calendar user specified by the IRI..
*/
public final IRI cn = createProperty("cn");
/**
- * value type: TEXTThis IRI specifies non-processing information intended
- * to provide a comment to the calendar user..
+ * value type: TEXTThis IRI specifies non-processing information intended to provide a comment to the calendar
+ * user..
*/
public final IRI comment = createProperty("comment");
/**
- * value type: DATE-TIMEThis IRI defines the date and time that a to-do
- * was actually completed..
+ * value type: DATE-TIMEThis IRI defines the date and time that a to-do was actually completed..
*/
public final IRI completed = createProperty("completed");
/**
- * value type: TEXTThe IRI is used to represent contact information or alternately
- * a reference to contact information associated with the calendar component..
+ * value type: TEXTThe IRI is used to represent contact information or alternately a reference to contact
+ * information associated with the calendar component..
*/
public final IRI contact = createProperty("contact");
public final IRI count = createProperty("count");
/**
- * This IRI specifies the date and time that the calendar information was
- * created by the calendar user agent in the calendar store. Note: This is analogous
- * to the creation date and time for a file in the file system.value type: DATE-TIME.
+ * This IRI specifies the date and time that the calendar information was created by the calendar user agent in the
+ * calendar store. Note: This is analogous to the creation date and time for a file in the file system.value type:
+ * DATE-TIME.
*/
public final IRI created = createProperty("created");
@@ -261,50 +249,43 @@ public class ICAL extends Vocabulary {
public final IRI cutype = createProperty("cutype");
/**
- * To specify the calendar users that have delegated their participation to the
- * calendar user specified by the IRI..
+ * To specify the calendar users that have delegated their participation to the calendar user specified by the IRI..
*/
public final IRI delegatedFrom = createProperty("delegatedFrom");
/**
- * To specify the calendar users to whom the calendar user specified by the IRI
- * has delegated participation..
+ * To specify the calendar users to whom the calendar user specified by the IRI has delegated participation..
*/
public final IRI delegatedTo = createProperty("delegatedTo");
/**
- * value type: TEXTThis IRI provides a more complete description of the
- * calendar component, than that provided by the "SUMMARY" IRI..
+ * value type: TEXTThis IRI provides a more complete description of the calendar component, than that provided by
+ * the "SUMMARY" IRI..
*/
public final IRI description = createProperty("description");
/**
- * To specify reference to a directory entry associated with the calendar user
- * specified by the IRI..
+ * To specify reference to a directory entry associated with the calendar user specified by the IRI..
*/
public final IRI dir = createProperty("dir");
/**
- * This IRI specifies the date and time that a calendar component ends.default
- * value type: DATE-TIME.
+ * This IRI specifies the date and time that a calendar component ends.default value type: DATE-TIME.
*/
public final IRI dtend = createProperty("dtend");
/**
- * value type: DATE-TIMEThe IRI indicates the date/time that the instance
- * of the iCalendar object was created..
+ * value type: DATE-TIMEThe IRI indicates the date/time that the instance of the iCalendar object was created..
*/
public final IRI dtstamp = createProperty("dtstamp");
/**
- * default value type: DATE-TIMEThis IRI specifies when the calendar component
- * begins..
+ * default value type: DATE-TIMEThis IRI specifies when the calendar component begins..
*/
public final IRI dtstart = createProperty("dtstart");
/**
- * default value type: DATE-TIMEThis IRI defines the date and time that
- * a to-do is expected to be completed..
+ * default value type: DATE-TIMEThis IRI defines the date and time that a to-do is expected to be completed..
*/
public final IRI due = createProperty("due");
@@ -314,8 +295,8 @@ public class ICAL extends Vocabulary {
public final IRI encoding = createProperty("encoding");
/**
- * default value type: DATE-TIMEThis IRI defines the list of date/time exceptions
- * for a recurring calendar component..
+ * default value type: DATE-TIMEThis IRI defines the list of date/time exceptions for a recurring calendar
+ * component..
*/
public final IRI exdate = createProperty("exdate");
@@ -339,108 +320,95 @@ public class ICAL extends Vocabulary {
public final IRI language = createProperty("language");
/**
- * value type: DATE-TIMEThe IRI specifies the date and time that the information
- * associated with the calendar component was last revised in the calendar store.
- * Note: This is analogous to the modification date and time for a file in the
- * file system..
+ * value type: DATE-TIMEThe IRI specifies the date and time that the information associated with the calendar
+ * component was last revised in the calendar store. Note: This is analogous to the modification date and time for a
+ * file in the file system..
*/
public final IRI lastModified = createProperty("lastModified");
/**
- * value type: TEXTThe IRI defines the intended venue for the activity defined
- * by a calendar component..
+ * value type: TEXTThe IRI defines the intended venue for the activity defined by a calendar component..
*/
public final IRI location = createProperty("location");
/**
- * To specify the group or list membership of the calendar user specified by
- * the IRI..
+ * To specify the group or list membership of the calendar user specified by the IRI..
*/
public final IRI member = createProperty("member");
/**
- * value type: TEXTThis IRI defines the iCalendar object method associated
- * with the calendar object..
+ * value type: TEXTThis IRI defines the iCalendar object method associated with the calendar object..
*/
public final IRI method = createProperty("method");
/**
- * To specify the participation status for the calendar user specified by the
- * IRI..
+ * To specify the participation status for the calendar user specified by the IRI..
*/
public final IRI partstat = createProperty("partstat");
/**
- * value type: INTEGERThis IRI is used by an assignee or delegatee of a
- * to-do to convey the percent completion of a to-do to the Organizer..
+ * value type: INTEGERThis IRI is used by an assignee or delegatee of a to-do to convey the percent completion of a
+ * to-do to the Organizer..
*/
public final IRI percentComplete = createProperty("percentComplete");
/**
- * The IRI defines the relative priority for a calendar component.value
- * type: INTEGER.
+ * The IRI defines the relative priority for a calendar component.value type: INTEGER.
*/
public final IRI priority = createProperty("priority");
/**
- * value type: TEXTThis IRI specifies the identifier for the product that
- * created the iCalendar object..
+ * value type: TEXTThis IRI specifies the identifier for the product that created the iCalendar object..
*/
public final IRI prodid = createProperty("prodid");
/**
- * To specify the effective range of recurrence instances from the instance specified
- * by the recurrence identifier specified by the IRI..
+ * To specify the effective range of recurrence instances from the instance specified by the recurrence identifier
+ * specified by the IRI..
*/
public final IRI range = createProperty("range");
/**
- * default value type: DATE-TIMEThis IRI defines the list of date/times
- * for a recurrence set..
+ * default value type: DATE-TIMEThis IRI defines the list of date/times for a recurrence set..
*/
public final IRI rdate = createProperty("rdate");
/**
- * default value type: DATE-TIMEThis IRI is used in conjunction with the
- * "UID" and "SEQUENCE" IRI to identify a specific instance of a recurring
- * "VEVENT", "VTODO" or "VJOURNAL" calendar component. The IRI value is
- * the effective value of the "DTSTART" IRI of the recurrence instance..
+ * default value type: DATE-TIMEThis IRI is used in conjunction with the "UID" and "SEQUENCE" IRI to identify a
+ * specific instance of a recurring "VEVENT", "VTODO" or "VJOURNAL" calendar component. The IRI value is the
+ * effective value of the "DTSTART" IRI of the recurrence instance..
*/
public final IRI recurrenceId = createProperty("recurrenceId");
/**
- * To specify the relationship of the alarm trigger with respect to the start
- * or end of the calendar component..
+ * To specify the relationship of the alarm trigger with respect to the start or end of the calendar component..
*/
public final IRI related = createProperty("related");
/**
- * The IRI is used to represent a relationship or reference between one
- * calendar component and another.value type: TEXT.
+ * The IRI is used to represent a relationship or reference between one calendar component and another.value type:
+ * TEXT.
*/
public final IRI relatedTo = createProperty("relatedTo");
/**
- * To specify the type of hierarchical relationship associated with the calendar
- * component specified by the IRI..
+ * To specify the type of hierarchical relationship associated with the calendar component specified by the IRI..
*/
public final IRI reltype = createProperty("reltype");
/**
- * This IRI defines the number of time the alarm should be repeated, after
- * the initial trigger.value type: INTEGER.
+ * This IRI defines the number of time the alarm should be repeated, after the initial trigger.value type: INTEGER.
*/
public final IRI repeat = createProperty("repeat");
/**
- * value type: TEXTThis IRI defines the status code returned for a scheduling
- * request..
+ * value type: TEXTThis IRI defines the status code returned for a scheduling request..
*/
public final IRI requestStatus = createProperty("requestStatus");
/**
- * value type: TEXTThis IRI defines the equipment or resources anticipated
- * for an activity specified by a calendar entity...
+ * value type: TEXTThis IRI defines the equipment or resources anticipated for an activity specified by a calendar
+ * entity...
*/
public final IRI resources = createProperty("resources");
@@ -450,78 +418,68 @@ public class ICAL extends Vocabulary {
public final IRI role = createProperty("role");
/**
- * To specify whether there is an expectation of a favor of a reply from the
- * calendar user specified by the IRI value..
+ * To specify whether there is an expectation of a favor of a reply from the calendar user specified by the IRI
+ * value..
*/
public final IRI rsvp = createProperty("rsvp");
/**
- * To specify the calendar user that is acting on behalf of the calendar user
- * specified by the IRI..
+ * To specify the calendar user that is acting on behalf of the calendar user specified by the IRI..
*/
public final IRI sentBy = createProperty("sentBy");
/**
- * value type: integerThis IRI defines the revision sequence number of the
- * calendar component within a sequence of revisions..
+ * value type: integerThis IRI defines the revision sequence number of the calendar component within a sequence of
+ * revisions..
*/
public final IRI sequence = createProperty("sequence");
/**
- * value type: TEXTThis IRI defines the overall status or confirmation for
- * the calendar component..
+ * value type: TEXTThis IRI defines the overall status or confirmation for the calendar component..
*/
public final IRI status = createProperty("status");
/**
- * This IRI defines a short summary or subject for the calendar component.value
- * type: TEXT.
+ * This IRI defines a short summary or subject for the calendar component.value type: TEXT.
*/
public final IRI summary = createProperty("summary");
/**
- * This IRI defines whether an event is transparent or not to busy time
- * searches.value type: TEXT.
+ * This IRI defines whether an event is transparent or not to busy time searches.value type: TEXT.
*/
public final IRI transp = createProperty("transp");
/**
- * value type: TEXTTo specify the identifier for the time zone definition for
- * a time component in the IRI value.This IRI specifies the text value
- * that uniquely identifies the "VTIMEZONE" calendar component..
+ * value type: TEXTTo specify the identifier for the time zone definition for a time component in the IRI value.This
+ * IRI specifies the text value that uniquely identifies the "VTIMEZONE" calendar component..
*/
public final IRI tzid = createProperty("tzid");
/**
- * value type: TEXTThis IRI specifies the customary designation for a time
- * zone description..
+ * value type: TEXTThis IRI specifies the customary designation for a time zone description..
*/
public final IRI tzname = createProperty("tzname");
/**
- * value type: UTC-OFFSETThis IRI specifies the offset which is in use prior
- * to this time zone observance..
+ * value type: UTC-OFFSETThis IRI specifies the offset which is in use prior to this time zone observance..
*/
public final IRI tzoffsetfrom = createProperty("tzoffsetfrom");
/**
- * value type: UTC-OFFSETThis IRI specifies the offset which is in use in
- * this time zone observance..
+ * value type: UTC-OFFSETThis IRI specifies the offset which is in use in this time zone observance..
*/
public final IRI tzoffsetto = createProperty("tzoffsetto");
/**
- * This IRI defines the persistent, globally unique identifier for the calendar
- * component.value type: TEXT.
+ * This IRI defines the persistent, globally unique identifier for the calendar component.value type: TEXT.
*/
public final IRI uid = createProperty("uid");
public final IRI until = createProperty("until");
/**
- * value type: TEXTThis IRI specifies the identifier corresponding to the
- * highest version number or the minimum and maximum range of the iCalendar specification
- * that is required in order to interpret the iCalendar object..
+ * value type: TEXTThis IRI specifies the identifier corresponding to the highest version number or the minimum and
+ * maximum range of the iCalendar specification that is required in order to interpret the iCalendar object..
*/
public final IRI version = createProperty("version");
@@ -533,7 +491,7 @@ public class ICAL extends Vocabulary {
return createProperty(NS, string);
}
- private ICAL(){
+ private ICAL() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreAction.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreAction.java
index 0747db3..1d93ee0 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreAction.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreAction.java
@@ -19,70 +19,74 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The action module describes the vocabulary for representing actions in general.
- * Actions are processes which are performed by some agent (the actor of the action).
- * This module does not commit itself to a particular theory on thematic roles.</p>
+ * <p>
+ * The action module describes the vocabulary for representing actions in general. Actions are processes which are
+ * performed by some agent (the actor of the action). This module does not commit itself to a particular theory on
+ * thematic roles.
+ * </p>
*
* @author lewismc
*
*
*/
public class LKIFCoreAction extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/action.owl#";
-
+
private static LKIFCoreAction instance;
-
+
public static LKIFCoreAction getInstance() {
- if(instance == null) {
- instance = new LKIFCoreAction();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreAction();
+ }
+ return instance;
+ }
+
/////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/action.owl */
/////////////////////////////////////////////////////////
// CLASSES
- public final IRI Action = createClass(NS, "Action");
- public final IRI Agent = createClass(NS, "Agent");
- public final IRI Artifact = createClass(NS, "Artifact");
- public final IRI Collaborative_Plan = createClass(NS, "Collaborative_Plan");
- public final IRI Creation_C = createClass(NS, "Creation");
- public final IRI Natural_Object = createClass(NS, "Natural_Object");
- public final IRI Organisation = createClass(NS, "Organisation");
- public final IRI Person = createClass(NS, "Person");
- public final IRI Personal_Plan = createClass(NS, "Personal_Plan");
- public final IRI Plan = createClass(NS, "Plan");
- public final IRI Reaction = createClass(NS, "Reaction");
- public final IRI Transaction = createClass(NS, "Transaction");
- public final IRI Mental_Object = createClass(NS, "Mental_Object");
- public final IRI Change = createClass(NS, "Change");
- public final IRI Physical_Object = createClass(NS, "Physical_Object");
- public final IRI Process = createClass(NS, "Process");
-
+ public final IRI Action = createClass(NS, "Action");
+ public final IRI Agent = createClass(NS, "Agent");
+ public final IRI Artifact = createClass(NS, "Artifact");
+ public final IRI Collaborative_Plan = createClass(NS, "Collaborative_Plan");
+ public final IRI Creation_C = createClass(NS, "Creation");
+ public final IRI Natural_Object = createClass(NS, "Natural_Object");
+ public final IRI Organisation = createClass(NS, "Organisation");
+ public final IRI Person = createClass(NS, "Person");
+ public final IRI Personal_Plan = createClass(NS, "Personal_Plan");
+ public final IRI Plan = createClass(NS, "Plan");
+ public final IRI Reaction = createClass(NS, "Reaction");
+ public final IRI Transaction = createClass(NS, "Transaction");
+ public final IRI Mental_Object = createClass(NS, "Mental_Object");
+ public final IRI Change = createClass(NS, "Change");
+ public final IRI Physical_Object = createClass(NS, "Physical_Object");
+ public final IRI Process = createClass(NS, "Process");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI actor = createProperty(NS, "actor");
- public final IRI actor_in = createProperty(NS, "actor_in");
- public final IRI direct_part = createProperty(NS, "direct_part");
- public final IRI member = createProperty(NS, "member");
- public final IRI part = createProperty(NS, "part");
- public final IRI creation_P = createProperty(NS, "creation");
- public final IRI participant = createProperty(NS, "participant");
- public final IRI participant_in = createProperty(NS, "participant_in");
- public final IRI result_of = createProperty(NS, "result_of");
-
+ public final IRI actor = createProperty(NS, "actor");
+ public final IRI actor_in = createProperty(NS, "actor_in");
+ public final IRI direct_part = createProperty(NS, "direct_part");
+ public final IRI member = createProperty(NS, "member");
+ public final IRI part = createProperty(NS, "part");
+ public final IRI creation_P = createProperty(NS, "creation");
+ public final IRI participant = createProperty(NS, "participant");
+ public final IRI participant_in = createProperty(NS, "participant_in");
+ public final IRI result_of = createProperty(NS, "result_of");
+
private LKIFCoreAction() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreExpression.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreExpression.java
index 60c0dd9..1784807 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreExpression.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreExpression.java
@@ -19,109 +19,112 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The expression module describes a vocabulary for describing,
- * propositions and propositional attitudes (belief, intention), qualifications,
- * statements and media. It furthermore extends the role module with a number
- * or epistemic roles, and is the basis for the definition of norms.</p>
+ * <p>
+ * The expression module describes a vocabulary for describing, propositions and propositional attitudes (belief,
+ * intention), qualifications, statements and media. It furthermore extends the role module with a number or epistemic
+ * roles, and is the basis for the definition of norms.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*/
public class LKIFCoreExpression extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/expression.owl#";
-
+
private static LKIFCoreExpression instance;
-
+
public static LKIFCoreExpression getInstance() {
- if(instance == null) {
- instance = new LKIFCoreExpression();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreExpression();
+ }
+ return instance;
+ }
+
/////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/expression.owl */
/////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Argument = createClass(NS, "Argument");
- public final IRI Assertion = createClass(NS, "Assertion");
- public final IRI Assumption = createClass(NS, "Assumption");
- public final IRI Belief = createClass(NS, "Belief");
- public final IRI Cause = createClass(NS, "Cause");
- public final IRI Communicated_Attitude = createClass(NS, "Communicated_Attitude");
- public final IRI Declaration = createClass(NS, "Declaration");
- public final IRI Desire = createClass(NS, "Desire");
- public final IRI Document = createClass(NS, "Document");
- public final IRI Evaluative_Attitude = createClass(NS, "Evaluative_Attitude");
- public final IRI Evaluative_Proposition = createClass(NS, "Evaluative_Proposition");
- public final IRI Evidence = createClass(NS, "Evidence");
- public final IRI Exception = createClass(NS, "Exception");
- public final IRI Expectation = createClass(NS, "Expectation");
- public final IRI Expression = createClass(NS, "Expression");
- public final IRI Fact = createClass(NS, "Fact");
- public final IRI Intention = createClass(NS, "Intention");
- public final IRI Lie = createClass(NS, "Lie");
- public final IRI Medium = createClass(NS, "Medium");
- public final IRI Observation = createClass(NS, "Observation");
- public final IRI Problem = createClass(NS, "Problem");
- public final IRI Promise = createClass(NS, "Promise");
- public final IRI Proposition = createClass(NS, "Proposition");
- public final IRI Propositional_Attitude = createClass(NS, "Propositional_Attitude");
- public final IRI Qualification = createClass(NS, "Qualification");
- public final IRI Qualified = createClass(NS, "Qualified");
- public final IRI Reason = createClass(NS, "Reason");
- public final IRI Speech_Act = createClass(NS, "Speech_Act");
- public final IRI Statement_In_Writing = createClass(NS, "Statement_In_Writing");
- public final IRI Surprise = createClass(NS, "Surprise");
-
+ public final IRI Argument = createClass(NS, "Argument");
+ public final IRI Assertion = createClass(NS, "Assertion");
+ public final IRI Assumption = createClass(NS, "Assumption");
+ public final IRI Belief = createClass(NS, "Belief");
+ public final IRI Cause = createClass(NS, "Cause");
+ public final IRI Communicated_Attitude = createClass(NS, "Communicated_Attitude");
+ public final IRI Declaration = createClass(NS, "Declaration");
+ public final IRI Desire = createClass(NS, "Desire");
+ public final IRI Document = createClass(NS, "Document");
+ public final IRI Evaluative_Attitude = createClass(NS, "Evaluative_Attitude");
+ public final IRI Evaluative_Proposition = createClass(NS, "Evaluative_Proposition");
+ public final IRI Evidence = createClass(NS, "Evidence");
+ public final IRI Exception = createClass(NS, "Exception");
+ public final IRI Expectation = createClass(NS, "Expectation");
+ public final IRI Expression = createClass(NS, "Expression");
+ public final IRI Fact = createClass(NS, "Fact");
+ public final IRI Intention = createClass(NS, "Intention");
+ public final IRI Lie = createClass(NS, "Lie");
+ public final IRI Medium = createClass(NS, "Medium");
+ public final IRI Observation = createClass(NS, "Observation");
+ public final IRI Problem = createClass(NS, "Problem");
+ public final IRI Promise = createClass(NS, "Promise");
+ public final IRI Proposition = createClass(NS, "Proposition");
+ public final IRI Propositional_Attitude = createClass(NS, "Propositional_Attitude");
+ public final IRI Qualification = createClass(NS, "Qualification");
+ public final IRI Qualified = createClass(NS, "Qualified");
+ public final IRI Reason = createClass(NS, "Reason");
+ public final IRI Speech_Act = createClass(NS, "Speech_Act");
+ public final IRI Statement_In_Writing = createClass(NS, "Statement_In_Writing");
+ public final IRI Surprise = createClass(NS, "Surprise");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI addressee = createProperty(NS, "addressee");
- public final IRI asserted_by = createProperty(NS, "asserted_by");
- public final IRI asserts = createProperty(NS, "asserts");
- public final IRI attitude = createProperty(NS, "attitude");
- public final IRI author = createProperty(NS, "author");
- public final IRI bears = createProperty(NS, "bears");
- public final IRI believed_by = createProperty(NS, "believed_by");
- public final IRI believes = createProperty(NS, "believes");
- public final IRI declares = createProperty(NS, "declares");
- public final IRI declared_by = createProperty(NS, "declared_by");
- public final IRI evaluated_by = createProperty(NS, "evaluated_by");
- public final IRI evaluates = createProperty(NS, "evaluates");
- public final IRI evaluatively_comparable = createProperty(NS, "evaluatively_comparable");
- public final IRI held_by = createProperty(NS, "held_by");
- public final IRI holds = createProperty(NS, "holds");
- public final IRI intended_by = createProperty(NS, "intended_by");
- public final IRI intends = createProperty(NS, "intends");
- public final IRI medium = createProperty(NS, "medium");
- public final IRI observer = createProperty(NS, "observer");
- public final IRI observes = createProperty(NS, "observes");
- public final IRI promised_by = createProperty(NS, "promised_by");
- public final IRI promises = createProperty(NS, "promises");
- public final IRI qualified_by = createProperty(NS, "qualified_by");
- public final IRI qualifies = createProperty(NS, "qualifies");
- public final IRI qualitatively_comparable = createProperty(NS, "qualitatively_comparable");
- public final IRI stated_by = createProperty(NS, "stated_by");
- public final IRI states = createProperty(NS, "states");
- public final IRI towards = createProperty(NS, "towards");
- public final IRI utterer = createProperty(NS, "utterer");
- public final IRI utters = createProperty(NS, "utters");
- public final IRI creation = createProperty(NS, "creation");
- public final IRI counts_as = createProperty(NS, "counts_as");
- public final IRI imposed_on = createProperty(NS, "imposed_on");
- public final IRI played_by = createProperty(NS, "played_by");
- public final IRI plays = createProperty(NS, "plays");
-
+ public final IRI addressee = createProperty(NS, "addressee");
+ public final IRI asserted_by = createProperty(NS, "asserted_by");
+ public final IRI asserts = createProperty(NS, "asserts");
+ public final IRI attitude = createProperty(NS, "attitude");
+ public final IRI author = createProperty(NS, "author");
+ public final IRI bears = createProperty(NS, "bears");
+ public final IRI believed_by = createProperty(NS, "believed_by");
+ public final IRI believes = createProperty(NS, "believes");
+ public final IRI declares = createProperty(NS, "declares");
+ public final IRI declared_by = createProperty(NS, "declared_by");
+ public final IRI evaluated_by = createProperty(NS, "evaluated_by");
+ public final IRI evaluates = createProperty(NS, "evaluates");
+ public final IRI evaluatively_comparable = createProperty(NS, "evaluatively_comparable");
+ public final IRI held_by = createProperty(NS, "held_by");
+ public final IRI holds = createProperty(NS, "holds");
+ public final IRI intended_by = createProperty(NS, "intended_by");
+ public final IRI intends = createProperty(NS, "intends");
+ public final IRI medium = createProperty(NS, "medium");
+ public final IRI observer = createProperty(NS, "observer");
+ public final IRI observes = createProperty(NS, "observes");
+ public final IRI promised_by = createProperty(NS, "promised_by");
+ public final IRI promises = createProperty(NS, "promises");
+ public final IRI qualified_by = createProperty(NS, "qualified_by");
+ public final IRI qualifies = createProperty(NS, "qualifies");
+ public final IRI qualitatively_comparable = createProperty(NS, "qualitatively_comparable");
+ public final IRI stated_by = createProperty(NS, "stated_by");
+ public final IRI states = createProperty(NS, "states");
+ public final IRI towards = createProperty(NS, "towards");
+ public final IRI utterer = createProperty(NS, "utterer");
+ public final IRI utters = createProperty(NS, "utters");
+ public final IRI creation = createProperty(NS, "creation");
+ public final IRI counts_as = createProperty(NS, "counts_as");
+ public final IRI imposed_on = createProperty(NS, "imposed_on");
+ public final IRI played_by = createProperty(NS, "played_by");
+ public final IRI plays = createProperty(NS, "plays");
+
private LKIFCoreExpression() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalAction.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalAction.java
index 0553b9a..b2ca066 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalAction.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalAction.java
@@ -19,66 +19,69 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The legal action module extends the action module with a number of
- * legal concepts related to action and agent, such as public acts,
- * public bodies, legal person, natural person etc.</p>
+ * <p>
+ * The legal action module extends the action module with a number of legal concepts related to action and agent, such
+ * as public acts, public bodies, legal person, natural person etc.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreLegalAction extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/legal-action.owl#";
-
+
private static LKIFCoreLegalAction instance;
-
+
public static LKIFCoreLegalAction getInstance() {
- if(instance == null) {
- instance = new LKIFCoreLegalAction();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreLegalAction();
+ }
+ return instance;
+ }
+
////////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/legal-action.owl# */
////////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Limited_Company = createClass(NS, "Limited_Company");
- public final IRI Private_Legal_Person = createClass(NS, "Private_Legal_Person");
- public final IRI Society = createClass(NS, "Society");
- public final IRI Natural_Person = createClass(NS, "Natural_Person");
- public final IRI Mandate = createClass(NS, "Mandate");
- public final IRI Corporation = createClass(NS, "Corporation");
- public final IRI Legal_Person = createClass(NS, "Legal_Person");
- public final IRI Public_Body = createClass(NS, "Public_Body");
- public final IRI Foundation = createClass(NS, "Foundation");
- public final IRI Co_operative = createClass(NS, "Co-operative");
- public final IRI Legislative_Body = createClass(NS, "Legislative_Body");
- public final IRI Delegation = createClass(NS, "Delegation");
- public final IRI Legal_Speech_Act = createClass(NS, "Legal_Speech_Act");
- public final IRI Public_Act = createClass(NS, "Public_Act");
- public final IRI Company = createClass(NS, "Company");
- public final IRI Decision = createClass(NS, "Decision");
- public final IRI Public_Limited_Company = createClass(NS, "Public_Limited_Company");
- public final IRI Incorporated = createClass(NS, "Incorporated");
- public final IRI Act_of_Law = createClass(NS, "Act_of_Law");
- public final IRI Association = createClass(NS, "Association");
- public final IRI Assignment = createClass(NS, "Assignment");
- public final IRI Unincorporated = createClass(NS, "Unincorporated");
-
+ public final IRI Limited_Company = createClass(NS, "Limited_Company");
+ public final IRI Private_Legal_Person = createClass(NS, "Private_Legal_Person");
+ public final IRI Society = createClass(NS, "Society");
+ public final IRI Natural_Person = createClass(NS, "Natural_Person");
+ public final IRI Mandate = createClass(NS, "Mandate");
+ public final IRI Corporation = createClass(NS, "Corporation");
+ public final IRI Legal_Person = createClass(NS, "Legal_Person");
+ public final IRI Public_Body = createClass(NS, "Public_Body");
+ public final IRI Foundation = createClass(NS, "Foundation");
+ public final IRI Co_operative = createClass(NS, "Co-operative");
+ public final IRI Legislative_Body = createClass(NS, "Legislative_Body");
+ public final IRI Delegation = createClass(NS, "Delegation");
+ public final IRI Legal_Speech_Act = createClass(NS, "Legal_Speech_Act");
+ public final IRI Public_Act = createClass(NS, "Public_Act");
+ public final IRI Company = createClass(NS, "Company");
+ public final IRI Decision = createClass(NS, "Decision");
+ public final IRI Public_Limited_Company = createClass(NS, "Public_Limited_Company");
+ public final IRI Incorporated = createClass(NS, "Incorporated");
+ public final IRI Act_of_Law = createClass(NS, "Act_of_Law");
+ public final IRI Association = createClass(NS, "Association");
+ public final IRI Assignment = createClass(NS, "Assignment");
+ public final IRI Unincorporated = createClass(NS, "Unincorporated");
+
// RESOURCES
-
+
// PROPERTIES
-
+
private LKIFCoreLegalAction() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalRole.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalRole.java
index 37f0056..cf2f6ee 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalRole.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreLegalRole.java
@@ -19,46 +19,50 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The legal role module extends the role module with a small number
- * of legal concepts related to roles, legal professions etc.</p>
+ * <p>
+ * The legal role module extends the role module with a small number of legal concepts related to roles, legal
+ * professions etc.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreLegalRole extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/legal-role.owl#";
-
+
private static LKIFCoreLegalRole instance;
-
+
public static LKIFCoreLegalRole getInstance() {
- if(instance == null) {
- instance = new LKIFCoreLegalRole();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreLegalRole();
+ }
+ return instance;
+ }
+
//////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/legal-role.owl# */
//////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Social_Legal_Role = createClass(NS, "Social_Legal_Role");
- public final IRI Legal_Role = createClass(NS, "Legal_Role");
- public final IRI Professional_Legal_Role = createClass(NS, "Professional_Legal_Role");
-
+ public final IRI Social_Legal_Role = createClass(NS, "Social_Legal_Role");
+ public final IRI Legal_Role = createClass(NS, "Legal_Role");
+ public final IRI Professional_Legal_Role = createClass(NS, "Professional_Legal_Role");
+
// RESOURCES
-
+
// PROPERTIES
-
+
private LKIFCoreLegalRole() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreMereology.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreMereology.java
index 0bc650b..5f57789 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreMereology.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreMereology.java
@@ -19,63 +19,66 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The mereology module defines mereological concepts such as parts
- * and wholes, and typical mereological relations such as part of,
- * component of, containment, membership etc.</p>
+ * <p>
+ * The mereology module defines mereological concepts such as parts and wholes, and typical mereological relations such
+ * as part of, component of, containment, membership etc.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreMereology extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/mereology.owl#";
-
+
private static LKIFCoreMereology instance;
-
+
public static LKIFCoreMereology getInstance() {
- if(instance == null) {
- instance = new LKIFCoreMereology();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreMereology();
+ }
+ return instance;
+ }
+
/////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/mereology.owl */
/////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Atom = createClass(NS, "Atom");
- public final IRI Composition = createClass(NS, "Composition");
- public final IRI Pair = createClass(NS, "Pair");
- public final IRI Part = createClass(NS, "Part");
- public final IRI Whole = createClass(NS, "Whole");
-
+ public final IRI Atom = createClass(NS, "Atom");
+ public final IRI Composition = createClass(NS, "Composition");
+ public final IRI Pair = createClass(NS, "Pair");
+ public final IRI Part = createClass(NS, "Part");
+ public final IRI Whole = createClass(NS, "Whole");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI component = createProperty(NS, "component");
- public final IRI component_of = createProperty(NS, "component_of");
- public final IRI composed_of = createProperty(NS, "composed_of");
- public final IRI composes = createProperty(NS, "composes");
- public final IRI contained_in = createProperty(NS, "contained_in");
- public final IRI contains = createProperty(NS, "contains");
- public final IRI direct_part = createProperty(NS, "direct_part");
- public final IRI direct_part_of = createProperty(NS, "direct_part_of");
- public final IRI member = createProperty(NS, "member");
- public final IRI member_of = createProperty(NS, "member_of");
- public final IRI part = createProperty(NS, "part");
- public final IRI part_of = createProperty(NS, "part_of");
- public final IRI strict_part = createProperty(NS, "strict_part");
- public final IRI strict_part_of = createProperty(NS, "strict_part_of");
-
+ public final IRI component = createProperty(NS, "component");
+ public final IRI component_of = createProperty(NS, "component_of");
+ public final IRI composed_of = createProperty(NS, "composed_of");
+ public final IRI composes = createProperty(NS, "composes");
+ public final IRI contained_in = createProperty(NS, "contained_in");
+ public final IRI contains = createProperty(NS, "contains");
+ public final IRI direct_part = createProperty(NS, "direct_part");
+ public final IRI direct_part_of = createProperty(NS, "direct_part_of");
+ public final IRI member = createProperty(NS, "member");
+ public final IRI member_of = createProperty(NS, "member_of");
+ public final IRI part = createProperty(NS, "part");
+ public final IRI part_of = createProperty(NS, "part_of");
+ public final IRI strict_part = createProperty(NS, "strict_part");
+ public final IRI strict_part_of = createProperty(NS, "strict_part_of");
+
private LKIFCoreMereology() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreNorm.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreNorm.java
index 1d40628..2a92ffe 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreNorm.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreNorm.java
@@ -19,113 +19,115 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The norm module is an extension primarily on the expression
- * module where norms are defined as qualifications. Please
- * refer to Deliverable 1.1 for a more in-depth description
- * of the underlying theory. It furthermore defines a number of
- * legal sources, e.g. legal documents, customary law etc., and a
- * typology of rights and powers, cf. Sartor (2006), Rubino et al. (2006)</p>
+ * <p>
+ * The norm module is an extension primarily on the expression module where norms are defined as qualifications. Please
+ * refer to Deliverable 1.1 for a more in-depth description of the underlying theory. It furthermore defines a number of
+ * legal sources, e.g. legal documents, customary law etc., and a typology of rights and powers, cf. Sartor (2006),
+ * Rubino et al. (2006)
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreNorm extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/norm.owl#";
-
+
private static LKIFCoreNorm instance;
-
+
public static LKIFCoreNorm getInstance() {
- if(instance == null) {
- instance = new LKIFCoreNorm();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreNorm();
+ }
+ return instance;
+ }
+
///////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/norm.owl */
///////////////////////////////////////////////////////
// CLASSES
- public final IRI Hohfeldian_Power = createClass(NS, "Hohfeldian_Power");
- public final IRI Normatively_Qualified = createClass(NS, "Normatively_Qualified");
- public final IRI Code_of_Conduct = createClass(NS, "Code_of_Conduct");
- public final IRI Regulation = createClass(NS, "Regulation");
- public final IRI Soft_Law = createClass(NS, "Soft_Law");
- public final IRI Strictly_Disallowed = createClass(NS, "Strictly_Disallowed");
- public final IRI Permissive_Right = createClass(NS, "Permissive_Right");
- public final IRI Proclamation = createClass(NS, "Proclamation");
- public final IRI Legal_Expression = createClass(NS, "Legal_Expression");
- public final IRI Qualificatory_Expression = createClass(NS, "Qualificatory_Expression");
- public final IRI Enabling_Power = createClass(NS, "Enabling_Power");
- public final IRI Existential_Expression = createClass(NS, "Existential_Expression");
- public final IRI Persuasive_Precedent = createClass(NS, "Persuasive_Precedent");
- public final IRI Belief_In_Violation = createClass(NS, "Belief_In_Violation");
- public final IRI Strictly_Allowed = createClass(NS, "Strictly_Allowed");
- public final IRI Legal_Doctrine = createClass(NS, "Legal_Doctrine");
- public final IRI Resolution = createClass(NS, "Resolution");
- public final IRI Evaluative_Expression = createClass(NS, "Evaluative_Expression");
- public final IRI Liberty_Right = createClass(NS, "Liberty_Right");
- public final IRI Declarative_Power = createClass(NS, "Declarative_Power");
- public final IRI Contract = createClass(NS, "Contract");
- public final IRI Custom = createClass(NS, "Custom");
- public final IRI Exclusionary_Right = createClass(NS, "Exclusionary_Right");
- public final IRI International_Agreement = createClass(NS, "International_Agreement");
- public final IRI Customary_Law = createClass(NS, "Customary_Law");
- public final IRI Action_Power = createClass(NS, "Action_Power");
- public final IRI Legal_Source = createClass(NS, "Legal_Source");
- public final IRI Statute = createClass(NS, "Statute");
- public final IRI International_Arbitration = createClass(NS, "International_Arbitration");
- public final IRI Immunity = createClass(NS, "Immunity");
- public final IRI Treaty = createClass(NS, "Treaty");
- public final IRI Mandatory_Precedent = createClass(NS, "Mandatory_Precedent");
- public final IRI Code = createClass(NS, "Code");
- public final IRI Allowed = createClass(NS, "Allowed");
- public final IRI Observation_of_Violation = createClass(NS, "Observation_of_Violation");
- public final IRI Legal_Document = createClass(NS, "Legal_Document");
- public final IRI Potestative_Expression = createClass(NS, "Potestative_Expression");
- public final IRI Norm = createClass(NS, "Norm");
- public final IRI Potestative_Right = createClass(NS, "Potestative_Right");
- public final IRI Allowed_And_Disallowed = createClass(NS, "Allowed_And_Disallowed");
- public final IRI Obligation = createClass(NS, "Obligation");
- public final IRI Disallowed_Intention = createClass(NS, "Disallowed_Intention");
- public final IRI Permission = createClass(NS, "Permission");
- public final IRI Liability_Right = createClass(NS, "Liability_Right");
- public final IRI Right = createClass(NS, "Right");
- public final IRI Obliged = createClass(NS, "Obliged");
- public final IRI Non_binding_International_Agreement = createClass(NS, "Non-binding_International_Agreement");
- public final IRI Directive = createClass(NS, "Directive");
- public final IRI Disallowed = createClass(NS, "Disallowed");
- public final IRI Definitional_Expression = createClass(NS, "Definitional_Expression");
- public final IRI Prohibition = createClass(NS, "Prohibition");
- public final IRI Precedent = createClass(NS, "Precedent");
- public final IRI Obligative_Right = createClass(NS, "Obligative_Right");
-
+ public final IRI Hohfeldian_Power = createClass(NS, "Hohfeldian_Power");
+ public final IRI Normatively_Qualified = createClass(NS, "Normatively_Qualified");
+ public final IRI Code_of_Conduct = createClass(NS, "Code_of_Conduct");
+ public final IRI Regulation = createClass(NS, "Regulation");
+ public final IRI Soft_Law = createClass(NS, "Soft_Law");
+ public final IRI Strictly_Disallowed = createClass(NS, "Strictly_Disallowed");
+ public final IRI Permissive_Right = createClass(NS, "Permissive_Right");
+ public final IRI Proclamation = createClass(NS, "Proclamation");
+ public final IRI Legal_Expression = createClass(NS, "Legal_Expression");
+ public final IRI Qualificatory_Expression = createClass(NS, "Qualificatory_Expression");
+ public final IRI Enabling_Power = createClass(NS, "Enabling_Power");
+ public final IRI Existential_Expression = createClass(NS, "Existential_Expression");
+ public final IRI Persuasive_Precedent = createClass(NS, "Persuasive_Precedent");
+ public final IRI Belief_In_Violation = createClass(NS, "Belief_In_Violation");
+ public final IRI Strictly_Allowed = createClass(NS, "Strictly_Allowed");
+ public final IRI Legal_Doctrine = createClass(NS, "Legal_Doctrine");
+ public final IRI Resolution = createClass(NS, "Resolution");
+ public final IRI Evaluative_Expression = createClass(NS, "Evaluative_Expression");
+ public final IRI Liberty_Right = createClass(NS, "Liberty_Right");
+ public final IRI Declarative_Power = createClass(NS, "Declarative_Power");
+ public final IRI Contract = createClass(NS, "Contract");
+ public final IRI Custom = createClass(NS, "Custom");
+ public final IRI Exclusionary_Right = createClass(NS, "Exclusionary_Right");
+ public final IRI International_Agreement = createClass(NS, "International_Agreement");
+ public final IRI Customary_Law = createClass(NS, "Customary_Law");
+ public final IRI Action_Power = createClass(NS, "Action_Power");
+ public final IRI Legal_Source = createClass(NS, "Legal_Source");
+ public final IRI Statute = createClass(NS, "Statute");
+ public final IRI International_Arbitration = createClass(NS, "International_Arbitration");
+ public final IRI Immunity = createClass(NS, "Immunity");
+ public final IRI Treaty = createClass(NS, "Treaty");
+ public final IRI Mandatory_Precedent = createClass(NS, "Mandatory_Precedent");
+ public final IRI Code = createClass(NS, "Code");
+ public final IRI Allowed = createClass(NS, "Allowed");
+ public final IRI Observation_of_Violation = createClass(NS, "Observation_of_Violation");
+ public final IRI Legal_Document = createClass(NS, "Legal_Document");
+ public final IRI Potestative_Expression = createClass(NS, "Potestative_Expression");
+ public final IRI Norm = createClass(NS, "Norm");
+ public final IRI Potestative_Right = createClass(NS, "Potestative_Right");
+ public final IRI Allowed_And_Disallowed = createClass(NS, "Allowed_And_Disallowed");
+ public final IRI Obligation = createClass(NS, "Obligation");
+ public final IRI Disallowed_Intention = createClass(NS, "Disallowed_Intention");
+ public final IRI Permission = createClass(NS, "Permission");
+ public final IRI Liability_Right = createClass(NS, "Liability_Right");
+ public final IRI Right = createClass(NS, "Right");
+ public final IRI Obliged = createClass(NS, "Obliged");
+ public final IRI Non_binding_International_Agreement = createClass(NS, "Non-binding_International_Agreement");
+ public final IRI Directive = createClass(NS, "Directive");
+ public final IRI Disallowed = createClass(NS, "Disallowed");
+ public final IRI Definitional_Expression = createClass(NS, "Definitional_Expression");
+ public final IRI Prohibition = createClass(NS, "Prohibition");
+ public final IRI Precedent = createClass(NS, "Precedent");
+ public final IRI Obligative_Right = createClass(NS, "Obligative_Right");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI normatively_comparable = createProperty(NS, "normatively_comparable");
- public final IRI normatively_equivalent_or_better = createProperty(NS, "normatively_equivalent_or_better");
- public final IRI disallows = createProperty(NS, "disallows");
- public final IRI normatively_strictly_worse = createProperty(NS, "normatively_strictly_worse");
- public final IRI normatively_not_equivalent = createProperty(NS, "normatively_not_equivalent");
- public final IRI normatively_strictly_better = createProperty(NS, "normatively_strictly_better");
- public final IRI allowed_by = createProperty(NS, "allowed_by");
- public final IRI disallowed_by = createProperty(NS, "disallowed_by");
- public final IRI allows = createProperty(NS, "allows");
- public final IRI normatively_equivalent_or_worse = createProperty(NS, "normatively_equivalent_or_worse");
- public final IRI commands = createProperty(NS, "commands");
- public final IRI commanded_by = createProperty(NS, "commanded_by");
- public final IRI strictly_equivalent = createProperty(NS, "strictly_equivalent");
-
+ public final IRI normatively_comparable = createProperty(NS, "normatively_comparable");
+ public final IRI normatively_equivalent_or_better = createProperty(NS, "normatively_equivalent_or_better");
+ public final IRI disallows = createProperty(NS, "disallows");
+ public final IRI normatively_strictly_worse = createProperty(NS, "normatively_strictly_worse");
+ public final IRI normatively_not_equivalent = createProperty(NS, "normatively_not_equivalent");
+ public final IRI normatively_strictly_better = createProperty(NS, "normatively_strictly_better");
+ public final IRI allowed_by = createProperty(NS, "allowed_by");
+ public final IRI disallowed_by = createProperty(NS, "disallowed_by");
+ public final IRI allows = createProperty(NS, "allows");
+ public final IRI normatively_equivalent_or_worse = createProperty(NS, "normatively_equivalent_or_worse");
+ public final IRI commands = createProperty(NS, "commands");
+ public final IRI commanded_by = createProperty(NS, "commanded_by");
+ public final IRI strictly_equivalent = createProperty(NS, "strictly_equivalent");
+
private LKIFCoreNorm() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreProcess.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreProcess.java
index 1c55f67..19508f7 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreProcess.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreProcess.java
@@ -19,63 +19,66 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The process module extends the LKIF top ontology module with
- * a definition of changes, processes (being causal changes) and
- * physical objects. It introduces a limited set of properties for
- * describing participant roles of processes.</p>
+ * <p>
+ * The process module extends the LKIF top ontology module with a definition of changes, processes (being causal
+ * changes) and physical objects. It introduces a limited set of properties for describing participant roles of
+ * processes.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreProcess extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/process.owl#";
-
+
private static LKIFCoreProcess instance;
-
+
public static LKIFCoreProcess getInstance() {
- if(instance == null) {
- instance = new LKIFCoreProcess();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreProcess();
+ }
+ return instance;
+ }
+
//////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/process.owl */
//////////////////////////////////////////////////////////
// CLASSES
- public final IRI Change = createClass(NS, "Change");
- public final IRI Continuation = createClass(NS, "Continuation");
- public final IRI Initiation = createClass(NS, "Initiation");
- public final IRI Mental_Process = createClass(NS, "Mental_Process");
- public final IRI Physical_Object = createClass(NS, "Physical_Object");
- public final IRI Physical_Process = createClass(NS, "Physical_Process");
- public final IRI Process = createClass(NS, "Process");
- public final IRI Termination = createClass(NS, "Termination");
-
+ public final IRI Change = createClass(NS, "Change");
+ public final IRI Continuation = createClass(NS, "Continuation");
+ public final IRI Initiation = createClass(NS, "Initiation");
+ public final IRI Mental_Process = createClass(NS, "Mental_Process");
+ public final IRI Physical_Object = createClass(NS, "Physical_Object");
+ public final IRI Physical_Process = createClass(NS, "Physical_Process");
+ public final IRI Process = createClass(NS, "Process");
+ public final IRI Termination = createClass(NS, "Termination");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI created_by = createProperty(NS, "created_by");
- public final IRI creation = createProperty(NS, "creation");
- public final IRI participant = createProperty(NS, "participant");
- public final IRI participant_in = createProperty(NS, "participant_in");
- public final IRI requirement = createProperty(NS, "requirement");
- public final IRI requirement_of = createProperty(NS, "requirement_of");
- public final IRI resource = createProperty(NS, "resource");
- public final IRI resource_for = createProperty(NS, "resource_for ");
- public final IRI result = createProperty(NS, "result");
- public final IRI result_of = createProperty(NS, "result_of");
-
+ public final IRI created_by = createProperty(NS, "created_by");
+ public final IRI creation = createProperty(NS, "creation");
+ public final IRI participant = createProperty(NS, "participant");
+ public final IRI participant_in = createProperty(NS, "participant_in");
+ public final IRI requirement = createProperty(NS, "requirement");
+ public final IRI requirement_of = createProperty(NS, "requirement_of");
+ public final IRI resource = createProperty(NS, "resource");
+ public final IRI resource_for = createProperty(NS, "resource_for ");
+ public final IRI result = createProperty(NS, "result");
+ public final IRI result_of = createProperty(NS, "result_of");
+
private LKIFCoreProcess() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRelativePlaces.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRelativePlaces.java
index fe21cb5..a23b1f7 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRelativePlaces.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRelativePlaces.java
@@ -19,63 +19,66 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The place module partially implements the theory of relative
- * places (Donnelly, 2005) in OWL DL.</p>
+ * <p>
+ * The place module partially implements the theory of relative places (Donnelly, 2005) in OWL DL.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreRelativePlaces extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/relative-places.owl#";
-
+
private static LKIFCoreRelativePlaces instance;
-
+
public static LKIFCoreRelativePlaces getInstance() {
- if(instance == null) {
- instance = new LKIFCoreRelativePlaces();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreRelativePlaces();
+ }
+ return instance;
+ }
+
//////////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/relative-places.owl */
//////////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Absolute_Place = createClass(NS, "Absolute_Place");
- public final IRI Comprehensive_Place = createClass(NS, "Comprehensive_Place");
- public final IRI Location_Complex = createClass(NS, "Location_Complex");
- public final IRI Place = createClass(NS, "Place");
- public final IRI Relative_Place = createClass(NS, "Relative_Place");
-
+ public final IRI Absolute_Place = createClass(NS, "Absolute_Place");
+ public final IRI Comprehensive_Place = createClass(NS, "Comprehensive_Place");
+ public final IRI Location_Complex = createClass(NS, "Location_Complex");
+ public final IRI Place = createClass(NS, "Place");
+ public final IRI Relative_Place = createClass(NS, "Relative_Place");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI abut = createProperty(NS, "abut");
- public final IRI connect = createProperty(NS, "connect");
- public final IRI cover = createProperty(NS, "cover");
- public final IRI covered_by = createProperty(NS, "covered_by");
- public final IRI exactly_coincide = createProperty(NS, "exactly_coincide");
- public final IRI externally_connect = createProperty(NS, "externally_connect");
- public final IRI in = createProperty(NS, "in");
- public final IRI location_complex = createProperty(NS, "location_complex");
- public final IRI location_complex_for = createProperty(NS, "location_complex_for");
- public final IRI meet = createProperty(NS, "meet");
- public final IRI overlap = createProperty(NS, "overlap");
- public final IRI partially_coincide = createProperty(NS, "partially_coincide");
- public final IRI relatively_fixed = createProperty(NS, "relatively_fixed");
- public final IRI spatial_reference = createProperty(NS, "spatial_reference");
- public final IRI spatial_relation = createProperty(NS, "spatial_relation");
-
+ public final IRI abut = createProperty(NS, "abut");
+ public final IRI connect = createProperty(NS, "connect");
+ public final IRI cover = createProperty(NS, "cover");
+ public final IRI covered_by = createProperty(NS, "covered_by");
+ public final IRI exactly_coincide = createProperty(NS, "exactly_coincide");
+ public final IRI externally_connect = createProperty(NS, "externally_connect");
+ public final IRI in = createProperty(NS, "in");
+ public final IRI location_complex = createProperty(NS, "location_complex");
+ public final IRI location_complex_for = createProperty(NS, "location_complex_for");
+ public final IRI meet = createProperty(NS, "meet");
+ public final IRI overlap = createProperty(NS, "overlap");
+ public final IRI partially_coincide = createProperty(NS, "partially_coincide");
+ public final IRI relatively_fixed = createProperty(NS, "relatively_fixed");
+ public final IRI spatial_reference = createProperty(NS, "spatial_reference");
+ public final IRI spatial_relation = createProperty(NS, "spatial_relation");
+
private LKIFCoreRelativePlaces() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRole.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRole.java
index a968da2..243754d 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRole.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRole.java
@@ -19,56 +19,59 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The role module defines a typology of roles (epistemic roles,
- * functions, person roles, organisation roles) and the
- * plays-property for relating a role filler to a role.</p>
+ * <p>
+ * The role module defines a typology of roles (epistemic roles, functions, person roles, organisation roles) and the
+ * plays-property for relating a role filler to a role.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreRole extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/role.owl#";
-
+
private static LKIFCoreRole instance;
-
+
public static LKIFCoreRole getInstance() {
- if(instance == null) {
- instance = new LKIFCoreRole();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreRole();
+ }
+ return instance;
+ }
+
///////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/role.owl */
///////////////////////////////////////////////////////
// CLASSES
- public final IRI Epistemic_Role = createClass(NS, "Epistemic_Role");
- public final IRI Function = createClass(NS, "Function");
- public final IRI Organisation_Role = createClass(NS, "Organisation_Role");
- public final IRI Person_Role = createClass(NS, "Person_Role");
- public final IRI Role = createClass(NS, "Role");
- public final IRI Social_Role = createClass(NS, "Social_Role");
- public final IRI Subjective_Entity = createClass(NS, "Subjective_Entity ");
-
+ public final IRI Epistemic_Role = createClass(NS, "Epistemic_Role");
+ public final IRI Function = createClass(NS, "Function");
+ public final IRI Organisation_Role = createClass(NS, "Organisation_Role");
+ public final IRI Person_Role = createClass(NS, "Person_Role");
+ public final IRI Role = createClass(NS, "Role");
+ public final IRI Social_Role = createClass(NS, "Social_Role");
+ public final IRI Subjective_Entity = createClass(NS, "Subjective_Entity ");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI context = createProperty(NS, "context");
- public final IRI counts_as = createProperty(NS, "counts_as");
- public final IRI imposed_on = createProperty(NS, "imposed_on");
- public final IRI played_by = createProperty(NS, "played_by");
- public final IRI plays = createProperty(NS, "plays");
-
+ public final IRI context = createProperty(NS, "context");
+ public final IRI counts_as = createProperty(NS, "counts_as");
+ public final IRI imposed_on = createProperty(NS, "imposed_on");
+ public final IRI played_by = createProperty(NS, "played_by");
+ public final IRI plays = createProperty(NS, "plays");
+
private LKIFCoreRole() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRules.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRules.java
index 1d0eabd..62eacac 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreRules.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreRules.java
@@ -19,53 +19,55 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The rules & argumentation module defines roles central to
- * argumentation, and describes the vocabulary for LKIF rules
- * as defined in Deliverable 1.1, chapter 5. The module
- * leaves room for further extension to complex argumentation
- * frameworks (AIF, Carneades).</p>
+ * <p>
+ * The rules & argumentation module defines roles central to argumentation, and describes the vocabulary for LKIF
+ * rules as defined in Deliverable 1.1, chapter 5. The module leaves room for further extension to complex argumentation
+ * frameworks (AIF, Carneades).
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreRules extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/lkif-rules.owl#";
-
+
private static LKIFCoreRules instance;
-
+
public static LKIFCoreRules getInstance() {
- if(instance == null) {
- instance = new LKIFCoreRules();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreRules();
+ }
+ return instance;
+ }
+
/////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/lkif-rules.owl */
/////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Valid_Rule = createClass(NS, "Valid_Rule");
- public final IRI Rule = createClass(NS, "Rule");
-
+ public final IRI Valid_Rule = createClass(NS, "Valid_Rule");
+ public final IRI Rule = createClass(NS, "Rule");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI rule_predicate = createProperty(NS, "rule_predicate");
- public final IRI prior = createProperty(NS, "prior");
- public final IRI excluded = createProperty(NS, "excluded");
- public final IRI applies = createProperty(NS, "applies");
- public final IRI rebuts = createProperty(NS, "rebuts");
-
+ public final IRI rule_predicate = createProperty(NS, "rule_predicate");
+ public final IRI prior = createProperty(NS, "prior");
+ public final IRI excluded = createProperty(NS, "excluded");
+ public final IRI applies = createProperty(NS, "applies");
+ public final IRI rebuts = createProperty(NS, "rebuts");
+
private LKIFCoreRules() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTime.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTime.java
index 7a21404..586b49b 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTime.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTime.java
@@ -19,58 +19,61 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The time module provides an OWL DL implementation of the
- * theory of time by Allen (1984).</p>
+ * <p>
+ * The time module provides an OWL DL implementation of the theory of time by Allen (1984).
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreTime extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/time.owl#";
-
+
private static LKIFCoreTime instance;
-
+
public static LKIFCoreTime getInstance() {
- if(instance == null) {
- instance = new LKIFCoreTime();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreTime();
+ }
+ return instance;
+ }
+
///////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/time.owl */
///////////////////////////////////////////////////////
// CLASSES
- public final IRI Interval = createClass(NS, "Interval");
- public final IRI Moment = createClass(NS, "Moment");
- public final IRI Pair_Of_Periods = createClass(NS, "Pair_Of_Periods");
- public final IRI Temporal_Occurrence = createClass(NS, "Temporal_Occurrence");
-
+ public final IRI Interval = createClass(NS, "Interval");
+ public final IRI Moment = createClass(NS, "Moment");
+ public final IRI Pair_Of_Periods = createClass(NS, "Pair_Of_Periods");
+ public final IRI Temporal_Occurrence = createClass(NS, "Temporal_Occurrence");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI after = createProperty(NS, "after");
- public final IRI before = createProperty(NS, "before");
- public final IRI between = createProperty(NS, "between");
- public final IRI during = createProperty(NS, "during");
- public final IRI finishes = createProperty(NS, "finishes");
- public final IRI immediately_after = createProperty(NS, "immediately_after");
- public final IRI immediately_before = createProperty(NS, "immediately_before");
- public final IRI overlap = createProperty(NS, "overlap");
- public final IRI preceeds = createProperty(NS, "preceeds");
- public final IRI starts = createProperty(NS, "starts");
- public final IRI temporal_relation = createProperty(NS, "temporal_relation");
-
+ public final IRI after = createProperty(NS, "after");
+ public final IRI before = createProperty(NS, "before");
+ public final IRI between = createProperty(NS, "between");
+ public final IRI during = createProperty(NS, "during");
+ public final IRI finishes = createProperty(NS, "finishes");
+ public final IRI immediately_after = createProperty(NS, "immediately_after");
+ public final IRI immediately_before = createProperty(NS, "immediately_before");
+ public final IRI overlap = createProperty(NS, "overlap");
+ public final IRI preceeds = createProperty(NS, "preceeds");
+ public final IRI starts = createProperty(NS, "starts");
+ public final IRI temporal_relation = createProperty(NS, "temporal_relation");
+
private LKIFCoreTime() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTimeModification.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTimeModification.java
index 3b2897f..5025353 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTimeModification.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTimeModification.java
@@ -19,103 +19,105 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The modification module is both an extension of the time module
- * and the legal action module. The time module is extended with numerous
- * intervals and moments describing the efficacy and being in force of
- * legal documents. The action module is extended with a typology of modifications.
- * These concepts are described in further detail in Deliverable 3.2 of
- * the ESTRELLA project.</p>
+ * <p>
+ * The modification module is both an extension of the time module and the legal action module. The time module is
+ * extended with numerous intervals and moments describing the efficacy and being in force of legal documents. The
+ * action module is extended with a typology of modifications. These concepts are described in further detail in
+ * Deliverable 3.2 of the ESTRELLA project.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreTimeModification extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/time-modification.owl#";
-
+
private static LKIFCoreTimeModification instance;
-
+
public static LKIFCoreTimeModification getInstance() {
- if(instance == null) {
- instance = new LKIFCoreTimeModification();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreTimeModification();
+ }
+ return instance;
+ }
+
////////////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/time-modification.owl */
////////////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Semantic_Annotation = createClass(NS, "Semantic_Annotation");
- public final IRI Modification = createClass(NS, "Modification");
- public final IRI Transposition = createClass(NS, "Transposition");
- public final IRI Ultractivity = createClass(NS, "Ultractivity");
- public final IRI Annulment = createClass(NS, "Annulment");
- public final IRI End_efficacy = createClass(NS, "End_efficacy");
- public final IRI Efficacy_Modification = createClass(NS, "Efficacy_Modification ");
- public final IRI Modification_of_System = createClass(NS, "Modification_of_System ");
- public final IRI Dynamic_Temporal_Entity = createClass(NS, "Dynamic_Temporal_Entity ");
- public final IRI Remaking = createClass(NS, "Remaking ");
- public final IRI Application = createClass(NS, "Application ");
- public final IRI Ratification = createClass(NS, "Ratification ");
- public final IRI Textual_Modification = createClass(NS, "Textual_Modification ");
- public final IRI Prorogation_in_Force = createClass(NS, "Prorogation_in_Force ");
- public final IRI Application_Date = createClass(NS, "Application_Date ");
- public final IRI Retroactivity = createClass(NS, "Retroactivity ");
- public final IRI Modification_of_Term = createClass(NS, "Modification_of_Term ");
- public final IRI Efficacy_Interval = createClass(NS, "Efficacy_Interval ");
- public final IRI Start_Efficacy = createClass(NS, "Start_Efficacy ");
- public final IRI Substitution = createClass(NS, "Substitution ");
- public final IRI Temporal_Modification = createClass(NS, "Temporal_Modification ");
- public final IRI Suspension = createClass(NS, "Suspension ");
- public final IRI In_Force_Modification = createClass(NS, "In_Force_Modification ");
- public final IRI Publication_Date = createClass(NS, "Publication_Date ");
- public final IRI Exception = createClass(NS, "Exception ");
- public final IRI Modification_of_Meaning = createClass(NS, "Modification_of_Meaning ");
- public final IRI Static_Temporal_Entity = createClass(NS, "Static_Temporal_Entity ");
- public final IRI End_in_Force = createClass(NS, "End_in_Force ");
- public final IRI Start_in_Force = createClass(NS, "Start_in_Force ");
- public final IRI Integration = createClass(NS, "Integration ");
- public final IRI Application_Interval = createClass(NS, "Application_Interval ");
- public final IRI Interpretation = createClass(NS, "Interpretation ");
- public final IRI Deregulation = createClass(NS, "Deregulation ");
- public final IRI In_Force_Interval = createClass(NS, "In_Force_Interval ");
- public final IRI Repeal = createClass(NS, "Repeal ");
- public final IRI Modification_of_Scope = createClass(NS, "Modification_of_Scope ");
- public final IRI Delivery_Date = createClass(NS, "Delivery_Date ");
- public final IRI Enter_in_Force_Date = createClass(NS, "Enter_in_Force_Date ");
- public final IRI Variation = createClass(NS, "Variation ");
- public final IRI Existence_Date = createClass(NS, "Existence_Date ");
- public final IRI Relocation = createClass(NS, "Relocation ");
- public final IRI Prorogation_Efficacy = createClass(NS, "Prorogation_Efficacy ");
- public final IRI Extension = createClass(NS, "Extension ");
- public final IRI Renewal = createClass(NS, "Renewal ");
-
+ public final IRI Semantic_Annotation = createClass(NS, "Semantic_Annotation");
+ public final IRI Modification = createClass(NS, "Modification");
+ public final IRI Transposition = createClass(NS, "Transposition");
+ public final IRI Ultractivity = createClass(NS, "Ultractivity");
+ public final IRI Annulment = createClass(NS, "Annulment");
+ public final IRI End_efficacy = createClass(NS, "End_efficacy");
+ public final IRI Efficacy_Modification = createClass(NS, "Efficacy_Modification ");
+ public final IRI Modification_of_System = createClass(NS, "Modification_of_System ");
+ public final IRI Dynamic_Temporal_Entity = createClass(NS, "Dynamic_Temporal_Entity ");
+ public final IRI Remaking = createClass(NS, "Remaking ");
+ public final IRI Application = createClass(NS, "Application ");
+ public final IRI Ratification = createClass(NS, "Ratification ");
+ public final IRI Textual_Modification = createClass(NS, "Textual_Modification ");
+ public final IRI Prorogation_in_Force = createClass(NS, "Prorogation_in_Force ");
+ public final IRI Application_Date = createClass(NS, "Application_Date ");
+ public final IRI Retroactivity = createClass(NS, "Retroactivity ");
+ public final IRI Modification_of_Term = createClass(NS, "Modification_of_Term ");
+ public final IRI Efficacy_Interval = createClass(NS, "Efficacy_Interval ");
+ public final IRI Start_Efficacy = createClass(NS, "Start_Efficacy ");
+ public final IRI Substitution = createClass(NS, "Substitution ");
+ public final IRI Temporal_Modification = createClass(NS, "Temporal_Modification ");
+ public final IRI Suspension = createClass(NS, "Suspension ");
+ public final IRI In_Force_Modification = createClass(NS, "In_Force_Modification ");
+ public final IRI Publication_Date = createClass(NS, "Publication_Date ");
+ public final IRI Exception = createClass(NS, "Exception ");
+ public final IRI Modification_of_Meaning = createClass(NS, "Modification_of_Meaning ");
+ public final IRI Static_Temporal_Entity = createClass(NS, "Static_Temporal_Entity ");
+ public final IRI End_in_Force = createClass(NS, "End_in_Force ");
+ public final IRI Start_in_Force = createClass(NS, "Start_in_Force ");
+ public final IRI Integration = createClass(NS, "Integration ");
+ public final IRI Application_Interval = createClass(NS, "Application_Interval ");
+ public final IRI Interpretation = createClass(NS, "Interpretation ");
+ public final IRI Deregulation = createClass(NS, "Deregulation ");
+ public final IRI In_Force_Interval = createClass(NS, "In_Force_Interval ");
+ public final IRI Repeal = createClass(NS, "Repeal ");
+ public final IRI Modification_of_Scope = createClass(NS, "Modification_of_Scope ");
+ public final IRI Delivery_Date = createClass(NS, "Delivery_Date ");
+ public final IRI Enter_in_Force_Date = createClass(NS, "Enter_in_Force_Date ");
+ public final IRI Variation = createClass(NS, "Variation ");
+ public final IRI Existence_Date = createClass(NS, "Existence_Date ");
+ public final IRI Relocation = createClass(NS, "Relocation ");
+ public final IRI Prorogation_Efficacy = createClass(NS, "Prorogation_Efficacy ");
+ public final IRI Extension = createClass(NS, "Extension ");
+ public final IRI Renewal = createClass(NS, "Renewal ");
+
// RESOURCES
-
+
// PROPERTIES
- public final IRI initial_date = createProperty(NS, "initial_date");
- public final IRI in_force = createProperty(NS, "in_force");
- public final IRI final_date_of = createProperty(NS, "final_date_of");
- public final IRI efficacy = createProperty(NS, "efficacy");
- public final IRI initial_date_of = createProperty(NS, "initial_date_of");
- public final IRI produce_efficacy_modification = createProperty(NS, "produce_efficacy_modification");
- public final IRI duration = createProperty(NS, "duration");
- public final IRI final_date = createProperty(NS, "final_date");
- public final IRI application = createProperty(NS, "application");
- public final IRI date = createProperty(NS, "date");
- public final IRI produce_textual_modification = createProperty(NS, "produce_textual_modification");
- public final IRI produce_inforce_modification = createProperty(NS, "produce_inforce_modification");
-
+ public final IRI initial_date = createProperty(NS, "initial_date");
+ public final IRI in_force = createProperty(NS, "in_force");
+ public final IRI final_date_of = createProperty(NS, "final_date_of");
+ public final IRI efficacy = createProperty(NS, "efficacy");
+ public final IRI initial_date_of = createProperty(NS, "initial_date_of");
+ public final IRI produce_efficacy_modification = createProperty(NS, "produce_efficacy_modification");
+ public final IRI duration = createProperty(NS, "duration");
+ public final IRI final_date = createProperty(NS, "final_date");
+ public final IRI application = createProperty(NS, "application");
+ public final IRI date = createProperty(NS, "date");
+ public final IRI produce_textual_modification = createProperty(NS, "produce_textual_modification");
+ public final IRI produce_inforce_modification = createProperty(NS, "produce_inforce_modification");
+
private LKIFCoreTimeModification() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTop.java b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTop.java
index c0a7266..bb6bd10 100644
--- a/api/src/main/java/org/apache/any23/vocab/LKIFCoreTop.java
+++ b/api/src/main/java/org/apache/any23/vocab/LKIFCoreTop.java
@@ -19,50 +19,53 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a>
- * vocabulary which is a library of ontologies relevant for the legal domain.
- * The library consists of 15 modules, each of which describes a set of closely
- * related concepts from both legal and commonsense domains.</p>
+ * <p>
+ * An implementation of the <a href="https://github.com/RinkeHoekstra/lkif-core">lkif-core</a> vocabulary which is a
+ * library of ontologies relevant for the legal domain. The library consists of 15 modules, each of which describes a
+ * set of closely related concepts from both legal and commonsense domains.
+ * </p>
*
- * <p>The LKIF top ontology is largely based on the top-level of
- * LRI-Core but has less ontological commitment in the sense that
- * it imposes less restrictions on subclasses of the top categories. </p>
+ * <p>
+ * The LKIF top ontology is largely based on the top-level of LRI-Core but has less ontological commitment in the sense
+ * that it imposes less restrictions on subclasses of the top categories.
+ * </p>
*
- * @author lewismc
+ * @author lewismc
*
*/
public class LKIFCoreTop extends Vocabulary {
-
+
/**
* The namespace of the vocabulary as a string.
*/
public static final String NS = "http://www.estrellaproject.org/lkif-core/lkif-top.owl#";
-
+
private static LKIFCoreTop instance;
-
+
public static LKIFCoreTop getInstance() {
- if(instance == null) {
- instance = new LKIFCoreTop();
- }
- return instance;
- }
+ if (instance == null) {
+ instance = new LKIFCoreTop();
+ }
+ return instance;
+ }
+
/////////////////////////////////////////////////////////////
/* http://www.estrellaproject.org/lkif-core/lkif-top.owl */
/////////////////////////////////////////////////////////////
// CLASSES
- public final IRI Abstract_Entity = createClass(NS, "Abstract_Entity");
- public final IRI Mental_Entity = createClass(NS, "Mental_Entity");
- public final IRI Mental_Object = createClass(NS, "Mental_Object");
- public final IRI Occurrence = createClass(NS, "Occurrence");
- public final IRI Physical_Entity = createClass(NS, "Physical_Entity");
- public final IRI Spatio_Temporal_Occurrence = createClass(NS, "Spatio_Temporal_Occurrence");
+ public final IRI Abstract_Entity = createClass(NS, "Abstract_Entity");
+ public final IRI Mental_Entity = createClass(NS, "Mental_Entity");
+ public final IRI Mental_Object = createClass(NS, "Mental_Object");
+ public final IRI Occurrence = createClass(NS, "Occurrence");
+ public final IRI Physical_Entity = createClass(NS, "Physical_Entity");
+ public final IRI Spatio_Temporal_Occurrence = createClass(NS, "Spatio_Temporal_Occurrence");
// RESOURCES
-
+
// PROPERTIES
-
+
private LKIFCoreTop() {
- super(NS);
+ super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/OGP.java b/api/src/main/java/org/apache/any23/vocab/OGP.java
index 5ee0e92..22b8cb2 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGP.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGP.java
@@ -31,19 +31,23 @@ public class OGP extends Vocabulary {
}
public static final String NS = "http://ogp.me/ns#";
-
+
/* BEGIN: Basic Metadata. */
/** The title of your object as it should appear within the graph, e.g., "The Rock". */
public static final String TITLE = "title";
- /** The type of your object, e.g., "video.movie". Depending on the
- * type you specify, other properties may also be required. */
- public static final String TYPE = "type";
+ /**
+ * The type of your object, e.g., "video.movie". Depending on the type you specify, other properties may also be
+ * required.
+ */
+ public static final String TYPE = "type";
- /** The canonical URL of your object that will be used as its permanent ID in the
- * graph, e.g., "http://www.imdb.com/title/tt0117500/". */
- public static final String URL = "url";
+ /**
+ * The canonical URL of your object that will be used as its permanent ID in the graph, e.g.,
+ * "http://www.imdb.com/title/tt0117500/".
+ */
+ public static final String URL = "url";
/** An image URL which should represent your object within the graph. */
public static final String IMAGE = "image";
@@ -58,19 +62,25 @@ public class OGP extends Vocabulary {
/** A one to two sentence description of your object. */
public static final String DESCRIPTION = "description";
- /** The word that appears before this object's title in a sentence. An enum of (a, an, the, "", auto).
- * If auto is chosen, the consumer of your data should chose between "a" or "an". Default is "" (blank). */
+ /**
+ * The word that appears before this object's title in a sentence. An enum of (a, an, the, "", auto). If auto is
+ * chosen, the consumer of your data should chose between "a" or "an". Default is "" (blank).
+ */
public static final String DETERMINER = "determiner";
- /** The locale these tags are marked up in. Of the format <code>language_TERRITORY</code>.
- * Default is <code>en_US</code>. */
+ /**
+ * The locale these tags are marked up in. Of the format <code>language_TERRITORY</code>. Default is
+ * <code>en_US</code>.
+ */
public static final String LOCALE = "locale";
/** An array of other locales this page is available in. */
public static final String LOCALE__ALTERNATE = "locale:alternate";
- /** If your object is part of a larger web site, the name which should be
- * displayed for the overall site. e.g., <b>IMDb</b>. */
+ /**
+ * If your object is part of a larger web site, the name which should be displayed for the overall site. e.g.,
+ * <b>IMDb</b>.
+ */
public static final String SITE_NAME = "site_name";
/** A URL to a video file that complements this object. */
@@ -81,96 +91,101 @@ public class OGP extends Vocabulary {
/* BEGIN: Structured Properties. */
/** Identical to <code>og:image</code>. */
- public static final String IMAGE__URL = "image:url";
+ public static final String IMAGE__URL = "image:url";
/** An alternate url to use if the webpage requires <b>HTTPS</b>. */
public static final String IMAGE__SECURE_URL = "image:secure_url";
/** A <i>MIME type</i> for this image. */
- public static final String IMAGE__TYPE = "image:type";
+ public static final String IMAGE__TYPE = "image:type";
/** The number of pixels wide. */
- public static final String IMAGE__WIDTH = "image:width";
+ public static final String IMAGE__WIDTH = "image:width";
/** The number of pixels high. */
- public static final String IMAGE__HEIGHT = "image:height";
+ public static final String IMAGE__HEIGHT = "image:height";
- /** A description of what is in the image (not a caption).
- * If the page specifies an og:image it should specify og:image:alt.*/
- public static final String IMAGE__ALT = "image:alt";
+ /**
+ * A description of what is in the image (not a caption). If the page specifies an og:image it should specify
+ * og:image:alt.
+ */
+ public static final String IMAGE__ALT = "image:alt";
/** Video URL. */
- public static final String VIDEO__URL = "video:url";
+ public static final String VIDEO__URL = "video:url";
/** An alternate url to use if the webpage requires <b>HTTPS</b>. */
public static final String VIDEO__SECURE_URL = "video:secure_url";
/** A <i>MIME type</i> for this video. */
- public static final String VIDEO__TYPE = "video:type";
+ public static final String VIDEO__TYPE = "video:type";
/** The number of pixels wide. */
- public static final String VIDEO__WIDTH = "video:width";
+ public static final String VIDEO__WIDTH = "video:width";
/** The number of pixels height. */
- public static final String VIDEO__HEIGHT = "video:height";
+ public static final String VIDEO__HEIGHT = "video:height";
- /** A description of what is in the video (not a caption).
- * If the page specifies an og:video it should specify og:video:alt.*/
- public static final String VIDEO__ALT = "video:alt";
+ /**
+ * A description of what is in the video (not a caption). If the page specifies an og:video it should specify
+ * og:video:alt.
+ */
+ public static final String VIDEO__ALT = "video:alt";
/** An alternate url to use if the webpage requires <b>HTTPS</b>. */
public static final String AUDIO__SECURE_URL = "audio:secure_url";
/** A <i>MIME type</i> for this audio. */
- public static final String AUDIO__TYPE = "audio:type";
+ public static final String AUDIO__TYPE = "audio:type";
- /** A description of what is in the audio file (not a caption).
- * If the page specifies an og:audio it should specify og:audio:alt.*/
- public static final String AUDIO__ALT = "audio:alt";
+ /**
+ * A description of what is in the audio file (not a caption). If the page specifies an og:audio it should specify
+ * og:audio:alt.
+ */
+ public static final String AUDIO__ALT = "audio:alt";
/* END: Structured Properties. */
private static OGP instance;
public static OGP getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGP();
}
return instance;
}
public final IRI NAMESPACE = createIRI(NS);
-
-
- public final IRI title = createProperty(TITLE);
- public final IRI type = createProperty(TYPE);
- public final IRI url = createProperty(URL);
- public final IRI image = createProperty(IMAGE);
- public final IRI description = createProperty(DESCRIPTION);
- public final IRI determiner = createProperty(DETERMINER);
- public final IRI locale = createProperty(LOCALE);
+
+ public final IRI title = createProperty(TITLE);
+ public final IRI type = createProperty(TYPE);
+ public final IRI url = createProperty(URL);
+ public final IRI image = createProperty(IMAGE);
+ public final IRI description = createProperty(DESCRIPTION);
+ public final IRI determiner = createProperty(DETERMINER);
+ public final IRI locale = createProperty(LOCALE);
public final IRI localeAlternate = createProperty(LOCALE__ALTERNATE);
- public final IRI siteName = createProperty(SITE_NAME);
- public final IRI video = createProperty(VIDEO);
+ public final IRI siteName = createProperty(SITE_NAME);
+ public final IRI video = createProperty(VIDEO);
- public final IRI imageURL = createProperty(IMAGE__URL);
+ public final IRI imageURL = createProperty(IMAGE__URL);
public final IRI imageSecureURL = createProperty(IMAGE__SECURE_URL);
- public final IRI imageType = createProperty(IMAGE__TYPE);
- public final IRI imageWidth = createProperty(IMAGE__WIDTH);
- public final IRI imageHeight = createProperty(IMAGE__HEIGHT);
- public final IRI imageAlt = createProperty(IMAGE__ALT);
+ public final IRI imageType = createProperty(IMAGE__TYPE);
+ public final IRI imageWidth = createProperty(IMAGE__WIDTH);
+ public final IRI imageHeight = createProperty(IMAGE__HEIGHT);
+ public final IRI imageAlt = createProperty(IMAGE__ALT);
- public final IRI videoURL = createProperty(VIDEO__URL);
+ public final IRI videoURL = createProperty(VIDEO__URL);
public final IRI videoSecureURL = createProperty(VIDEO__SECURE_URL);
- public final IRI videoType = createProperty(VIDEO__TYPE);
- public final IRI videoWidth = createProperty(VIDEO__WIDTH);
- public final IRI videoHeight = createProperty(VIDEO__HEIGHT);
- public final IRI videoAlt = createProperty(VIDEO__ALT);
+ public final IRI videoType = createProperty(VIDEO__TYPE);
+ public final IRI videoWidth = createProperty(VIDEO__WIDTH);
+ public final IRI videoHeight = createProperty(VIDEO__HEIGHT);
+ public final IRI videoAlt = createProperty(VIDEO__ALT);
- public final IRI audio = createProperty(AUDIO);
+ public final IRI audio = createProperty(AUDIO);
public final IRI audioSecureURL = createProperty(AUDIO__SECURE_URL);
- public final IRI audioType = createProperty(AUDIO__TYPE);
- public final IRI audioAlt = createProperty(AUDIO__ALT);
+ public final IRI audioType = createProperty(AUDIO__TYPE);
+ public final IRI audioAlt = createProperty(AUDIO__ALT);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/OGPArticle.java b/api/src/main/java/org/apache/any23/vocab/OGPArticle.java
index 0381bd4..349fdbe 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGPArticle.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGPArticle.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <a href="http://ogp.me/">Open Graph Protocol Article Type</a>
- * vocabulary.
+ * The <a href="http://ogp.me/">Open Graph Protocol Article Type</a> vocabulary.
*/
public class OGPArticle extends Vocabulary {
@@ -43,20 +42,20 @@ public class OGPArticle extends Vocabulary {
public static final String ARTICLE__EXPIRATION_TIME = "article:expiration_time";
/** Writers of the article. */
- public static final String ARTICLE__AUTHOR = "article:author";
+ public static final String ARTICLE__AUTHOR = "article:author";
/** A high-level section name. E.g. Technology */
- public static final String ARTICLE__SECTION = "article:section";
+ public static final String ARTICLE__SECTION = "article:section";
/** Tag words associated with this article. */
- public static final String ARTICLE__TAG = "article:tag";
+ public static final String ARTICLE__TAG = "article:tag";
/* END: http://ogp.me/#type_article */
private static OGPArticle instance;
public static OGPArticle getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGPArticle();
}
return instance;
@@ -67,9 +66,9 @@ public class OGPArticle extends Vocabulary {
public final IRI articlePublishedTime = createProperty(ARTICLE__PUBLISHED_TIME);
public final IRI articleModifiedTime = createProperty(ARTICLE__MODIFIED_TIME);
public final IRI articleExpirationTime = createProperty(ARTICLE__EXPIRATION_TIME);
- public final IRI articleAuthor = createProperty(ARTICLE__AUTHOR);
+ public final IRI articleAuthor = createProperty(ARTICLE__AUTHOR);
public final IRI articleSection = createProperty(ARTICLE__SECTION);
- public final IRI articleTag = createProperty(ARTICLE__TAG);
+ public final IRI articleTag = createProperty(ARTICLE__TAG);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/OGPBook.java b/api/src/main/java/org/apache/any23/vocab/OGPBook.java
index 2f2debc..9cf5083 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGPBook.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGPBook.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <a href="http://ogp.me/#type_book">Open Graph Protocol Book Type</a>
- * vocabulary.
+ * The <a href="http://ogp.me/#type_book">Open Graph Protocol Book Type</a> vocabulary.
*/
public class OGPBook extends Vocabulary {
@@ -34,23 +33,23 @@ public class OGPBook extends Vocabulary {
/* BEGIN: http://ogp.me/#type_book */
/** Who wrote this book. */
- public static final String BOOK__AUTHOR = "book:author";
+ public static final String BOOK__AUTHOR = "book:author";
/** The ISBN */
- public static final String BOOK__ISBN = "book:isbn";
+ public static final String BOOK__ISBN = "book:isbn";
/** The date the book was released. */
public static final String BOOK__RELEASE_DATE = "book:release_date";
/** Tag words associated with this book. */
- public static final String BOOK__TAG = "book:tag";
+ public static final String BOOK__TAG = "book:tag";
/* END: http://ogp.me/#type_book */
private static OGPBook instance;
public static OGPBook getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGPBook();
}
return instance;
@@ -58,10 +57,10 @@ public class OGPBook extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
- public final IRI bookAuthor = createProperty(BOOK__AUTHOR);
- public final IRI bookIsbn = createProperty(BOOK__ISBN);
+ public final IRI bookAuthor = createProperty(BOOK__AUTHOR);
+ public final IRI bookIsbn = createProperty(BOOK__ISBN);
public final IRI bookReleaseDate = createProperty(BOOK__RELEASE_DATE);
- public final IRI bookTag = createProperty(BOOK__TAG);
+ public final IRI bookTag = createProperty(BOOK__TAG);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/OGPMusic.java b/api/src/main/java/org/apache/any23/vocab/OGPMusic.java
index 405b85e..a93bba8 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGPMusic.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGPMusic.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <a href="http://ogp.me/#type_music">Open Graph Protocol Music Type</a>
- * vocabulary.
+ * The <a href="http://ogp.me/#type_music">Open Graph Protocol Music Type</a> vocabulary.
*
*/
public class OGPMusic extends Vocabulary {
@@ -35,10 +34,10 @@ public class OGPMusic extends Vocabulary {
/* BEGIN: http://ogp.me/#type_music.song */
/** The song's length in seconds. */
- public static final String MUSIC__DURATION = "music:duration";
+ public static final String MUSIC__DURATION = "music:duration";
/** The album this song is from. */
- public static final String MUSIC__ALBUM = "music:album";
+ public static final String MUSIC__ALBUM = "music:album";
/** Which disc of the album this song is on. */
public static final String MUSIC__ALBUM_DISC = "music:album:disc";
@@ -47,17 +46,17 @@ public class OGPMusic extends Vocabulary {
public static final String MUSIC__ALBUM_TRACK = "music:album:track";
/** Which disc of the album this song is on. */
- public static final String MUSIC__MUSICIAN = "music:musician";
+ public static final String MUSIC__MUSICIAN = "music:musician";
/* END: http://ogp.me/#type_music.song */
/* BEGIN: http://ogp.me/#type_music.album */
/** The song on this album. */
- public static final String MUSIC__SONG = "music:song";
+ public static final String MUSIC__SONG = "music:song";
/** The same as music:album:disc but in reverse. */
- public static final String MUSIC__SONG_DISC = "music:song:disc";
+ public static final String MUSIC__SONG_DISC = "music:song:disc";
/** The same as music:album:track but in reverse. */
public static final String MUSIC__SONG_TRACK = "music:song:track";
@@ -69,16 +68,17 @@ public class OGPMusic extends Vocabulary {
/* BEGIN: http://ogp.me/#type_music.playlist */
- /** The creator of this playlist if 'music.playlist' or the
- * creator of this station if 'music.radio_station' */
- public static final String MUSIC__CREATOR = "music:creator";
+ /**
+ * The creator of this playlist if 'music.playlist' or the creator of this station if 'music.radio_station'
+ */
+ public static final String MUSIC__CREATOR = "music:creator";
/* END: http://ogp.me/#type_music.playlist */
private static OGPMusic instance;
public static OGPMusic getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGPMusic();
}
return instance;
@@ -86,18 +86,18 @@ public class OGPMusic extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
- public final IRI musicDuration = createProperty(MUSIC__DURATION);
- public final IRI musicAlbum = createProperty(MUSIC__ALBUM);
+ public final IRI musicDuration = createProperty(MUSIC__DURATION);
+ public final IRI musicAlbum = createProperty(MUSIC__ALBUM);
public final IRI musicAlbumDisc = createProperty(MUSIC__ALBUM_DISC);
public final IRI musicAlbumTrack = createProperty(MUSIC__ALBUM_TRACK);
- public final IRI musicMusician = createProperty(MUSIC__MUSICIAN);
-
- public final IRI musicSong = createProperty(MUSIC__SONG);
- public final IRI musicSongDisc = createProperty(MUSIC__SONG_DISC);
+ public final IRI musicMusician = createProperty(MUSIC__MUSICIAN);
+
+ public final IRI musicSong = createProperty(MUSIC__SONG);
+ public final IRI musicSongDisc = createProperty(MUSIC__SONG_DISC);
public final IRI musicSongTrack = createProperty(MUSIC__SONG_TRACK);
public final IRI musicReleaseDate = createProperty(MUSIC__RELEASE_DATE);
-
- public final IRI musicCreator = createProperty(MUSIC__CREATOR);
+
+ public final IRI musicCreator = createProperty(MUSIC__CREATOR);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/OGPProfile.java b/api/src/main/java/org/apache/any23/vocab/OGPProfile.java
index 48b0b3b..64d5b0f 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGPProfile.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGPProfile.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <a href="http://ogp.me/">Open Graph Protocol Profile Type</a>
- * vocabulary.
+ * The <a href="http://ogp.me/">Open Graph Protocol Profile Type</a> vocabulary.
*/
public class OGPProfile extends Vocabulary {
@@ -40,17 +39,17 @@ public class OGPProfile extends Vocabulary {
public static final String PROFILE__LAST_NAME = "profile:last_name";
/** A short unique string to identify them. */
- public static final String PROFILE__USERNAME = "profile:username";
+ public static final String PROFILE__USERNAME = "profile:username";
/** Their gender. */
- public static final String PROFILE__GENDER = "profile:gender";
+ public static final String PROFILE__GENDER = "profile:gender";
/* END: http://ogp.me/#type_profile */
private static OGPProfile instance;
public static OGPProfile getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGPProfile();
}
return instance;
@@ -61,7 +60,7 @@ public class OGPProfile extends Vocabulary {
public final IRI profileFirstName = createProperty(PROFILE__FIRST_NAME);
public final IRI profileLastName = createProperty(PROFILE__LAST_NAME);
public final IRI profileUsername = createProperty(PROFILE__USERNAME);
- public final IRI profileGender = createProperty(PROFILE__GENDER);
+ public final IRI profileGender = createProperty(PROFILE__GENDER);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/OGPVideo.java b/api/src/main/java/org/apache/any23/vocab/OGPVideo.java
index 774c7fd..76e4488 100644
--- a/api/src/main/java/org/apache/any23/vocab/OGPVideo.java
+++ b/api/src/main/java/org/apache/any23/vocab/OGPVideo.java
@@ -20,8 +20,7 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * The <a href="http://ogp.me/#type_video">Open Graph Protocol Video Type</a>
- * vocabulary.
+ * The <a href="http://ogp.me/#type_video">Open Graph Protocol Video Type</a> vocabulary.
*/
public class OGPVideo extends Vocabulary {
@@ -34,34 +33,34 @@ public class OGPVideo extends Vocabulary {
/* BEGIN: ogp.me/#type_video.movie */
/** Actors in the movie. */
- public static final String VIDEO__ACTOR = "video:actor";
+ public static final String VIDEO__ACTOR = "video:actor";
/** The role they played. */
public static final String VIDEO__ACTOR_ROLE = "video:actor:role";
/** Directors of the movie. */
- public static final String VIDEO__DIRECTOR = "video:director";
+ public static final String VIDEO__DIRECTOR = "video:director";
/** Writers of the movie. */
- public static final String VIDEO__WRITER = "video:writer";
+ public static final String VIDEO__WRITER = "video:writer";
/** The movie's length in seconds. */
- public static final String VIDEO__DURATION = "video:duration";
+ public static final String VIDEO__DURATION = "video:duration";
/** The date the movie was released. */
public static final String VIDEO__RELEASE_DATE = "video:release_date";
/** Tag words associated with this movie. */
- public static final String VIDEO__TAG = "video:tag";
+ public static final String VIDEO__TAG = "video:tag";
/** Which series this episode belongs to. */
- public static final String VIDEO__SERIES = "video:series";
+ public static final String VIDEO__SERIES = "video:series";
/* END: ogp.me/#type_video.movie */
private static OGPVideo instance;
public static OGPVideo getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new OGPVideo();
}
return instance;
@@ -69,14 +68,14 @@ public class OGPVideo extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
- public final IRI videoActor = createProperty(VIDEO__ACTOR);
+ public final IRI videoActor = createProperty(VIDEO__ACTOR);
public final IRI videoActorRole = createProperty(VIDEO__ACTOR_ROLE);
- public final IRI videoDirector = createProperty(VIDEO__DIRECTOR);
- public final IRI videoWriter = createProperty(VIDEO__WRITER);
- public final IRI videoDuration = createProperty(VIDEO__DURATION);
+ public final IRI videoDirector = createProperty(VIDEO__DIRECTOR);
+ public final IRI videoWriter = createProperty(VIDEO__WRITER);
+ public final IRI videoDuration = createProperty(VIDEO__DURATION);
public final IRI videoReleaseDate = createProperty(VIDEO__RELEASE_DATE);
- public final IRI videoTag = createProperty(VIDEO__TAG);
- public final IRI videoSeries = createProperty(VIDEO__SERIES);
+ public final IRI videoTag = createProperty(VIDEO__TAG);
+ public final IRI videoSeries = createProperty(VIDEO__SERIES);
@SuppressWarnings("unused")
private IRI createClass(String localName) {
diff --git a/api/src/main/java/org/apache/any23/vocab/Programme.java b/api/src/main/java/org/apache/any23/vocab/Programme.java
index 7d23254..4069ba1 100644
--- a/api/src/main/java/org/apache/any23/vocab/Programme.java
+++ b/api/src/main/java/org/apache/any23/vocab/Programme.java
@@ -19,354 +19,375 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>The <a href="http://purl.org/ontology/po/">Programmes Ontology</a> is aimed
- * at providing a simple vocabulary for describing programmes.</p>
- * <p>It covers brands, series (seasons), episodes, broadcast events, broadcast
- * services, etc. Its development was funded by the BBC, and is heavily grounded
- * on previous programmes data modeling work done there.</p>
+ * <p>
+ * The <a href="http://purl.org/ontology/po/">Programmes Ontology</a> is aimed at providing a simple vocabulary for
+ * describing programmes.
+ * </p>
+ * <p>
+ * It covers brands, series (seasons), episodes, broadcast events, broadcast services, etc. Its development was funded
+ * by the BBC, and is heavily grounded on previous programmes data modeling work done there.
+ * </p>
*
* @author lewismc
*/
public class Programme extends Vocabulary {
- public static final String NS = "http://purl.org/ontology/po/";
+ public static final String NS = "http://purl.org/ontology/po/";
- private static Programme instance;
+ private static Programme instance;
- public static Programme getInstance() {
- if(instance == null) {
- instance = new Programme();
+ public static Programme getInstance() {
+ if (instance == null) {
+ instance = new Programme();
+ }
+ return instance;
+ }
+
+ // Resources
+ /** A version holding an audio description. */
+ public final IRI AudioDescribedVersion = createClass(NS, "AudioDescribedVersion");
+
+ /** A brand, e.g. `Top Gea`r */
+ public final IRI Brand = createClass(NS, "Brand");
+
+ /**
+ * A broadcast event. Subsumes the event concept defined in the Event ontology. A broadcast is associated with a
+ * service, and with a particular version of an episode.
+ */
+ public final IRI Broadcast = createClass(NS, "Broadcast");
+
+ /**
+ * An organization responsible of some broadcasting services. It can hold a set of services and outlets.
+ */
+ public final IRI Broadcaster = createClass(NS, "Broadcaster");
+
+ /**
+ * A category provides a way of classifying a set of programmes. Such classifications can be performed according to
+ * multiple dimensions and taxonomies, e.g. genre, format, places, people, subjects...
+ */
+ public final IRI Category = createClass(NS, "Category");
+
+ /**
+ * A physical channel on which a broadcast occurs. A single outlet or service can be associated with multiple
+ * channels. For example, Radio 4 LW broadcasts on Analogue Long Wave and on Digital Satellite.
+ */
+ public final IRI Channel = createClass(NS, "Channel");
+
+ /** A particular clip, e.g. `Clip of Top Gear, first series' */
+ public final IRI Clip = createClass(NS, "Clip");
+
+ /**
+ * Digital Audio Broadcasting
+ */
+ public final IRI DAB = createClass(NS, "DAB");
+
+ /** Digital Video Broadcasting */
+ public final IRI DVB = createClass(NS, "DVB");
+
+ /**
+ * A particular episode, e.g. `Top Gear, first episode of the first series' or the film 'A Walk in the Sun'
+ * (http://www.bbc.co.uk/programmes/b00gfzdt)
+ */
+ public final IRI Episode = createClass(NS, "Episode");
+
+ /** The FM broadcast band */
+ public final IRI FM = createClass(NS, "FM");
+
+ /** Specifies a broadcast as being the first one of a particular version. */
+ public final IRI FirstBroadcast = createClass(NS, "FirstBroadcast");
+
+ /**
+ * Anchor point for format taxonomies, similar to po:Genre for genre taxonomies. Instances of this concept include
+ * documentaries, talk shows, animation, etc.
+ */
+ public final IRI Format = createClass(NS, "Format");
+
+ /**
+ * An anchor point for a programmes' genre taxonomy, # e.g. 'Drama'/'Biographical'.
+ */
+ public final IRI Genre = createClass(NS, "Genre");
+
+ /** IP Stream */
+ public final IRI IPStream = createClass(NS, "IPStream");
+
+ /** The AM broadcast band. */
+ public final IRI LW = createClass(NS, "LW");
+
+ /** Radio services aiming at a local coverage. */
+ public final IRI LocalRadio = createClass(NS, "LocalRadio");
+
+ /**
+ * Classification of an episode version's region corresponding to a musical track being played..
+ */
+ public final IRI MusicSegment = createClass(NS, "MusicSegment");
+
+ /** Radio services aiming at a national coverage. */
+ public final IRI NationalRadio = createClass(NS, "NationalRadio");
+
+ /** An `original' version, the legacy version of a particular episode. */
+ public final IRI OriginalVersion = createClass(NS, "OriginalVersion");
+
+ /**
+ * Outlet of a particular service, e.g. Radio 4 LW and FM for Radio 4. Outlets are services which do not have
+ * variations. The identity criteria for an outlet is its timeline. For example, Radio 4 LW broadcasts on Analogue
+ * Long Wave, but also on Digital Satellite. It corresponds to just one outlet, as they are simulcasts. The two
+ * physical channels for broadcasts correspond to po:Channel.
+ */
+ public final IRI Outlet = createClass(NS, "Outlet");
+
+ /** A Person. */
+ public final IRI Person = createClass(NS, "Person");
+
+ /** A physical place. */
+ public final IRI Place = createClass(NS, "Place");
+
+ /** A programme, can either be a brand, a series or an episode. */
+ public final IRI Programme = createClass(NS, "Programme");
+
+ /**
+ * A programme that can have versions, and as such can be broadcast or made available on-demand, e.g. a clip or an
+ * episode.
+ */
+ public final IRI ProgrammeItem = createClass(NS, "ProgrammeItem");
+
+ /** Services that use a radio medium. */
+ public final IRI Radio = createClass(NS, "Radio");
+
+ /** Radio services aiming at a regional coverage. */
+ public final IRI RegionalRadio = createClass(NS, "RegionalRadio");
+
+ /** Specifies a broadcast as being a repeat. */
+ public final IRI RepeatBroadcast = createClass(NS, "RepeatBroadcast");
+
+ /** A season is a group of broadcasts. */
+ public final IRI Season = createClass(NS, "Season");
+
+ /**
+ * Classification of an episode version's region, e.g. 'this track was played at that time'.
+ */
+ public final IRI Segment = createClass(NS, "Segment");
+
+ /** A series, e.g. `Top Gear, first season' */
+ public final IRI Series = createClass(NS, "Series");
+
+ /**
+ * A broadcasting service. Instances of this concept include BBC Radio Wales, BBC Radio 4, BBC News, etc. A service
+ * is a collection of outlets which contain common material, but with some variations, e.g. by region. Hence, a
+ * service may have multiple outlets (po:Outlet), e.g. BBC Radio 4 has BBC Radio 4 LW and BBC Radio 4 FM. A
+ * hierarchy of services types is defined within this ontology, e.g. radio and TV. A service that is a master brand
+ * only (a service that only commissions programmes, e.g. BBC Switch) should be an instance of the top-level
+ * po:Service.
+ */
+ public final IRI Service = createClass(NS, "Service");
+
+ /** A shortened version. */
+ public final IRI ShortenedVersion = createClass(NS, "ShortenedVersion");
+
+ /** Classification of an episode version's region holding speech content. */
+ public final IRI SpeechSegment = createClass(NS, "SpeechSegment");
+
+ /** Anchor point for subject taxonomies. */
+ public final IRI SignedVersion = createClass(NS, "SignedVersion");
+
+ /** A version holding sign language. */
+ public final IRI Subject = createClass(NS, "Subject");
+
+ /** Classification of an episode version's region corresponding to a subtitle being shown. */
+ public final IRI Subtitle = createClass(NS, "Subtitle");
+
+ /** Services that use a television medium. */
+ public final IRI TV = createClass(NS, "TV");
+
+ /**
+ * A particular version of an episode. Such versions include shortened ones, audio described ones or ones that holds
+ * sign language. The version is associated to a timeline.
+ */
+ public final IRI Version = createClass(NS, "Version");
+
+ /** Services that use a Web medium. */
+ public final IRI Web = createClass(NS, "Web");
+
+ // Properties
+ /**
+ * Relates a programmes to one of its actors - a person who plays the role of a character.
+ */
+ public final IRI actor = createProperty(NS, "actor");
+
+ /** A television reporter who coordinates a programme. */
+ public final IRI anchor = createProperty(NS, "anchor");
+
+ /** The aspect ration of a particular version. */
+ public final IRI aspect_ratio = createProperty(NS, "aspect_ratio");
+
+ /** Relates a programme to its author - the person who created the content */
+ public final IRI author = createProperty(NS, "author");
+
+ /**
+ * Relates a particular broadcast to the version being broadcasted. Sub-property of the event:factor one.
+ */
+ public final IRI broadcast_of = createProperty(NS, "broadcast_of");
+
+ /**
+ * Relates a particular broadcast to the service or outlet on which it was on. Sub-property of the event:factor one.
+ */
+ public final IRI broadcast_on = createProperty(NS, "broadcast_on");
+
+ /** Associates a service to a broadcaster. */
+ public final IRI broadcaster = createProperty(NS, "broadcaster");
+
+ /** Relates a programme to a particular category, e.g. genre, format, place... */
+ public final IRI category = createProperty(NS, "category");
+
+ /**
+ * Associates a service to a channel, e.g. Radio 4 LW to Radio 4 LW on Analogue Long Wave.
+ */
+ public final IRI channel = createProperty(NS, "channel");
+
+ /** Associates a brand, a series or an episode to a clip. */
+ public final IRI clip = createProperty(NS, "clip");
+
+ /** Relates a programme to one of its commentators */
+ public final IRI commentator = createProperty(NS, "commentator");
+
+ /** Relates a programmes to a person who is credited in it */
+ public final IRI credit = createProperty(NS, "credit");
+
+ /**
+ * Relates a programme to its supervisor. Generally refers to the person responsible for all audience-visible
+ * components of a program, film, or show, whereas the producer is responsible for the financial and other
+ * behind-the-scenes aspects. A director's duties might also include casting, script editing, shot selection, shot
+ * composition, and editing
+ */
+ public final IRI director = createProperty(NS, "director");
+
+ /** The duration of a version, in seconds. */
+ public final IRI duration = createProperty(NS, "duration");
+
+ /** Associates a brand or a series to an episode constituting it. */
+ public final IRI episode = createProperty(NS, "episode");
+
+ /**
+ * Relates a programme to its executive producer - a producer who is not involved in any technical aspects of the
+ * making process, but who is still responsible for the overall production. Typically an executive producer handles
+ * business and legal issues
+ */
+ public final IRI executive_producer = createProperty(NS, "executive_producer");
+
+ /** Relates a programme to a particular format (eg. `Animation', `Documentary', etc.). */
+ public final IRI format = createProperty(NS, "format");
+
+ /** Associates a channel to its frequency */
+ public final IRI frequency = createProperty(NS, "frequency");
+
+ /** Relates a programme to a particular genre. */
+ public final IRI genre = createProperty(NS, "genre");
+
+ /**
+ * Associates a service to a geographic location, aiming at capturing what this service aims at covering.
+ */
+ public final IRI location = createProperty(NS, "location");
+
+ /** A long synopsis of a serie, brand or episode. Sub-property of po:synopsis. */
+ public final IRI long_synopsis = createProperty(NS, "long_synopsis");
+
+ /** Associates a programme with its masterbrand (its commissionner) */
+ public final IRI masterbrand = createProperty(NS, "masterbrand");
+
+ /** A medium synopsis of a serie, brand or episode. Sub-property of po:synopsis. */
+ public final IRI medium_synopsis = createProperty(NS, "medium_synopsis");
+
+ /**
+ * Associates a programme to its microsite. For example http://www.bbc.co.uk/programmes/b00fm04s and
+ * http://www.bbc.co.uk/eastenders/
+ */
+ public final IRI microsite = createProperty(NS, "microsite");
+
+ /** Relates a programme to its news reader */
+ public final IRI news_reader = createProperty(NS, "news_reader");
+
+ /** Associates a service to an outlet, e.g. Radio 4 to Radio 4 LW. */
+ public final IRI outlet = createProperty(NS, "outlet");
+
+ /** Relates a series to a series constituting it (eg. `Waking the dead'). */
+ public final IRI parent_series = createProperty(NS, "parent_series");
+
+ /** Relates a service to another service encapsulating it (eg. `BBC One' and `BBC One South') */
+ public final IRI parent_service = createProperty(NS, "parent_service");
+
+ /** Relates a programme to one of its participants */
+ public final IRI participant = createProperty(NS, "participant");
+
+ /** Relates a programme to an entertainer who performs a dramatic or musical work for audience */
+ public final IRI performer = createProperty(NS, "performer");
+
+ /** Relates a programme to a person */
+ public final IRI person = createProperty(NS, "person");
+
+ /** Relates a programme to a place (e.g. `London') */
+ public final IRI place = createProperty(NS, "place");
+
+ /**
+ * The position of a particular series or episode within its containing programme. This property can also be used to
+ * give the position of an interval within the containing timeline.
+ */
+ public final IRI position = createProperty(NS, "position");
+
+ /**
+ * Relates a programme to its producer - the manager of an event, show, or other work, usually the individual in
+ * charge of finance, personnel, and other non-artistic aspects in the development of commercials, plays, movies,
+ * and other works
+ */
+ public final IRI producer = createProperty(NS, "producer");
+
+ /** The schedule date of a broadcast event. */
+ public final IRI schedule_date = createProperty(NS, "schedule_date");
+
+ /** Associates a season to its constituent broadcasts */
+ public final IRI season_broadcast = createProperty(NS, "season_broadcast");
+
+ /** Associates a brand or a series to a series constituting it. */
+ public final IRI series = createProperty(NS, "series");
+
+ /** Associate a brand, series or episode to the master brand service. */
+ public final IRI service = createProperty(NS, "service");
+
+ /** A short synopsis of a serie, brand or episode. Sub-property of po:synopsis. */
+ public final IRI short_synopsis = createProperty(NS, "short_synopsis");
+
+ /** The sound format of a particular version. */
+ public final IRI sound_format = createProperty(NS, "sound_format");
+
+ /** Relates a programme to a subject (e.g. `easter'). */
+ public final IRI subject = createProperty(NS, "subject");
+
+ /** Language of the subtitles emebedded in a particular version. */
+ public final IRI subtitle_language = createProperty(NS, "subtitle_language");
+
+ /** The synopsis of a serie, brand or episode. */
+ public final IRI synopsis = createProperty(NS, "synopsis");
+
+ /** Associates an episode to a particular tag. */
+ public final IRI tag = createProperty(NS, "tag");
+
+ /** Associates a subtitle event to the corresponding text. */
+ public final IRI text = createProperty(NS, "text");
+
+ /**
+ * Associates an episode's version or a version's segment with a temporal interval. This interval can be associated
+ * with a timeline, serving as an anchor for further temporal annotations, e.g. subtitles or played track.
+ */
+ public final IRI time = createProperty(NS, "time");
+
+ /** Associates a music segment with a track, as defined in MO. */
+ public final IRI track = createProperty(NS, "track");
+
+ /**
+ * Associate an episode to a version of it. Different versions of a same episode can exist (shortened version,
+ * version designed for the hearing impaired, etc.).
+ */
+ public final IRI version = createProperty(NS, "version");
+
+ private Programme() {
+ super(NS);
}
- return instance;
- }
-
- //Resources
- /** A version holding an audio description. */
- public final IRI AudioDescribedVersion = createClass(NS, "AudioDescribedVersion");
-
- /** A brand, e.g. `Top Gea`r*/
- public final IRI Brand = createClass(NS, "Brand");
-
- /**
- * A broadcast event. Subsumes the event concept defined in the Event ontology.
- * A broadcast is associated with a service, and with a particular version of an episode.
- */
- public final IRI Broadcast = createClass(NS, "Broadcast");
-
- /** An organization responsible of some broadcasting services.
- * It can hold a set of services and outlets.
- */
- public final IRI Broadcaster = createClass(NS, "Broadcaster");
-
- /** A category provides a way of classifying a set of programmes.
- * Such classifications can be performed according to multiple
- * dimensions and taxonomies, e.g. genre, format, places, people, subjects...
- */
- public final IRI Category = createClass(NS, "Category");
-
- /** A physical channel on which a broadcast occurs.
- * A single outlet or service can be associated with multiple channels.
- * For example, Radio 4 LW broadcasts on Analogue Long Wave and on Digital
- * Satellite.
- */
- public final IRI Channel = createClass(NS, "Channel");
-
- /** A particular clip, e.g. `Clip of Top Gear, first series' */
- public final IRI Clip = createClass(NS, "Clip");
-
- /**
- * Digital Audio Broadcasting */
- public final IRI DAB = createClass(NS, "DAB");
-
- /** Digital Video Broadcasting*/
- public final IRI DVB = createClass(NS, "DVB");
-
- /**
- * A particular episode, e.g. `Top Gear, first episode of the first series'
- * or the film 'A Walk in the Sun' (http://www.bbc.co.uk/programmes/b00gfzdt)
- */
- public final IRI Episode = createClass(NS, "Episode");
-
- /** The FM broadcast band */
- public final IRI FM = createClass(NS, "FM");
-
- /** Specifies a broadcast as being the first one of a particular version.*/
- public final IRI FirstBroadcast = createClass(NS, "FirstBroadcast");
-
- /**
- * Anchor point for format taxonomies, similar to po:Genre for genre taxonomies.
- * Instances of this concept include documentaries, talk shows, animation, etc.
- */
- public final IRI Format = createClass(NS, "Format");
-
- /**
- * An anchor point for a programmes' genre taxonomy, #
- * e.g. 'Drama'/'Biographical'.*/
- public final IRI Genre = createClass(NS, "Genre");
-
- /** IP Stream*/
- public final IRI IPStream = createClass(NS, "IPStream");
-
- /** The AM broadcast band.*/
- public final IRI LW = createClass(NS, "LW");
-
- /** Radio services aiming at a local coverage.*/
- public final IRI LocalRadio = createClass(NS, "LocalRadio");
-
- /** Classification of an episode version's region corresponding to a
- * musical track being played..*/
- public final IRI MusicSegment = createClass(NS, "MusicSegment");
-
- /** Radio services aiming at a national coverage.*/
- public final IRI NationalRadio = createClass(NS, "NationalRadio");
-
- /** An `original' version, the legacy version of a particular episode.*/
- public final IRI OriginalVersion = createClass(NS, "OriginalVersion");
-
- /** Outlet of a particular service, e.g. Radio 4 LW and FM for Radio 4.
- * Outlets are services which do not have variations. The identity criteria
- * for an outlet is its timeline. For example, Radio 4 LW broadcasts on
- * Analogue Long Wave, but also on Digital Satellite. It corresponds to just
- * one outlet, as they are simulcasts. The two physical channels for
- * broadcasts correspond to po:Channel.*/
- public final IRI Outlet = createClass(NS, "Outlet");
-
- /** A Person.*/
- public final IRI Person = createClass(NS, "Person");
-
- /** A physical place.*/
- public final IRI Place = createClass(NS, "Place");
-
- /** A programme, can either be a brand, a series or an episode.*/
- public final IRI Programme = createClass(NS, "Programme");
-
- /** A programme that can have versions, and as such can be broadcast or
- * made available on-demand, e.g. a clip or an episode.*/
- public final IRI ProgrammeItem = createClass(NS, "ProgrammeItem");
-
- /** Services that use a radio medium.*/
- public final IRI Radio = createClass(NS, "Radio");
-
- /** Radio services aiming at a regional coverage.*/
- public final IRI RegionalRadio = createClass(NS, "RegionalRadio");
-
- /** Specifies a broadcast as being a repeat.*/
- public final IRI RepeatBroadcast = createClass(NS, "RepeatBroadcast");
-
- /** A season is a group of broadcasts.*/
- public final IRI Season = createClass(NS, "Season");
-
- /** Classification of an episode version's region, e.g.
- * 'this track was played at that time'.*/
- public final IRI Segment = createClass(NS, "Segment");
-
- /** A series, e.g. `Top Gear, first season'*/
- public final IRI Series = createClass(NS, "Series");
-
- /** A broadcasting service. Instances of this concept include BBC Radio Wales,
- * BBC Radio 4, BBC News, etc. A service is a collection of outlets which
- * contain common material, but with some variations, e.g. by region.
- * Hence, a service may have multiple outlets (po:Outlet), e.g. BBC Radio 4
- * has BBC Radio 4 LW and BBC Radio 4 FM. A hierarchy of services types is
- * defined within this ontology, e.g. radio and TV. A service that is a master
- * brand only (a service that only commissions programmes, e.g. BBC Switch) should
- * be an instance of the top-level po:Service.*/
- public final IRI Service = createClass(NS, "Service");
-
- /** A shortened version.*/
- public final IRI ShortenedVersion = createClass(NS, "ShortenedVersion");
-
- /** Classification of an episode version's region holding speech content.*/
- public final IRI SpeechSegment = createClass(NS, "SpeechSegment");
-
- /** Anchor point for subject taxonomies.*/
- public final IRI SignedVersion = createClass(NS, "SignedVersion");
-
- /** A version holding sign language.*/
- public final IRI Subject = createClass(NS, "Subject");
-
- /** Classification of an episode version's region corresponding to a subtitle being shown. */
- public final IRI Subtitle = createClass(NS, "Subtitle");
-
- /** Services that use a television medium.*/
- public final IRI TV = createClass(NS, "TV");
-
- /** A particular version of an episode.
- * Such versions include shortened ones, audio described ones
- * or ones that holds sign language.
- * The version is associated to a timeline.*/
- public final IRI Version = createClass(NS, "Version");
-
- /** Services that use a Web medium.*/
- public final IRI Web = createClass(NS, "Web");
-
- //Properties
- /** Relates a programmes to one of its actors - a person who plays the
- * role of a character. */
- public final IRI actor = createProperty(NS, "actor");
-
- /** A television reporter who coordinates a programme. */
- public final IRI anchor = createProperty(NS, "anchor");
-
- /** The aspect ration of a particular version.*/
- public final IRI aspect_ratio = createProperty(NS, "aspect_ratio");
-
- /** Relates a programme to its author - the person who created the content */
- public final IRI author = createProperty(NS, "author");
-
- /** Relates a particular broadcast to the version being broadcasted.
- * Sub-property of the event:factor one.*/
- public final IRI broadcast_of = createProperty(NS, "broadcast_of");
-
- /** Relates a particular broadcast to the service or outlet on which it was on.
- * Sub-property of the event:factor one. */
- public final IRI broadcast_on = createProperty(NS, "broadcast_on");
-
- /** Associates a service to a broadcaster. */
- public final IRI broadcaster = createProperty(NS, "broadcaster");
-
- /** Relates a programme to a particular category, e.g. genre, format, place...*/
- public final IRI category = createProperty(NS, "category");
-
- /** Associates a service to a channel, e.g. Radio 4 LW to Radio 4 LW on
- * Analogue Long Wave.*/
- public final IRI channel = createProperty(NS, "channel");
-
- /** Associates a brand, a series or an episode to a clip.*/
- public final IRI clip = createProperty(NS, "clip");
-
- /** Relates a programme to one of its commentators */
- public final IRI commentator = createProperty(NS, "commentator");
-
- /** Relates a programmes to a person who is credited in it */
- public final IRI credit = createProperty(NS, "credit");
-
- /** Relates a programme to its supervisor. Generally refers to the person
- * responsible for all audience-visible components of a program, film, or show,
- * whereas the producer is responsible for the financial and other
- * behind-the-scenes aspects. A director's duties might also include casting,
- * script editing, shot selection, shot composition, and editing */
- public final IRI director = createProperty(NS, "director");
-
- /** The duration of a version, in seconds. */
- public final IRI duration = createProperty(NS, "duration");
-
- /** Associates a brand or a series to an episode constituting it.*/
- public final IRI episode = createProperty(NS, "episode");
-
- /** Relates a programme to its executive producer - a producer who is not involved
- * in any technical aspects of the making process, but who is still responsible
- * for the overall production. Typically an executive producer handles business and
- * legal issues */
- public final IRI executive_producer = createProperty(NS, "executive_producer");
-
- /** Relates a programme to a particular format (eg. `Animation', `Documentary', etc.).*/
- public final IRI format = createProperty(NS, "format");
-
- /** Associates a channel to its frequency */
- public final IRI frequency = createProperty(NS, "frequency");
-
- /** Relates a programme to a particular genre.*/
- public final IRI genre = createProperty(NS, "genre");
-
- /** Associates a service to a geographic location, aiming at capturing what
- * this service aims at covering.*/
- public final IRI location = createProperty(NS, "location");
-
- /** A long synopsis of a serie, brand or episode. Sub-property of po:synopsis.*/
- public final IRI long_synopsis = createProperty(NS, "long_synopsis");
-
- /** Associates a programme with its masterbrand (its commissionner) */
- public final IRI masterbrand = createProperty(NS, "masterbrand");
-
- /** A medium synopsis of a serie, brand or episode. Sub-property of po:synopsis.*/
- public final IRI medium_synopsis = createProperty(NS, "medium_synopsis");
-
- /** Associates a programme to its microsite. For example
- * http://www.bbc.co.uk/programmes/b00fm04s and http://www.bbc.co.uk/eastenders/ */
- public final IRI microsite = createProperty(NS, "microsite");
-
- /** Relates a programme to its news reader */
- public final IRI news_reader = createProperty(NS, "news_reader");
-
- /** Associates a service to an outlet, e.g. Radio 4 to Radio 4 LW.*/
- public final IRI outlet = createProperty(NS, "outlet");
-
- /** Relates a series to a series constituting it (eg. `Waking the dead').*/
- public final IRI parent_series = createProperty(NS, "parent_series");
-
- /** Relates a service to another service encapsulating it (eg. `BBC One' and `BBC One South')*/
- public final IRI parent_service = createProperty(NS, "parent_service");
-
- /** Relates a programme to one of its participants */
- public final IRI participant = createProperty(NS, "participant");
-
- /** Relates a programme to an entertainer who performs a dramatic or musical work for audience */
- public final IRI performer = createProperty(NS, "performer");
-
- /** Relates a programme to a person*/
- public final IRI person = createProperty(NS, "person");
-
- /** Relates a programme to a place (e.g. `London')*/
- public final IRI place = createProperty(NS, "place");
-
- /** The position of a particular series or episode within its containing programme.
- * This property can also be used to give the position of an interval
- * within the containing timeline. */
- public final IRI position = createProperty(NS, "position");
-
- /** Relates a programme to its producer - the manager of an event, show,
- * or other work, usually the individual in charge of finance, personnel,
- * and other non-artistic aspects in the development of commercials,
- * plays, movies, and other works */
- public final IRI producer = createProperty(NS, "producer");
-
- /** The schedule date of a broadcast event.*/
- public final IRI schedule_date = createProperty(NS, "schedule_date");
-
- /** Associates a season to its constituent broadcasts */
- public final IRI season_broadcast = createProperty(NS, "season_broadcast");
-
- /** Associates a brand or a series to a series constituting it.*/
- public final IRI series = createProperty(NS, "series");
-
- /** Associate a brand, series or episode to the master brand service.*/
- public final IRI service = createProperty(NS, "service");
-
- /** A short synopsis of a serie, brand or episode. Sub-property of po:synopsis.*/
- public final IRI short_synopsis = createProperty(NS, "short_synopsis");
-
- /** The sound format of a particular version.*/
- public final IRI sound_format = createProperty(NS, "sound_format");
-
- /** Relates a programme to a subject (e.g. `easter').*/
- public final IRI subject = createProperty(NS, "subject");
-
- /** Language of the subtitles emebedded in a particular version.*/
- public final IRI subtitle_language = createProperty(NS, "subtitle_language");
-
- /** The synopsis of a serie, brand or episode.*/
- public final IRI synopsis = createProperty(NS, "synopsis");
-
- /** Associates an episode to a particular tag. */
- public final IRI tag = createProperty(NS, "tag");
-
- /** Associates a subtitle event to the corresponding text. */
- public final IRI text = createProperty(NS, "text");
-
- /** Associates an episode's version or a version's segment with a temporal interval.
- * This interval can be associated with a timeline, serving as an anchor for
- * further temporal annotations, e.g. subtitles or played track.*/
- public final IRI time = createProperty(NS, "time");
-
- /** Associates a music segment with a track, as defined in MO. */
- public final IRI track = createProperty(NS, "track");
-
- /** Associate an episode to a version of it. Different versions of a same
- * episode can exist (shortened version, version designed for the hearing impaired, etc.). */
- public final IRI version = createProperty(NS, "version");
-
- private Programme(){
- super(NS);
- }
}
diff --git a/api/src/main/java/org/apache/any23/vocab/Review.java b/api/src/main/java/org/apache/any23/vocab/Review.java
index d4d82b3..0535dfc 100644
--- a/api/src/main/java/org/apache/any23/vocab/Review.java
+++ b/api/src/main/java/org/apache/any23/vocab/Review.java
@@ -27,7 +27,7 @@ public class Review extends Vocabulary {
private static Review instance;
public static Review getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new Review();
}
return instance;
@@ -46,7 +46,7 @@ public class Review extends Vocabulary {
/**
* The commenter on the review.
*/
- public final IRI commenter = createProperty("commenter");
+ public final IRI commenter = createProperty("commenter");
/**
* Used to associate a review with a comment on the review.
@@ -127,7 +127,7 @@ public class Review extends Vocabulary {
return createProperty(NS, localName);
}
- private Review(){
+ private Review() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/ReviewAggregate.java b/api/src/main/java/org/apache/any23/vocab/ReviewAggregate.java
index 3300523..28c781e 100644
--- a/api/src/main/java/org/apache/any23/vocab/ReviewAggregate.java
+++ b/api/src/main/java/org/apache/any23/vocab/ReviewAggregate.java
@@ -23,12 +23,12 @@ public class ReviewAggregate extends Vocabulary {
private static ReviewAggregate instance;
public static ReviewAggregate getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new ReviewAggregate();
}
return instance;
}
-
+
/**
* The namespace of the vocabulary as a string.
*/
@@ -38,28 +38,27 @@ public class ReviewAggregate extends Vocabulary {
* The namespace of the vocabulary as a IRI.
*/
public final IRI NAMESPACE = createIRI(NS);
-
+
/**
* Number of usefulness votes (integer).
*/
public final IRI votes = createProperty("votes");
-
+
/**
* Number of usefulness reviews (integer).
*/
public final IRI count = createProperty("count");
-
+
/**
* Optional
*/
public final IRI average = createProperty("average");
-
+
public final IRI worst = createProperty("worst");
-
+
public final IRI best = createProperty("best");
-
- /**
+ /**
* An agg review of a work.
*/
public final IRI ReviewAggregate = createProperty("ReviewAggregate");
@@ -67,8 +66,8 @@ public class ReviewAggregate extends Vocabulary {
private IRI createProperty(String localName) {
return createProperty(NS, localName);
}
-
- private ReviewAggregate(){
+
+ private ReviewAggregate() {
super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/SINDICE.java b/api/src/main/java/org/apache/any23/vocab/SINDICE.java
index 287f04c..49d6517 100644
--- a/api/src/main/java/org/apache/any23/vocab/SINDICE.java
+++ b/api/src/main/java/org/apache/any23/vocab/SINDICE.java
@@ -20,8 +20,8 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * This class models an internal <i>Sindice</i> Vocabulary to describe
- * resource domains and Microformat nesting relationships.
+ * This class models an internal <i>Sindice</i> Vocabulary to describe resource domains and Microformat nesting
+ * relationships.
*
* @author Davide Palmisano (dpalmisano@gmail.com)
* @author Michele Mostarda (michele.mostarda@gmail.com)
@@ -48,7 +48,7 @@ public class SINDICE extends Vocabulary {
private static SINDICE instance;
public static SINDICE getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new SINDICE();
}
return instance;
@@ -60,15 +60,13 @@ public class SINDICE extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
/**
- * This property expresses the DNS domain of the resource on which
- * it is applied. It is intended to be used to keep track of the domain provenance
- * of each resource.
+ * This property expresses the DNS domain of the resource on which it is applied. It is intended to be used to keep
+ * track of the domain provenance of each resource.
*/
public final IRI domain = createProperty(DOMAIN);
/**
- * This property links a resource with a <i>blank node</i> that represents
- * a nested <i>Microformat</i> node.
+ * This property links a resource with a <i>blank node</i> that represents a nested <i>Microformat</i> node.
*/
public final IRI nesting = createProperty(NESTING);
@@ -93,7 +91,6 @@ public class SINDICE extends Vocabulary {
*/
public final IRI date = createProperty(DATE);
-
private IRI createClass(String localName) {
return createClass(NS, localName);
}
@@ -102,7 +99,7 @@ public class SINDICE extends Vocabulary {
return createProperty(NS, localName);
}
- private SINDICE(){
+ private SINDICE() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/SchemaOrg.java b/api/src/main/java/org/apache/any23/vocab/SchemaOrg.java
index bdd308c..6ddbd55 100644
--- a/api/src/main/java/org/apache/any23/vocab/SchemaOrg.java
+++ b/api/src/main/java/org/apache/any23/vocab/SchemaOrg.java
@@ -32,13 +32,13 @@ public class SchemaOrg extends Vocabulary {
private static SchemaOrg instance;
public static SchemaOrg getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new SchemaOrg();
}
return instance;
}
- private SchemaOrg(){
+ private SchemaOrg() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/VCard.java b/api/src/main/java/org/apache/any23/vocab/VCard.java
index d6cd698..3b21f90 100644
--- a/api/src/main/java/org/apache/any23/vocab/VCard.java
+++ b/api/src/main/java/org/apache/any23/vocab/VCard.java
@@ -32,7 +32,7 @@ public class VCard extends Vocabulary {
private static VCard instance;
public static VCard getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new VCard();
}
return instance;
@@ -144,8 +144,7 @@ public class VCard extends Vocabulary {
public final IRI key = createProperty("key");
/**
- * The formatted version of a postal address (a string with embedded line breaks,
- * punctuation, etc.).
+ * The formatted version of a postal address (a string with embedded line breaks, punctuation, etc.).
*/
public final IRI label = createProperty("label");
@@ -215,8 +214,7 @@ public class VCard extends Vocabulary {
public final IRI organization_unit = createProperty("organization-unit");
/**
- * An email address unaffiliated with any particular organization or employer;
- * a personal email address.
+ * An email address unaffiliated with any particular organization or employer; a personal email address.
*/
public final IRI personalEmail = createProperty("personalEmail");
@@ -352,12 +350,11 @@ public class VCard extends Vocabulary {
*/
public final IRI VCard = createIRI("http://www.w3.org/2006/vcard/ns#VCard");
-
private IRI createProperty(String localName) {
return createProperty(NS, localName);
}
- public VCard(){
+ public VCard() {
super(NS);
}
}
diff --git a/api/src/main/java/org/apache/any23/vocab/Vocabulary.java b/api/src/main/java/org/apache/any23/vocab/Vocabulary.java
index 7e4de65..6a4095c 100644
--- a/api/src/main/java/org/apache/any23/vocab/Vocabulary.java
+++ b/api/src/main/java/org/apache/any23/vocab/Vocabulary.java
@@ -34,15 +34,15 @@ import static java.lang.annotation.RetentionPolicy.RUNTIME;
* Base class for the definition of a vocabulary.
*
* @author Michele Mostarda ( michele.mostarda@gmail.com )
+ *
* @version $Id$
*/
public abstract class Vocabulary {
/**
- * Allows to add comments to <code>namespaces</code>,
- * <code>classes</code> and <code>properties</code>.
+ * Allows to add comments to <code>namespaces</code>, <code>classes</code> and <code>properties</code>.
*/
- @Target({FIELD})
+ @Target({ FIELD })
@Retention(RUNTIME)
@interface Comment {
String value();
@@ -56,26 +56,27 @@ public abstract class Vocabulary {
/**
* Map of vocabulary resources.
*/
- private Map<String,IRI> classes;
+ private Map<String, IRI> classes;
/**
* Map of vocabulary properties.
*/
- private Map<String,IRI> properties;
+ private Map<String, IRI> properties;
/**
* Map any resource with the relative comment.
*/
- private Map<IRI,String> resourceToCommentMap;
+ private Map<IRI, String> resourceToCommentMap;
/**
* Overloaded Constructor.
*
- * @param namespace the namespace IRI prefix.
+ * @param namespace
+ * the namespace IRI prefix.
*/
public Vocabulary(String namespace) {
try {
- this.namespace = SimpleValueFactory.getInstance().createIRI(namespace);
+ this.namespace = SimpleValueFactory.getInstance().createIRI(namespace);
} catch (Exception e) {
throw new IllegalArgumentException("Invalid namespace '" + namespace + "'", e);
}
@@ -91,7 +92,9 @@ public abstract class Vocabulary {
/**
* Returns a class defined within this vocabulary.
*
- * @param name class name.
+ * @param name
+ * class name.
+ *
* @return the IRI associated to such resource.
*/
public IRI getClass(String name) {
@@ -105,7 +108,9 @@ public abstract class Vocabulary {
/**
* Returns a property defined within this vocabulary.
*
- * @param name property name.
+ * @param name
+ * property name.
+ *
* @return the IRI associated to such property.
*/
public IRI getProperty(String name) {
@@ -117,11 +122,13 @@ public abstract class Vocabulary {
}
/**
- * Returns a property defined within this vocabulary, if not found the
- * <code>defaultValue</code> will be returned.
+ * Returns a property defined within this vocabulary, if not found the <code>defaultValue</code> will be returned.
*
- * @param name property name.
- * @param defaultValue the default value if property name not found.
+ * @param name
+ * property name.
+ * @param defaultValue
+ * the default value if property name not found.
+ *
* @return the IRI associated to such property.
*/
public IRI getProperty(String name, IRI defaultValue) {
@@ -133,11 +140,12 @@ public abstract class Vocabulary {
}
/**
- * Returns the property IRI for the specified property string.
- * If the string contains a list of words separated by blank chars,
- * such words are merged and camel case separated.
+ * Returns the property IRI for the specified property string. If the string contains a list of words separated by
+ * blank chars, such words are merged and camel case separated.
*
- * @param property property name.
+ * @param property
+ * property name.
+ *
* @return property IRI.
*/
public IRI getPropertyCamelCase(String property) {
@@ -154,22 +162,22 @@ public abstract class Vocabulary {
* @return the list of all defined classes.
*/
public IRI[] getClasses() {
- if(classes == null) {
+ if (classes == null) {
return new IRI[0];
}
final Collection<IRI> iris = classes.values();
- return iris.toArray( new IRI[ iris.size() ] );
+ return iris.toArray(new IRI[iris.size()]);
}
/**
* @return the list of all defined properties.
*/
public IRI[] getProperties() {
- if(properties == null) {
+ if (properties == null) {
return new IRI[0];
}
final Collection<IRI> iris = properties.values();
- return iris.toArray( new IRI[ iris.size() ] );
+ return iris.toArray(new IRI[iris.size()]);
}
/**
@@ -177,7 +185,7 @@ public abstract class Vocabulary {
*
* @return unmodifiable list of comments.
*/
- public Map<IRI,String> getComments() {
+ public Map<IRI, String> getComments() {
fillResourceToCommentMap();
return Collections.unmodifiableMap(resourceToCommentMap);
}
@@ -185,19 +193,22 @@ public abstract class Vocabulary {
/**
* Returns the comment for the given resource.
*
- * @param resource input resource to have a comment.
- * @return the human readable comment associated to the
- * given resource.
+ * @param resource
+ * input resource to have a comment.
+ *
+ * @return the human readable comment associated to the given resource.
*/
public String getCommentFor(IRI resource) {
fillResourceToCommentMap();
return resourceToCommentMap.get(resource);
}
-
+
/**
* Creates a IRI.
*
- * @param iriStr the IRI string
+ * @param iriStr
+ * the IRI string
+ *
* @return the IRI instance.
*/
protected IRI createIRI(String iriStr) {
@@ -207,13 +218,16 @@ public abstract class Vocabulary {
/**
* Creates a resource and register it to the {@link #classes} map.
*
- * @param namespace vocabulary namespace.
- * @param resource name of the resource.
+ * @param namespace
+ * vocabulary namespace.
+ * @param resource
+ * name of the resource.
+ *
* @return the created resource IRI.
*/
protected IRI createClass(String namespace, String resource) {
IRI res = createIRI(namespace, resource);
- if(classes == null) {
+ if (classes == null) {
classes = new HashMap<>(10);
}
classes.put(resource, res);
@@ -223,13 +237,16 @@ public abstract class Vocabulary {
/**
* Creates a property and register it to the {@link #properties} map.
*
- * @param namespace vocabulary namespace.
- * @param property name of the property.
+ * @param namespace
+ * vocabulary namespace.
+ * @param property
+ * name of the property.
+ *
* @return the created property IRI.
*/
protected IRI createProperty(String namespace, String property) {
IRI res = createIRI(namespace, property);
- if(properties == null) {
+ if (properties == null) {
properties = new HashMap<>(10);
}
properties.put(property, res);
@@ -241,6 +258,7 @@ public abstract class Vocabulary {
*
* @param namespace
* @param localName
+ *
* @return
*/
private IRI createIRI(String namespace, String localName) {
@@ -248,15 +266,15 @@ public abstract class Vocabulary {
}
private void fillResourceToCommentMap() {
- if(resourceToCommentMap != null)
+ if (resourceToCommentMap != null)
return;
- final Map<IRI,String> newMap = new HashMap<>();
+ final Map<IRI, String> newMap = new HashMap<>();
for (Field field : this.getClass().getFields()) {
try {
final Object value = field.get(this);
- if(value instanceof IRI) {
+ if (value instanceof IRI) {
final Comment comment = field.getAnnotation(Comment.class);
- if(comment != null)
+ if (comment != null)
newMap.put((IRI) value, comment.value());
}
} catch (IllegalAccessException iae) {
diff --git a/api/src/main/java/org/apache/any23/vocab/WO.java b/api/src/main/java/org/apache/any23/vocab/WO.java
index 6a28b72..a089187 100644
--- a/api/src/main/java/org/apache/any23/vocab/WO.java
+++ b/api/src/main/java/org/apache/any23/vocab/WO.java
@@ -20,11 +20,12 @@ package org.apache.any23.vocab;
import org.eclipse.rdf4j.model.IRI;
/**
- * <p>The <a href="http://purl.org/ontology/wo/">Wildlife Ontology</a> vocabulary.</p>
- * A simple vocabulary for describing biological species and related taxa.
- * The vocabulary defines terms for describing the names and ranking of taxa,
- * as well as providing support for describing their habitats, conservation status,
- * and behavioural characteristics, etc
+ * <p>
+ * The <a href="http://purl.org/ontology/wo/">Wildlife Ontology</a> vocabulary.
+ * </p>
+ * A simple vocabulary for describing biological species and related taxa. The vocabulary defines terms for describing
+ * the names and ranking of taxa, as well as providing support for describing their habitats, conservation status, and
+ * behavioural characteristics, etc
*
* @author lewismc
* @author Davide Palmisano (dpalmisano@gmail.com)
@@ -39,7 +40,7 @@ public class WO extends Vocabulary {
private static WO instance;
public static WO getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new WO();
}
return instance;
@@ -51,289 +52,279 @@ public class WO extends Vocabulary {
public final IRI NAMESPACE = createIRI(NS);
////////////////////////////////////////////////////////////////////
- //CLASSES
+ // CLASSES
////////////////////////////////////////////////////////////////////
-
- /** An adaptation is any feature of an animal or plant which makes
- * it better suited for a particular habitat or to do a particular
- * task. For instance, being streamlined is an adaptation to swimming
- * fast and being able to survive on very little water is an
- * adaptation to life in the desert.*/
+
+ /**
+ * An adaptation is any feature of an animal or plant which makes it better suited for a particular habitat or to do
+ * a particular task. For instance, being streamlined is an adaptation to swimming fast and being able to survive on
+ * very little water is an adaptation to life in the desert.
+ */
public final IRI Adaption = createClass("Adaption");
- /** Animal Intelligence or animal cognition is the title
- * given to a modern approach to the mental capacities of
- * non-human animals. It has developed out of comparative
- * psychology, but has also been strongly influenced by
- * the approach of ethology, behavioral ecology, and
- * evolutionary psychology.*/
+ /**
+ * Animal Intelligence or animal cognition is the title given to a modern approach to the mental capacities of
+ * non-human animals. It has developed out of comparative psychology, but has also been strongly influenced by the
+ * approach of ethology, behavioral ecology, and evolutionary psychology.
+ */
public final IRI Animal_Intelligence = createClass("AnimalIntelligence");
-
- /** Behavioural pattern describes an animal's dominant way of
- * life. Arboreal animals, for example, live in trees and
- * nocturnal animals are active at night.*/
+
+ /**
+ * Behavioural pattern describes an animal's dominant way of life. Arboreal animals, for example, live in trees and
+ * nocturnal animals are active at night.
+ */
public final IRI BehaviouralPattern = createClass("BehaviouralPattern");
-
- /** A class is a scientific way to group related organisms
- * together, some examples of classes being jellyfish,
- * reptiles and sea urchins. Classes are big groups and
- * contain within them smaller groupings called orders,
- * families, genera and species.*/
+
+ /**
+ * A class is a scientific way to group related organisms together, some examples of classes being jellyfish,
+ * reptiles and sea urchins. Classes are big groups and contain within them smaller groupings called orders,
+ * families, genera and species.
+ */
public final IRI Class = createClass("Class");
-
- /** A collection of resources, including documents,
- * multimedia files, programme clips and their associated .
- * taxa, which aims to showcase a particular aspect of
- * natural history film-making, or illustrate aspects of
- * the natural world. A collection provides an alternate
- * way to organize content over and above the basic
- * taxonomic hierarchy.*/
+
+ /**
+ * A collection of resources, including documents, multimedia files, programme clips and their associated . taxa,
+ * which aims to showcase a particular aspect of natural history film-making, or illustrate aspects of the natural
+ * world. A collection provides an alternate way to organize content over and above the basic taxonomic hierarchy.
+ */
public final IRI Collection = createClass("Collection");
-
- /** Communication and senses are how an organism perceives
- * the world - for instance through scent or sight - and
- * how it sends messages or warnings to others.*/
+
+ /**
+ * Communication and senses are how an organism perceives the world - for instance through scent or sight - and how
+ * it sends messages or warnings to others.
+ */
public final IRI CommunicationAdaption = createClass("CommunicationAdaption");
-
- /** Conservation status as described by the IUCN Red List.
- * Will typically have a number of properties including an
- * official IUCN status, population trend, and a year of assessment.*/
+
+ /**
+ * Conservation status as described by the IUCN Red List. Will typically have a number of properties including an
+ * official IUCN status, population trend, and a year of assessment.
+ */
public final IRI ConservationStatus = createClass("ConservationStatus");
-
- /** Ecosystem roles are about the part an animal or plant
- * plays in sustaining or maintaining the habitat around them.
- * Bees, for example, pollinate flowers, without which those
- * plants would not produce fruits or seeds. Other species,
- * such as dung beetles, play a vital role in keeping grasslands
- * clear of animal waste and recycling valuable resources.*/
+
+ /**
+ * Ecosystem roles are about the part an animal or plant plays in sustaining or maintaining the habitat around them.
+ * Bees, for example, pollinate flowers, without which those plants would not produce fruits or seeds. Other
+ * species, such as dung beetles, play a vital role in keeping grasslands clear of animal waste and recycling
+ * valuable resources.
+ */
public final IRI EcosystemRole = createClass("EcosystemRole");
-
- /** Ecozones are a method of dividing up the Earth's surface.
- * Each ecozone is a large area that contains a number of
- * habitats, which are linked by the evolutionary history
- * of the animals and plants within them. For instance one
- * ecozone is Australasia, because its marsupials evolved
- * in isolation to mammals in the rest of the world.*/
+
+ /**
+ * Ecozones are a method of dividing up the Earth's surface. Each ecozone is a large area that contains a number of
+ * habitats, which are linked by the evolutionary history of the animals and plants within them. For instance one
+ * ecozone is Australasia, because its marsupials evolved in isolation to mammals in the rest of the world.
+ */
public final IRI Ecozone = createClass("Ecozone");
-
- /** Organisms that are adapted to extremes (known as Extremophiles)
- * are organisms that thrives in and even may require physically
- * or geochemically extreme conditions that are detrimental
- * to the majority of life on Earth.*/
+
+ /**
+ * Organisms that are adapted to extremes (known as Extremophiles) are organisms that thrives in and even may
+ * require physically or geochemically extreme conditions that are detrimental to the majority of life on Earth.
+ */
public final IRI ExtremesAdaptiation = createClass("ExtremesAdaptiation");
-
- /** A family is a scientific grouping of closely related organisms.
- * It has smaller groups, called genera and species, within it. A
- * family can have a lot of members or only a few. Examples of
- * families include the cats (Felidae), the gulls (Laridae) and
- * the grasses (Poaceae). Further Reading:
- * http://en.wikipedia.org/wiki/Family_%28biology%29
- * http://www.bbc.co.uk/nature/family*/
+
+ /**
+ * A family is a scientific grouping of closely related organisms. It has smaller groups, called genera and species,
+ * within it. A family can have a lot of members or only a few. Examples of families include the cats (Felidae), the
+ * gulls (Laridae) and the grasses (Poaceae). Further Reading: http://en.wikipedia.org/wiki/Family_%28biology%29
+ * http://www.bbc.co.uk/nature/family
+ */
public final IRI Family = createClass("Family");
-
- /** Feeding habits describe the dominant diet of a particular
- * species or group of species, and how they go about obtaining it.*/
+
+ /**
+ * Feeding habits describe the dominant diet of a particular species or group of species, and how they go about
+ * obtaining it.
+ */
public final IRI FeedingHabit = createClass("FeedingHabit");
-
- /** Freshwater habitats include bogs, ponds, lakes, rivers and streams.
- * About 3% of Earth's water is freshwater, but this includes the water
- * locked up in the ice caps and trapped in rocks and soil as groundwater.
- * Only a tiny fraction (0.014%) is surface water in the form of rivers,
- * lakes and swamps.*/
+
+ /**
+ * Freshwater habitats include bogs, ponds, lakes, rivers and streams. About 3% of Earth's water is freshwater, but
+ * this includes the water locked up in the ice caps and trapped in rocks and soil as groundwater. Only a tiny
+ * fraction (0.014%) is surface water in the form of rivers, lakes and swamps.
+ */
public final IRI FreshwaterHabitat = createClass("FreshwaterHabitat");
-
- /** A genus is a scientific way of showing that species are very closed
- * related to each other. In fact the first word of the species'
- * scientific name is its genus. So for lions (Panthera leo), Panthera
- * is the genus and tells us that they are closely related to tigers
- * (Panthera tigris), because they share the name. Further Reading:
- * http://en.wikipedia.org/wiki/Genus
- * http://www.bbc.co.uk/nature/genus
- * */
+
+ /**
+ * A genus is a scientific way of showing that species are very closed related to each other. In fact the first word
+ * of the species' scientific name is its genus. So for lions (Panthera leo), Panthera is the genus and tells us
+ * that they are closely related to tigers (Panthera tigris), because they share the name. Further Reading:
+ * http://en.wikipedia.org/wiki/Genus http://www.bbc.co.uk/nature/genus
+ */
public final IRI Genus = createClass("Genus");
-
- /** A habitat, or biome, is the type of environment in which plant
- * and animals live. Habitat is dictated by what kinds of plants
- * grow there, the climate and the geography. Rainforest, coral
- * reefs and the tundra are all habitats where particular kinds
- * of plants and animals might be found. Further Reading:
- * http://en.wikipedia.org/wiki/Habitat
- * http://www.bbc.co.uk/nature/habitats */
+
+ /**
+ * A habitat, or biome, is the type of environment in which plant and animals live. Habitat is dictated by what
+ * kinds of plants grow there, the climate and the geography. Rainforest, coral reefs and the tundra are all
+ * habitats where particular kinds of plants and animals might be found. Further Reading:
+ * http://en.wikipedia.org/wiki/Habitat http://www.bbc.co.uk/nature/habitats
+ */
public final IRI Habitat = createClass("Habitat");
-
- /** Infraorders are a subdivision of suborders - thus infraorders
- * are an intermediate rank of classification, that group together
- * related superfamilies and families. The tarsiers are a infraorder
- * of primates, containing a single extant family, whilst
- * shrimps (Caridea) are an example of an infraorder which
- * encompases many related superfamiles. Ceratopsia is the
- * infraorder that contains all the horned dinosaurs. Further Reading:
- * http://en.wikipedia.org/wiki/Infraorder
- * http://www.bbc.co.uk/nature/infraorder*/
+
+ /**
+ * Infraorders are a subdivision of suborders - thus infraorders are an intermediate rank of classification, that
+ * group together related superfamilies and families. The tarsiers are a infraorder of primates, containing a single
+ * extant family, whilst shrimps (Caridea) are an example of an infraorder which encompases many related
+ * superfamiles. Ceratopsia is the infraorder that contains all the horned dinosaurs. Further Reading:
+ * http://en.wikipedia.org/wiki/Infraorder http://www.bbc.co.uk/nature/infraorder
+ */
public final IRI Infraorder = createClass("Infraorder");
-
- /** Kingdoms are the major categories into which scientists
- * divide up all living things. The main kingdoms are animals,
- * plants, fungi and bacteria, although there are others.
- * Each kingdom has its own suite of defining characteristics -
- * for instance plants have rigid cell walls, whilst animals
- * do not. Further Reading:
- * http://en.wikipedia.org/wiki/Kingdom_%28biology%29
- * http://www.bbc.co.uk/nature/kingdom*/
+
+ /**
+ * Kingdoms are the major categories into which scientists divide up all living things. The main kingdoms are
+ * animals, plants, fungi and bacteria, although there are others. Each kingdom has its own suite of defining
+ * characteristics - for instance plants have rigid cell walls, whilst animals do not. Further Reading:
+ * http://en.wikipedia.org/wiki/Kingdom_%28biology%29 http://www.bbc.co.uk/nature/kingdom
+ */
public final IRI Kingdom = createClass("Kingdom");
-
- /** An organism's Life Cycle describes the stages in an
- * organisms development including metamorphosis, courtship
- * displays and parental care.*/
+
+ /**
+ * An organism's Life Cycle describes the stages in an organisms development including metamorphosis, courtship
+ * displays and parental care.
+ */
public final IRI Lifecycle = createClass("Lifecycle");
-
- /** Locomotion is how an animal gets around - for instance by swimming,
- * flying or climbing.*/
+
+ /**
+ * Locomotion is how an animal gets around - for instance by swimming, flying or climbing.
+ */
public final IRI LocomotionAdaption = createClass("LocomotionAdaption");
-
- /** Approximately 71% of the Earth's surface is covered by the oceans,
- * an area of some 223698816km/sq. Although marine life evolved around
- * three billion years before life on land, marine habitats are relatively
- * poorly studied and much of the ocean's depths remains unexplored.*/
+
+ /**
+ * Approximately 71% of the Earth's surface is covered by the oceans, an area of some 223698816km/sq. Although
+ * marine life evolved around three billion years before life on land, marine habitats are relatively poorly studied
+ * and much of the ocean's depths remains unexplored.
+ */
public final IRI MarineHabitat = createClass("MarineHabitat");
-
- /** Morphology is anything to do with what a plant or animal looks like -
- * its size, shape, colour or structure.*/
+
+ /**
+ * Morphology is anything to do with what a plant or animal looks like - its size, shape, colour or structure.
+ */
public final IRI Morphology = createClass("Morphology");
-
- /** An order is a scientific way to categorise related organisms.
- * An order is a smaller grouping than a class, but bigger than
- * a family or genus. Examples of orders are willows, cockroaches
- * and primates. Further Reading:
- * http://en.wikipedia.org/wiki/Order_%28biology%29
- * http://www.bbc.co.uk/nature/order*/
+
+ /**
+ * An order is a scientific way to categorise related organisms. An order is a smaller grouping than a class, but
+ * bigger than a family or genus. Examples of orders are willows, cockroaches and primates. Further Reading:
+ * http://en.wikipedia.org/wiki/Order_%28biology%29 http://www.bbc.co.uk/nature/order
+ */
public final IRI Order = createClass("Order");
-
- /** A phylum - also known as a division when referring to plants -
- * is a scientfic way of grouping together related organisms.
- * All the members of a phylum have a common ancestor and
- * anatomical similarities. For instance, all the arthropods
- * have external skeletons. Phlya are large groups and are
- * further subdivided into classes, orders, families and so on.
- * Further Reading: http://en.wikipedia.org/wiki/Phylum
- * http://www.bbc.co.uk/nature/phylum*/
+
+ /**
+ * A phylum - also known as a division when referring to plants - is a scientfic way of grouping together related
+ * organisms. All the members of a phylum have a common ancestor and anatomical similarities. For instance, all the
+ * arthropods have external skeletons. Phlya are large groups and are further subdivided into classes, orders,
+ * families and so on. Further Reading: http://en.wikipedia.org/wiki/Phylum http://www.bbc.co.uk/nature/phylum
+ */
public final IRI Phylum = createClass("Phylum");
- /** Predation is catching and killing an animal in order to eat it.
- * The prey can be chased, ambushed or caught in a trap such as a
- * spider's web.*/
+ /**
+ * Predation is catching and killing an animal in order to eat it. The prey can be chased, ambushed or caught in a
+ * trap such as a spider's web.
+ */
public final IRI PredationStrategy = createClass("PredationStrategy");
-
- /** A category in the IUCN red list, 2001. Further Reading:
+
+ /**
+ * A category in the IUCN red list, 2001. Further Reading:
* http://www.iucnredlist.org/technical-documents/categories-and-criteria/2001-categories-criteria
*/
public final IRI RedListStatus = createClass("RedListStatus");
-
- /** Reproduction covers all the tactics and behaviours involved in obtaining
- * a mate, conceiving the next generation and successfully raising them.
- * It includes everything from plants being pollinated, to stags
- * fighting over hinds, to lionesses babysitting their sisters' cubs.*/
+
+ /**
+ * Reproduction covers all the tactics and behaviours involved in obtaining a mate, conceiving the next generation
+ * and successfully raising them. It includes everything from plants being pollinated, to stags fighting over hinds,
+ * to lionesses babysitting their sisters' cubs.
+ */
public final IRI ReproductionStrategy = createClass("ReproductionStrategy");
-
- /** Social behaviour is all about how an animal interacts with members
- * of its own species. For instance, does it live in a colony or on
- * its own, does it fight to be top of the pecking order, or does
- * it try to keep strangers away from its home?*/
+
+ /**
+ * Social behaviour is all about how an animal interacts with members of its own species. For instance, does it live
+ * in a colony or on its own, does it fight to be top of the pecking order, or does it try to keep strangers away
+ * from its home?
+ */
public final IRI SocialBehaviour = createClass("SocialBehaviour");
-
- /** Generic class defining a biological species. Further Reading:
- * http://en.wikipedia.org/wiki/Species
- * http://www.bbc.co.uk/nature/species*/
+
+ /**
+ * Generic class defining a biological species. Further Reading: http://en.wikipedia.org/wiki/Species
+ * http://www.bbc.co.uk/nature/species
+ */
public final IRI Species = createClass("Species");
-
- /** Suborders are an intermediate classification rank -
- * an order can be split into many closely related suborders.
- * Suborders are therefore of lower rank than a order, but
- * higher than a infraorder or a family. All modern
- * snakes are placed within a suborder (Serpentes).
- * Theropoda is another suborder to which many
- * famous carnivorous dinosaurs belong. Further Reading:
- * http://en.wikipedia.org/wiki/Suborder
- * http://www.bbc.co.uk/nature/suborder*/
+
+ /**
+ * Suborders are an intermediate classification rank - an order can be split into many closely related suborders.
+ * Suborders are therefore of lower rank than a order, but higher than a infraorder or a family. All modern snakes
+ * are placed within a suborder (Serpentes). Theropoda is another suborder to which many famous carnivorous
+ * dinosaurs belong. Further Reading: http://en.wikipedia.org/wiki/Suborder http://www.bbc.co.uk/nature/suborder
+ */
public final IRI Suborder = createClass("Suborder");
-
- /** Subspecies are a rank of classification that is lower
- * than a species. The differences between subspecies are
- * less distinct than between species. Generally speaking
- * two subspecies can successfully interbreed but two species
- * cannot. If a subspecies can be shown to be different
- * enough, then it can be elevated to the status of species.
- * There are several subspecies of tiger (Panthera tigris)
- * including the Bengal tiger (Panthera tigris tigris),
- * Sumatran tiger (Panthera tigris sumatrae) and Siberian
- * tiger (Panthera tigris altaica). Further Reading:
- * http://en.wikipedia.org/wiki/Subspecies
- * http://www.bbc.co.uk/nature/subspecies*/
+
+ /**
+ * Subspecies are a rank of classification that is lower than a species. The differences between subspecies are less
+ * distinct than between species. Generally speaking two subspecies can successfully interbreed but two species
+ * cannot. If a subspecies can be shown to be different enough, then it can be elevated to the status of species.
+ * There are several subspecies of tiger (Panthera tigris) including the Bengal tiger (Panthera tigris tigris),
+ * Sumatran tiger (Panthera tigris sumatrae) and Siberian tiger (Panthera tigris altaica). Further Reading:
+ * http://en.wikipedia.org/wiki/Subspecies http://www.bbc.co.uk/nature/subspecies
+ */
public final IRI Subspecies = createClass("Subspecies");
-
- /** Superclass is an intermediate classification rank, or
- * grouping, that sits directly above a class, ranking
- * below a phylum or subphylum and containing one or more
- * classes. The tetrapods are a superclass encompasing the
- * amphibian, reptile, bird, mammal and dinosaur classes.
- * Further Reading: http://en.wikipedia.org/wiki/Superclass_(biology)
- * http://www.bbc.co.uk/nature/superclass*/
+
+ /**
+ * Superclass is an intermediate classification rank, or grouping, that sits directly above a class, ranking below a
+ * phylum or subphylum and containing one or more classes. The tetrapods are a superclass encompasing the amphibian,
+ * reptile, bird, mammal and dinosaur classes. Further Reading: http://en.wikipedia.org/wiki/Superclass_(biology)
+ * http://www.bbc.co.uk/nature/superclass
+ */
public final IRI Superclass = createClass("Superclass");
-
- /** Superfamilies are an intermediate classification rank,
- * or grouping, that is directly above a family. A
- * superfamily may contain one or more related families.
- * Dung beetles are a superfamily containing the stag,
- * bess and scarab beetle families. There is also a
- * superfamily of rodents (muroidea) containing six families
- * of rats, mice, hamsters and gerbils. Further Reading:
- * http://en.wikipedia.org/wiki/Taxonomic_rank
- * http://www.bbc.co.uk/nature/superfamily*/
+
+ /**
+ * Superfamilies are an intermediate classification rank, or grouping, that is directly above a family. A
+ * superfamily may contain one or more related families. Dung beetles are a superfamily containing the stag, bess
+ * and scarab beetle families. There is also a superfamily of rodents (muroidea) containing six families of rats,
+ * mice, hamsters and gerbils. Further Reading: http://en.wikipedia.org/wiki/Taxonomic_rank
+ * http://www.bbc.co.uk/nature/superfamily
+ */
public final IRI Superfamily = createClass("Superfamily");
-
- /** Superorders are an intermediate classification rank or
- * grouping that sit directly above an order. A superorder
- * may contain several orders. Sharks are a good example of
- * a superorder, grouping together eight living orders of shark,
- * as well as, five extinct orders. Perhaps the most famous
- * superorder of them all is Dinosauria - the dinosaurs!
- * Further Reading: http://en.wikipedia.org/wiki/Superorder
- * http://www.bbc.co.uk/nature/superorder*/
+
+ /**
+ * Superorders are an intermediate classification rank or grouping that sit directly above an order. A superorder
+ * may contain several orders. Sharks are a good example of a superorder, grouping together eight living orders of
+ * shark, as well as, five extinct orders. Perhaps the most famous superorder of them all is Dinosauria - the
+ * dinosaurs! Further Reading: http://en.wikipedia.org/wiki/Superorder http://www.bbc.co.uk/nature/superorder
+ */
public final IRI Superorder = createClass("Superorder");
-
- /** Survival strategies include adaptations to changes in .
- * the organisms environment, including: hibernation, abscission and migration.*/
+
+ /**
+ * Survival strategies include adaptations to changes in . the organisms environment, including: hibernation,
+ * abscission and migration.
+ */
public final IRI SurvivalStrategy = createClass("SurvivalStrategy");
-
- /** A taxonomic name, describing the structure and provenance of a taxonomic name.*/
+
+ /** A taxonomic name, describing the structure and provenance of a taxonomic name. */
public final IRI TaxonName = createClass("TaxonName");
-
- /** Generic concept for a taxonomic rank such as a Genus or Species.
- * Further Reading: http://en.wikipedia.org/wiki/Taxonomic_rank
-*/
- public final IRI TaxonRank= createClass("TaxonRank");
-
- /** Terrestrial habitats include forests, grasslands, deserts
- * and rainforests. They are typically defined by factors such
- * as plant structure (trees and grasses), leaf types (eg broadleaf
- * and needleleaf), plant spacing (forest, woodland, savanna) and climate.*/
+
+ /**
+ * Generic concept for a taxonomic rank such as a Genus or Species. Further Reading:
+ * http://en.wikipedia.org/wiki/Taxonomic_rank
+ */
+ public final IRI TaxonRank = createClass("TaxonRank");
+
+ /**
+ * Terrestrial habitats include forests, grasslands, deserts and rainforests. They are typically defined by factors
+ * such as plant structure (trees and grasses), leaf types (eg broadleaf and needleleaf), plant spacing (forest,
+ * woodland, savanna) and climate.
+ */
public final IRI TerrestrialHabitat = createClass("TerrestrialHabitat");
-
- /** Tribes are a taxonomic rank that fall between family and genus.
- * Tribes can also be split in to smaller related groups called subtribes.
- * Tribes are mainly, but not always, used in botany to classify plants.
- * The true grass family is divided up into many subfamiles and then into
- * tribes, one of which is bamboo. The insect world also uses tribes
- * as a classification rank, for example, bombini is the tribe of bumblebees.
- * Further Reading: http://en.wikipedia.org/wiki/Tribe_(biology)
- * http://www.bbc.co.uk/nature/tribe*/
+
+ /**
+ * Tribes are a taxonomic rank that fall between family and genus. Tribes can also be split in to smaller related
+ * groups called subtribes. Tribes are mainly, but not always, used in botany to classify plants. The true grass
+ * family is divided up into many subfamiles and then into tribes, one of which is bamboo. The insect world also
+ * uses tribes as a classification rank, for example, bombini is the tribe of bumblebees. Further Reading:
+ * http://en.wikipedia.org/wiki/Tribe_(biology) http://www.bbc.co.uk/nature/tribe
+ */
public final IRI Tribe = createClass("Tribe");
//////////////////////////////////////////////////////////
- //PROPERTIES
+ // PROPERTIES
//////////////////////////////////////////////////////////
/**
- * associates a taxon rank with an adaptation which it displays
+ * associates a taxon rank with an adaptation which it displays
*/
public final IRI adaptation = createProperty("adaptation");
@@ -341,7 +332,7 @@ public class WO extends Vocabulary {
* associates a taxon rank with a class
*/
public final IRI clazz = createProperty("class");
-
+
/**
* associates a taxon rank, habitat, species, clip with a collection of which it is a member
*/
@@ -365,9 +356,11 @@ public class WO extends Vocabulary {
/** associates a taxon rank with a genus */
public final IRI genus = createProperty("genus");
-
- /** associates a taxon rank with a habitat in which it grows.
- * Sub-property of wo:habitat to be used for plants, fungi, etc */
+
+ /**
+ * associates a taxon rank with a habitat in which it grows. Sub-property of wo:habitat to be used for plants,
+ * fungi, etc
+ */
public final IRI growsIn = createProperty("growsIn");
/** associates a taxon rank with a habitat in which it may typically be found */
@@ -376,11 +369,13 @@ public class WO extends Vocabulary {
/** associates a taxon rank with a infraorder */
public final IRI infraorder = createProperty("infraorder");
- /** associates a taxon rank with a kingdom*/
+ /** associates a taxon rank with a kingdom */
public final IRI kingdom = createProperty("kingdom");
- /** associates a taxon rank with a habitat in which it lives.
- * Sub-property of wo:habitat to be used for members of the animal kingdom */
+ /**
+ * associates a taxon rank with a habitat in which it lives. Sub-property of wo:habitat to be used for members of
+ * the animal kingdom
+ */
public final IRI livesIn = createProperty("livesIn");
/** associates a taxon rank with a taxon name */
@@ -391,124 +386,127 @@ public class WO extends Vocabulary {
/** associates a taxon rank with a phylum */
public final IRI phylum = createProperty("phylum");
-
- /** associates a Conservation Status with a category in the IUCN Red List*/
+
+ /** associates a Conservation Status with a category in the IUCN Red List */
public final IRI redListStatus = createProperty("redListStatus");
-
- /** associates a taxon rank with a species*/
+
+ /** associates a taxon rank with a species */
public final IRI species = createProperty("species");
-
- /** associates a taxon rank with a subspecies*/
+
+ /** associates a taxon rank with a subspecies */
public final IRI subspecies = createProperty("subspecies");
-
- /** associates a taxon rank with a suborder*/
+
+ /** associates a taxon rank with a suborder */
public final IRI suborder = createProperty("suborder");
-
- /** associates a taxon rank with a superclass*/
+
+ /** associates a taxon rank with a superclass */
public final IRI superclass = createProperty("superclass");
-
- /** associates a taxon rank with a superfamily*/
+
+ /** associates a taxon rank with a superfamily */
public final IRI superfamily = createProperty("superfamily");
-
- /** associates a taxon rank with a superorder*/
+
+ /** associates a taxon rank with a superorder */
public final IRI superorder = createProperty("superorder");
-
- /** associates a taxon rank with a tribe*/
+
+ /** associates a taxon rank with a tribe */
public final IRI tribe = createProperty("tribe");
-
+
//////////////////////////////////////////////////////////////
- //DATATYPE PROPERTIES
+ // DATATYPE PROPERTIES
//////////////////////////////////////////////////////////////
-
- /** Used to specify the name of a class as part of a Taxon Name*/
+
+ /** Used to specify the name of a class as part of a Taxon Name */
public final IRI clazzName = createProperty("className");
-
- /** associates a formal taxon name with a common version. E.g.
- * Panthera leo might be associated with a common name of 'Lion'.
- * A given taxon name may have several common names*/
+
+ /**
+ * associates a formal taxon name with a common version. E.g. Panthera leo might be associated with a common name of
+ * 'Lion'. A given taxon name may have several common names
+ */
public final IRI commonName = createProperty("commonName");
-
- /** Used to specify the name of a family as part of a Taxon Name*/
+
+ /** Used to specify the name of a family as part of a Taxon Name */
public final IRI familyName = createProperty("familyName");
-
- /** specifies the genus part of a binomial name, allowing this
- * portion of the name to be explicitly described. Therefore this
- * property will typically only be used in TaxonNames associated
- * with species. The property is largely provided as a convenience
- * to avoid applications having to parse the binomial name.*/
+
+ /**
+ * specifies the genus part of a binomial name, allowing this portion of the name to be explicitly described.
+ * Therefore this property will typically only be used in TaxonNames associated with species. The property is
+ * largely provided as a convenience to avoid applications having to parse the binomial name.
+ */
public final IRI genusName = createProperty("genusName");
-
- /** Used to specify the name of a infraorder as part of a Taxon Name*/
+
+ /** Used to specify the name of a infraorder as part of a Taxon Name */
public final IRI infraorderName = createProperty("infraorderName");
-
+
/** Used to specify the name of a kingdom as part of a Taxon Name */
public final IRI kingdomName = createProperty("kingdomName");
-
+
/** Used to specify the name of an order as part of a Taxon Name */
public final IRI orderName = createProperty("orderName");
-
+
/** Used to specify the name of a phylum as part of a Taxon Name */
public final IRI phylumName = createProperty("phylumName");
-
- /** provides some indication of the population trend associated with an
- * assessment of a taxon's conversation status. The value of this
- * property is a simple literal, and is recommended to be one of:
- * Decreasing, Increasing, Stable, Unknown.*/
+
+ /**
+ * provides some indication of the population trend associated with an assessment of a taxon's conversation status.
+ * The value of this property is a simple literal, and is recommended to be one of: Decreasing, Increasing, Stable,
+ * Unknown.
+ */
public final IRI populationTrend = createProperty("populationTrend");
-
- /** associates a taxon name with its formal scientific name. This
- * may be a binomial name (e.g. Panthera leo) in the case of a
- * species name, or a uninomial (e.g. Panthera) name in the case
- * of a name associated with another taxon rank. In formal
- * taxonomic naming conventions, the scientific name is often
- * qualified with the source of the name, e.g. Panthera leo (Linnaeus, 1758).*/
+
+ /**
+ * associates a taxon name with its formal scientific name. This may be a binomial name (e.g. Panthera leo) in the
+ * case of a species name, or a uninomial (e.g. Panthera) name in the case of a name associated with another taxon
+ * rank. In formal taxonomic naming conventions, the scientific name is often qualified with the source of the name,
+ * e.g. Panthera leo (Linnaeus, 1758).
+ */
public final IRI scientificName = createProperty("scientificName");
-
- /** associates a short description with a Collection.*/
+
+ /** associates a short description with a Collection. */
public final IRI shortDescription = createProperty("shortDescription");
-
- /** specifies the species part of a binomial name, allowing this
- * portion of the name to be explicitly described. Therefore
- * this property will typically only be used in TaxonNames
- * associated with species. The property is largely provided
- * as a convenience to avoid applications having to parse the
- * binomial name.*/
+
+ /**
+ * specifies the species part of a binomial name, allowing this portion of the name to be explicitly described.
+ * Therefore this property will typically only be used in TaxonNames associated with species. The property is
+ * largely provided as a convenience to avoid applications having to parse the binomial name.
+ */
public final IRI speciesName = createProperty("speciesName");
-
- /** Used to specify the name of a suborder as part of a Taxon Name*/
+
+ /** Used to specify the name of a suborder as part of a Taxon Name */
public final IRI suborderName = createProperty("suborderName");
-
- /** Used to specify the name of a subspecies as part of a Taxon Name*/
+
+ /** Used to specify the name of a subspecies as part of a Taxon Name */
public final IRI subspeciesName = createProperty("subspeciesName");
-
- /** Used to specify the name of a superspecies as part of a Taxon Name*/
+
+ /** Used to specify the name of a superspecies as part of a Taxon Name */
public final IRI superspeciesName = createProperty("superspeciesName");
-
- /** Used to specify the name of a superclass as part of a Taxon Name*/
+
+ /** Used to specify the name of a superclass as part of a Taxon Name */
public final IRI superclassName = createProperty("superclassName");
-
- /** Used to specify the name of a superfamily as part of a Taxon Name*/
+
+ /** Used to specify the name of a superfamily as part of a Taxon Name */
public final IRI superfamilyName = createProperty("superfamilyName");
-
- /** Used to specify the name of a superorder as part of a Taxon Name*/
+
+ /** Used to specify the name of a superorder as part of a Taxon Name */
public final IRI superorderName = createProperty("superorderName");
-
- /** a naming property, associating a formal taxonomic name with a Taxon
- * Name instance. This property is a parent of a number of sub-properties
- * that provide more specific terms for denoting names of families, phyla,
- * species, etc.*/
+
+ /**
+ * a naming property, associating a formal taxonomic name with a Taxon Name instance. This property is a parent of a
+ * number of sub-properties that provide more specific terms for denoting names of families, phyla, species, etc.
+ */
public final IRI taxonomicName = createProperty("taxonomicName");
-
- /** description of the threat(s) that have been identified as part of
- * the assessment of the Conservation Status of a taxon*/
+
+ /**
+ * description of the threat(s) that have been identified as part of the assessment of the Conservation Status of a
+ * taxon
+ */
public final IRI threatDescription = createProperty("threatDescription");
-
- /** Used to specify the name of a tribe as part of a Taxon Name*/
+
+ /** Used to specify the name of a tribe as part of a Taxon Name */
public final IRI tribeName = createProperty("tribeName");
-
- /** the year in which the conservation status was assessed.*/
+
+ /** the year in which the conservation status was assessed. */
public final IRI yearAssessed = createProperty("yearAssessed");
-
+
private IRI createClass(String name) {
return createClass(NS, name);
}
@@ -517,7 +515,7 @@ public class WO extends Vocabulary {
return createProperty(NS, name);
}
- private WO(){
+ private WO() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/XFN.java b/api/src/main/java/org/apache/any23/vocab/XFN.java
index 428868d..97d2e71 100644
--- a/api/src/main/java/org/apache/any23/vocab/XFN.java
+++ b/api/src/main/java/org/apache/any23/vocab/XFN.java
@@ -35,33 +35,33 @@ public class XFN extends Vocabulary {
private static XFN instance;
public static XFN getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new XFN();
}
return instance;
}
- public final IRI contact = createProperty("contact");
+ public final IRI contact = createProperty("contact");
public final IRI acquaintance = createProperty("acquaintance");
- public final IRI friend = createProperty("friend");
- public final IRI met = createProperty("met");
- public final IRI coWorker = createProperty("co-worker");
- public final IRI colleague = createProperty("colleague");
- public final IRI coResident = createProperty("co-resident");
- public final IRI neighbor = createProperty("neighbor");
- public final IRI child = createProperty("child");
- public final IRI parent = createProperty("parent");
- public final IRI spouse = createProperty("spouse");
- public final IRI kin = createProperty("kin");
- public final IRI muse = createProperty("muse");
- public final IRI crush = createProperty("crush");
- public final IRI date = createProperty("date");
- public final IRI sweetheart = createProperty("sweetheart");
- public final IRI me = createProperty("me");
+ public final IRI friend = createProperty("friend");
+ public final IRI met = createProperty("met");
+ public final IRI coWorker = createProperty("co-worker");
+ public final IRI colleague = createProperty("colleague");
+ public final IRI coResident = createProperty("co-resident");
+ public final IRI neighbor = createProperty("neighbor");
+ public final IRI child = createProperty("child");
+ public final IRI parent = createProperty("parent");
+ public final IRI spouse = createProperty("spouse");
+ public final IRI kin = createProperty("kin");
+ public final IRI muse = createProperty("muse");
+ public final IRI crush = createProperty("crush");
+ public final IRI date = createProperty("date");
+ public final IRI sweetheart = createProperty("sweetheart");
+ public final IRI me = createProperty("me");
public final IRI mePage = createProperty(NS, "mePage");
- private Map<String, IRI> PeopleXFNProperties;
+ private Map<String, IRI> PeopleXFNProperties;
private Map<String, IRI> HyperlinkXFNProperties;
@@ -82,11 +82,11 @@ public class XFN extends Vocabulary {
}
private IRI createProperty(String localName) {
- if(HyperlinkXFNProperties == null) {
+ if (HyperlinkXFNProperties == null) {
HyperlinkXFNProperties = new HashMap<String, IRI>();
}
- if(PeopleXFNProperties == null) {
- PeopleXFNProperties = new HashMap<String, IRI>();
+ if (PeopleXFNProperties == null) {
+ PeopleXFNProperties = new HashMap<String, IRI>();
}
IRI result = createProperty(NS, localName + "-hyperlink");
@@ -97,7 +97,7 @@ public class XFN extends Vocabulary {
return result;
}
- private XFN(){
+ private XFN() {
super(NS);
}
diff --git a/api/src/main/java/org/apache/any23/vocab/XHTML.java b/api/src/main/java/org/apache/any23/vocab/XHTML.java
index 134b9b2..3a10c02 100644
--- a/api/src/main/java/org/apache/any23/vocab/XHTML.java
+++ b/api/src/main/java/org/apache/any23/vocab/XHTML.java
@@ -29,19 +29,19 @@ public class XHTML extends Vocabulary {
private static XHTML instance;
public static XHTML getInstance() {
- if(instance == null) {
+ if (instance == null) {
instance = new XHTML();
}
return instance;
}
- public final IRI license = createProperty(NS, "license" );
- public final IRI meta = createProperty(NS, "meta" );
- public final IRI alternate = createProperty(NS, "alternate" );
+ public final IRI license = createProperty(NS, "license");
+ public final IRI meta = createProperty(NS, "meta");
+ public final IRI alternate = createProperty(NS, "alternate");
public final IRI stylesheet = createProperty(NS, "stylesheet");
- private XHTML(){
+ private XHTML() {
super(NS);
}
-
+
}
diff --git a/api/src/main/java/org/apache/any23/vocab/YAML.java b/api/src/main/java/org/apache/any23/vocab/YAML.java
index 0236b81..945cf97 100644
--- a/api/src/main/java/org/apache/any23/vocab/YAML.java
+++ b/api/src/main/java/org/apache/any23/vocab/YAML.java
@@ -25,64 +25,66 @@ import org.eclipse.rdf4j.model.IRI;
*/
public class YAML extends Vocabulary {
- /*
- * Namespace of YAML vocabulary
- */
- public static final String NS = "http://yaml.org/spec/1.2/spec.html#";
-
- public static final String PREFIX = "yaml";
-
- public static final String ROOT = "Root";
-
- public static final String DOCUMENT = "Document";
-
- public static final String NODE = "Node";
-
- public static final String SEQUENCE = "Sequence" ;
-
- public static final String MAPPING = "Mapping";
-
- public static final String CONTAINS = "contains";
-
- public static final String NULL = "Null";
-
- private static final YAML _instance = new YAML();
-
- private YAML() {
- super(NS);
- }
-
- public static YAML getInstance() {
- return _instance;
- }
-
- // Resources
- /**
- * <p>The root node. Representation of the YAML file. NB: one file may contain more than one documents
- * represented by nodes; e.g. </p>
- * <p>
- * <code>
- * %YAML 1.2
- * ---
- * - data1
- * - data2
- * ---
- * - data3
- * </code>
- * </p>
- * Contains two documents.
- */
- public final IRI root = createClass(NS, ROOT);
-
- public final IRI document = createClass(NS, DOCUMENT);
-
- public final IRI node = createClass(NS, NODE);
-
- public final IRI sequence = createClass(NS, SEQUENCE);
-
- public final IRI mapping = createClass(NS, MAPPING);
- // property
- public final IRI contains = createProperty(NS, CONTAINS);
-
- public final IRI nullValue = createProperty(NS, NULL);
+ /*
+ * Namespace of YAML vocabulary
+ */
+ public static final String NS = "http://yaml.org/spec/1.2/spec.html#";
+
+ public static final String PREFIX = "yaml";
+
+ public static final String ROOT = "Root";
+
+ public static final String DOCUMENT = "Document";
+
+ public static final String NODE = "Node";
+
+ public static final String SEQUENCE = "Sequence";
+
+ public static final String MAPPING = "Mapping";
+
+ public static final String CONTAINS = "contains";
+
+ public static final String NULL = "Null";
+
+ private static final YAML _instance = new YAML();
+
+ private YAML() {
+ super(NS);
+ }
+
+ public static YAML getInstance() {
+ return _instance;
}
+
+ // Resources
+ /**
+ * <p>
+ * The root node. Representation of the YAML file. NB: one file may contain more than one documents represented by
+ * nodes; e.g.
+ * </p>
+ * <p>
+ * <code>
+ * %YAML 1.2
+ * ---
+ * - data1
+ * - data2
+ * ---
+ * - data3
+ * </code>
+ * </p>
+ * Contains two documents.
+ */
+ public final IRI root = createClass(NS, ROOT);
+
+ public final IRI document = createClass(NS, DOCUMENT);
+
+ public final IRI node = createClass(NS, NODE);
+
+ public final IRI sequence = createClass(NS, SEQUENCE);
+
+ public final IRI mapping = createClass(NS, MAPPING);
+ // property
+ public final IRI contains = createProperty(NS, CONTAINS);
+
+ public final IRI nullValue = createProperty(NS, NULL);
+}
diff --git a/api/src/main/java/org/apache/any23/writer/DecoratingWriterFactory.java b/api/src/main/java/org/apache/any23/writer/DecoratingWriterFactory.java
index cc66372..f3be0f9 100644
--- a/api/src/main/java/org/apache/any23/writer/DecoratingWriterFactory.java
+++ b/api/src/main/java/org/apache/any23/writer/DecoratingWriterFactory.java
@@ -21,6 +21,7 @@ import org.apache.any23.configuration.Settings;
/**
* Base interface used for constructors of decorating {@link TripleHandler} implementations.
+ *
* @author Hans Brende (hansbrende@apache.org)
*/
public interface DecoratingWriterFactory extends BaseWriterFactory<TripleHandler> {
@@ -33,11 +34,17 @@ public interface DecoratingWriterFactory extends BaseWriterFactory<TripleHandler
Settings getSupportedSettings();
/**
- * @param delegate the {@link TripleWriter} to delegate input to
- * @param settings the settings with which to configure the returned handler
+ * @param delegate
+ * the {@link TripleWriter} to delegate input to
+ * @param settings
+ * the settings with which to configure the returned handler
+ *
* @return a {@link TripleHandler} which writes to the specified delegate
- * @throws NullPointerException if the delegate or settings is null
- * @throws IllegalArgumentException if the settings are not correctly configured
+ *
+ * @throws NullPointerException
+ * if the delegate or settings is null
+ * @throws IllegalArgumentException
+ * if the settings are not correctly configured
*/
@Override
TripleHandler getTripleWriter(TripleHandler delegate, Settings settings);
diff --git a/api/src/main/java/org/apache/any23/writer/FormatWriter.java b/api/src/main/java/org/apache/any23/writer/FormatWriter.java
index 812959d..510047e 100644
--- a/api/src/main/java/org/apache/any23/writer/FormatWriter.java
+++ b/api/src/main/java/org/apache/any23/writer/FormatWriter.java
@@ -23,19 +23,20 @@ package org.apache.any23.writer;
public interface FormatWriter extends TripleHandler {
/**
- * If <code>true</code> then the produced <b>RDF</b> is annotated with
- * the extractors used to generate the specific statements.
+ * If <code>true</code> then the produced <b>RDF</b> is annotated with the extractors used to generate the specific
+ * statements.
*
* @return the annotation flag value.
*/
- boolean isAnnotated();
+ boolean isAnnotated();
/**
* Sets the <i>annotation</i> flag.
*
- * @param f If <code>true</code> then the produced <b>RDF</b> is annotated with
- * the extractors used to generate the specific statements.
+ * @param f
+ * If <code>true</code> then the produced <b>RDF</b> is annotated with the extractors used to generate
+ * the specific statements.
*/
- void setAnnotated(boolean f);
+ void setAnnotated(boolean f);
}
diff --git a/api/src/main/java/org/apache/any23/writer/TripleFormat.java b/api/src/main/java/org/apache/any23/writer/TripleFormat.java
index 01292eb..f80efb4 100644
--- a/api/src/main/java/org/apache/any23/writer/TripleFormat.java
+++ b/api/src/main/java/org/apache/any23/writer/TripleFormat.java
@@ -70,7 +70,7 @@ public class TripleFormat {
return new Capabilities(raw | WRITES_NAMESPACES);
}
- //TODO: add "supportsComments()"
+ // TODO: add "supportsComments()"
}
private static IllegalArgumentException mimeTypeErr(String mt) {
@@ -88,7 +88,7 @@ public class TripleFormat {
return object;
}
- //see https://tools.ietf.org/html/rfc2045#section-5.1
+ // see https://tools.ietf.org/html/rfc2045#section-5.1
private static void checkMimeTypes(List<String> mts) {
if (checkNonNull(mts, "mimetypes").isEmpty()) {
throw new IllegalArgumentException("mimetypes must not be empty");
@@ -97,11 +97,10 @@ public class TripleFormat {
boolean slash = false;
for (int i = 0, len = checkNonNull(mt, "mimetype").length(); i < len; i++) {
char ch = mt.charAt(i);
- if (ch <= ' ' || ch >= 127 || ch == '(' || ch == ')' ||
- ch == '<' || ch == '>' || ch == '@' || ch == ',' ||
- ch == ';' || ch == ':' || ch == '\\' || ch == '"' ||
- ch == '[' || ch == ']' || ch == '?' || ch == '='
- //also disallow wildcards:
+ if (ch <= ' ' || ch >= 127 || ch == '(' || ch == ')' || ch == '<' || ch == '>' || ch == '@' || ch == ','
+ || ch == ';' || ch == ':' || ch == '\\' || ch == '"' || ch == '[' || ch == ']' || ch == '?'
+ || ch == '='
+ // also disallow wildcards:
|| ch == '*') {
throw mimeTypeErr(mt);
} else if (ch == '/') {
@@ -122,9 +121,8 @@ public class TripleFormat {
int illegalDot = 0;
for (int i = 0, len = checkNonNull(ext, "extension").length(); i < len; i++) {
char ch = ext.charAt(i);
- if (ch <= ' ' || ch >= 127 || ch == '<' || ch == '>' ||
- ch == ':' || ch == '"' || ch == '/' || ch == '\\' ||
- ch == '|' || ch == '?' || ch == '*') {
+ if (ch <= ' ' || ch >= 127 || ch == '<' || ch == '>' || ch == ':' || ch == '"' || ch == '/'
+ || ch == '\\' || ch == '|' || ch == '?' || ch == '*') {
throw extensionErr(ext);
} else if (ch == '.') {
int next = i + 1;
@@ -145,22 +143,22 @@ public class TripleFormat {
return ext.toLowerCase(Locale.ENGLISH);
}
- private TripleFormat(String name, Collection<String> mimeTypes, Charset charset,
- Collection<String> fileExtensions, String standardIRI, Capabilities capabilities) {
+ private TripleFormat(String name, Collection<String> mimeTypes, Charset charset, Collection<String> fileExtensions,
+ String standardIRI, Capabilities capabilities) {
this.name = checkNonNull(name, "display name");
- checkMimeTypes(this.mimeTypes = Collections.unmodifiableList(mimeTypes.stream()
- .map(TripleFormat::normalizeMimeType).distinct().collect(Collectors.toList())));
+ checkMimeTypes(this.mimeTypes = Collections.unmodifiableList(
+ mimeTypes.stream().map(TripleFormat::normalizeMimeType).distinct().collect(Collectors.toList())));
if ((this.charset = charset) != null && !charset.canEncode()) {
throw new IllegalArgumentException(charset + " does not allow encoding");
}
- checkExtensions(this.fileExtensions = Collections.unmodifiableList(fileExtensions.stream()
- .map(TripleFormat::normalizeExtension).distinct().collect(Collectors.toList())));
+ checkExtensions(this.fileExtensions = Collections.unmodifiableList(
+ fileExtensions.stream().map(TripleFormat::normalizeExtension).distinct().collect(Collectors.toList())));
this.standardIRI = standardIRI == null ? null : vf.createIRI(standardIRI);
this.capabilities = checkNonNull(capabilities, "capabilities");
}
public static TripleFormat of(String displayName, Collection<String> mimeTypes, Charset defaultCharset,
- Collection<String> fileExtensions, String standardIRI, Capabilities capabilities) {
+ Collection<String> fileExtensions, String standardIRI, Capabilities capabilities) {
return new TripleFormat(displayName, mimeTypes, defaultCharset, fileExtensions, standardIRI, capabilities);
}
@@ -181,9 +179,8 @@ public class TripleFormat {
}
static TripleFormat of(RDFFormat format) {
- TripleFormat f = of(format.getName(), format.getMIMETypes(),
- format.getCharset(), format.getFileExtensions(), iri(format.getStandardURI()),
- capabilities(format));
+ TripleFormat f = of(format.getName(), format.getMIMETypes(), format.getCharset(), format.getFileExtensions(),
+ iri(format.getStandardURI()), capabilities(format));
f.rdfFormat = format;
return f;
}
@@ -230,10 +227,8 @@ public class TripleFormat {
}
public String toString() {
- return name + mimeTypes.stream().collect(
- Collectors.joining(", ", " (mimeTypes=", "; "))
- + fileExtensions.stream().collect(
- Collectors.joining(", ", "ext=", ")"));
+ return name + mimeTypes.stream().collect(Collectors.joining(", ", " (mimeTypes=", "; "))
+ + fileExtensions.stream().collect(Collectors.joining(", ", "ext=", ")"));
}
}
diff --git a/api/src/main/java/org/apache/any23/writer/TripleHandler.java b/api/src/main/java/org/apache/any23/writer/TripleHandler.java
index e74436f..b3b75cf 100644
--- a/api/src/main/java/org/apache/any23/writer/TripleHandler.java
+++ b/api/src/main/java/org/apache/any23/writer/TripleHandler.java
@@ -30,72 +30,88 @@ public interface TripleHandler extends AutoCloseable {
void startDocument(IRI documentIRI) throws TripleHandlerException;
/**
- * Informs the handler that a new context has been established.
- * Contexts are not guaranteed to receive any triples, so they
- * might be closed without any triple.
- * @param context an instantiated {@link org.apache.any23.extractor.ExtractionContext}
- * @throws TripleHandlerException if there is an errr opening the
- * {@link org.apache.any23.extractor.ExtractionContext}
+ * Informs the handler that a new context has been established. Contexts are not guaranteed to receive any triples,
+ * so they might be closed without any triple.
+ *
+ * @param context
+ * an instantiated {@link org.apache.any23.extractor.ExtractionContext}
+ *
+ * @throws TripleHandlerException
+ * if there is an errr opening the {@link org.apache.any23.extractor.ExtractionContext}
*/
void openContext(ExtractionContext context) throws TripleHandlerException;
/**
- * Invoked with a currently open context,
- * notifies the detection of a triple.
+ * Invoked with a currently open context, notifies the detection of a triple.
*
- * @param s triple subject, cannot be <code>null</code>.
- * @param p triple predicate, cannot be <code>null</code>.
- * @param o triple object, cannot be <code>null</code>.
- * @param g triple graph, can be <code>null</code>.
- * @param context extraction context.
- * @throws TripleHandlerException if there is an error receiving the triple.
+ * @param s
+ * triple subject, cannot be <code>null</code>.
+ * @param p
+ * triple predicate, cannot be <code>null</code>.
+ * @param o
+ * triple object, cannot be <code>null</code>.
+ * @param g
+ * triple graph, can be <code>null</code>.
+ * @param context
+ * extraction context.
+ *
+ * @throws TripleHandlerException
+ * if there is an error receiving the triple.
*/
void receiveTriple(Resource s, IRI p, Value o, IRI g, ExtractionContext context) throws TripleHandlerException;
/**
- * Invoked with a currently open context, notifies the detection of a
- * namespace.
+ * Invoked with a currently open context, notifies the detection of a namespace.
*
- * @param prefix namespace prefix.
- * @param uri namespace <i>IRI</i>.
- * @param context namespace context.
- * @throws TripleHandlerException if there is an error receiving the namespace.
+ * @param prefix
+ * namespace prefix.
+ * @param uri
+ * namespace <i>IRI</i>.
+ * @param context
+ * namespace context.
+ *
+ * @throws TripleHandlerException
+ * if there is an error receiving the namespace.
*/
void receiveNamespace(String prefix, String uri, ExtractionContext context) throws TripleHandlerException;
/**
- * Informs the handler that no more triples will come from a
- * previously opened context. All contexts are guaranteed to
- * be closed before the final close(). The document context
- * for each document is guaranteed to be closed after all
- * local contexts of that document.
+ * Informs the handler that no more triples will come from a previously opened context. All contexts are guaranteed
+ * to be closed before the final close(). The document context for each document is guaranteed to be closed after
+ * all local contexts of that document.
*
- * @param context the context to be closed.
- * @throws TripleHandlerException if there is an error closing the
- * {@link org.apache.any23.extractor.ExtractionContext}.
+ * @param context
+ * the context to be closed.
+ *
+ * @throws TripleHandlerException
+ * if there is an error closing the {@link org.apache.any23.extractor.ExtractionContext}.
*/
void closeContext(ExtractionContext context) throws TripleHandlerException;
/**
- * Informs the handler that the end of the document
- * has been reached.
+ * Informs the handler that the end of the document has been reached.
*
- * @param documentIRI document IRI.
- * @throws TripleHandlerException if there is an error ending the document.
+ * @param documentIRI
+ * document IRI.
+ *
+ * @throws TripleHandlerException
+ * if there is an error ending the document.
*/
void endDocument(IRI documentIRI) throws TripleHandlerException;
/**
* Sets the length of the content to be processed.
*
- * @param contentLength length of the content being processed.
+ * @param contentLength
+ * length of the content being processed.
*/
void setContentLength(long contentLength);
/**
* Will be called last and exactly once.
- * @throws TripleHandlerException if there is an error closing the
- * {@link org.apache.any23.writer.TripleHandler} implementation.
+ *
+ * @throws TripleHandlerException
+ * if there is an error closing the {@link org.apache.any23.writer.TripleHandler} implementation.
*/
void close() throws TripleHandlerException;
diff --git a/api/src/main/java/org/apache/any23/writer/TripleHandlerException.java b/api/src/main/java/org/apache/any23/writer/TripleHandlerException.java
index 8537091..48bc718 100644
--- a/api/src/main/java/org/apache/any23/writer/TripleHandlerException.java
+++ b/api/src/main/java/org/apache/any23/writer/TripleHandlerException.java
@@ -28,7 +28,6 @@ public class TripleHandlerException extends Exception {
super(s);
}
-
public TripleHandlerException(String s, Exception exception) {
super(s, exception);
}
diff --git a/api/src/main/java/org/apache/any23/writer/TripleWriter.java b/api/src/main/java/org/apache/any23/writer/TripleWriter.java
index 3800045..fbc27d9 100644
--- a/api/src/main/java/org/apache/any23/writer/TripleWriter.java
+++ b/api/src/main/java/org/apache/any23/writer/TripleWriter.java
@@ -30,29 +30,43 @@ public interface TripleWriter extends AutoCloseable {
/**
* Writes a triple and, optionally, a graph resource name.
- * @param s the subject to write
- * @param p the predicate to write
- * @param o the object to write
- * @param g the graph name to write, or null
- * @throws TripleHandlerException if there is an error writing the triple
+ *
+ * @param s
+ * the subject to write
+ * @param p
+ * the predicate to write
+ * @param o
+ * the object to write
+ * @param g
+ * the graph name to write, or null
+ *
+ * @throws TripleHandlerException
+ * if there is an error writing the triple
*/
void writeTriple(Resource s, IRI p, Value o, Resource g) throws TripleHandlerException;
/**
- * Writes a prefix-namespace mapping. <br><b>NOTE:</b> this method should be called
- * <b>before</b> writing out any triples. Calling this method <b>after</b> writing
- * out a triple may result in the prefix-namespace mapping being ignored.
- * @param prefix the namespace prefix
- * @param uri the namespace uri
- * @throws TripleHandlerException if there was an error writing out the prefix-namespace mapping
+ * Writes a prefix-namespace mapping. <br>
+ * <b>NOTE:</b> this method should be called <b>before</b> writing out any triples. Calling this method <b>after</b>
+ * writing out a triple may result in the prefix-namespace mapping being ignored.
+ *
+ * @param prefix
+ * the namespace prefix
+ * @param uri
+ * the namespace uri
+ *
+ * @throws TripleHandlerException
+ * if there was an error writing out the prefix-namespace mapping
*/
void writeNamespace(String prefix, String uri) throws TripleHandlerException;
/**
- * Releases resources associated with this {@link TripleWriter}, and flushes (but by default does not close)
- * any underlying {@link java.io.OutputStream}s. Future invocations of methods of this writer
- * produce <b>undefined behavior</b> after this method has been called.
- * @throws TripleHandlerException if there was an error closing this {@link TripleWriter}
+ * Releases resources associated with this {@link TripleWriter}, and flushes (but by default does not close) any
+ * underlying {@link java.io.OutputStream}s. Future invocations of methods of this writer produce <b>undefined
+ * behavior</b> after this method has been called.
+ *
+ * @throws TripleHandlerException
+ * if there was an error closing this {@link TripleWriter}
*/
@Override
void close() throws TripleHandlerException;
diff --git a/api/src/main/java/org/apache/any23/writer/TripleWriterFactory.java b/api/src/main/java/org/apache/any23/writer/TripleWriterFactory.java
index 20d4995..d4eae83 100644
--- a/api/src/main/java/org/apache/any23/writer/TripleWriterFactory.java
+++ b/api/src/main/java/org/apache/any23/writer/TripleWriterFactory.java
@@ -28,8 +28,9 @@ import org.eclipse.rdf4j.rio.RDFFormat;
import java.io.OutputStream;
/**
- * Base interface for constructors of {@link TripleHandler} implementations
- * that write to an {@link OutputStream} using a particular {@link FileFormat}.
+ * Base interface for constructors of {@link TripleHandler} implementations that write to an {@link OutputStream} using
+ * a particular {@link FileFormat}.
+ *
* @author Hans Brende (hansbrende@apache.org)
*/
public interface TripleWriterFactory extends BaseWriterFactory<OutputStream> {
@@ -64,41 +65,53 @@ public interface TripleWriterFactory extends BaseWriterFactory<OutputStream> {
@Deprecated
default FormatWriter getRdfWriter(OutputStream os) {
TripleHandler th = getTripleWriter(os, Settings.of());
- return th instanceof FormatWriter ? (FormatWriter)th : new FormatWriter() {
+ return th instanceof FormatWriter ? (FormatWriter) th : new FormatWriter() {
@Override
public boolean isAnnotated() {
return false;
}
+
@Override
- public void setAnnotated(boolean f) {}
+ public void setAnnotated(boolean f) {
+ }
+
@Override
public void startDocument(IRI documentIRI) throws TripleHandlerException {
th.startDocument(documentIRI);
}
+
@Override
public void openContext(ExtractionContext context) throws TripleHandlerException {
th.openContext(context);
}
+
@Override
- public void receiveTriple(Resource s, IRI p, Value o, IRI g, ExtractionContext context) throws TripleHandlerException {
+ public void receiveTriple(Resource s, IRI p, Value o, IRI g, ExtractionContext context)
+ throws TripleHandlerException {
th.receiveTriple(s, p, o, g, context);
}
+
@Override
- public void receiveNamespace(String prefix, String uri, ExtractionContext context) throws TripleHandlerException {
+ public void receiveNamespace(String prefix, String uri, ExtractionContext context)
+ throws TripleHandlerException {
th.receiveNamespace(prefix, uri, context);
}
+
@Override
public void closeContext(ExtractionContext context) throws TripleHandlerException {
th.closeContext(context);
}
+
@Override
public void endDocument(IRI documentIRI) throws TripleHandlerException {
th.endDocument(documentIRI);
}
+
@Override
public void setContentLength(long contentLength) {
th.setContentLength(contentLength);
}
+
@Override
public void close() throws TripleHandlerException {
th.close();
@@ -106,7 +119,6 @@ public interface TripleWriterFactory extends BaseWriterFactory<OutputStream> {
};
}
-
/**
*
* @return the settings supported by writers produced by this factory
@@ -114,13 +126,18 @@ public interface TripleWriterFactory extends BaseWriterFactory<OutputStream> {
@Override
Settings getSupportedSettings();
-
/**
- * @param out the {@link OutputStream} to write to
- * @param settings the settings with which to configure the writer
+ * @param out
+ * the {@link OutputStream} to write to
+ * @param settings
+ * the settings with which to configure the writer
+ *
* @return a {@link TripleHandler} which writes to the specified {@link OutputStream}
- * @throws NullPointerException if the output stream or settings is null
- * @throws IllegalArgumentException if the settings are not correctly configured
+ *
+ * @throws NullPointerException
+ * if the output stream or settings is null
+ * @throws IllegalArgumentException
+ * if the settings are not correctly configured
*/
@Override
TripleHandler getTripleWriter(OutputStream out, Settings settings);
diff --git a/api/src/main/java/org/apache/any23/writer/WriterFactory.java b/api/src/main/java/org/apache/any23/writer/WriterFactory.java
index 353ba11..995a0b6 100644
--- a/api/src/main/java/org/apache/any23/writer/WriterFactory.java
+++ b/api/src/main/java/org/apache/any23/writer/WriterFactory.java
@@ -23,8 +23,9 @@ import org.apache.any23.configuration.Settings;
import org.eclipse.rdf4j.rio.RDFFormat;
/**
- * The superinterface of all {@link TripleHandler} factory interfaces.
- * Do not implement this interface directly. Instead, implement one of the subinterfaces {@link TripleWriterFactory} or {@link DecoratingWriterFactory}.
+ * The superinterface of all {@link TripleHandler} factory interfaces. Do not implement this interface directly.
+ * Instead, implement one of the subinterfaces {@link TripleWriterFactory} or {@link DecoratingWriterFactory}.
+ *
* @author Peter Ansell (p_ansell@yahoo.com)
* @author Hans Brende (hansbrende@apache.org)
*/
@@ -32,6 +33,7 @@ public interface WriterFactory {
/**
* @deprecated since 2.3. Use {@link TripleWriterFactory#getTripleFormat()} instead.
+ *
* @return the {@link org.eclipse.rdf4j.rio.RDFFormat} being handled
*/
@Deprecated
@@ -40,7 +42,9 @@ public interface WriterFactory {
String getIdentifier();
/**
- * @deprecated since 2.3. Use {@link TripleWriterFactory#getTripleFormat()}.{@link TripleFormat#getMimeType() getMimeType()} instead.
+ * @deprecated since 2.3. Use {@link TripleWriterFactory#getTripleFormat()}.{@link TripleFormat#getMimeType()
+ * getMimeType()} instead.
+ *
* @return a String representing the Mimetype being handled in this Writer
*/
@Deprecated
@@ -48,8 +52,11 @@ public interface WriterFactory {
/**
* @deprecated since 2.3. Use {@link TripleWriterFactory#getTripleWriter(OutputStream, Settings)} instead.
- * @param os a {@link java.io.OutputStream} to be written to the FormatWriter handler
- * @return a {@link org.apache.any23.writer.FormatWriter} ready to be implemented
+ *
+ * @param os
+ * a {@link java.io.OutputStream} to be written to the FormatWriter handler
+ *
+ * @return a {@link org.apache.any23.writer.FormatWriter} ready to be implemented
*/
@Deprecated
FormatWriter getRdfWriter(OutputStream os);
diff --git a/api/src/main/java/org/apache/any23/writer/WriterFactoryRegistry.java b/api/src/main/java/org/apache/any23/writer/WriterFactoryRegistry.java
index 64830d8..f8cb7ea 100644
--- a/api/src/main/java/org/apache/any23/writer/WriterFactoryRegistry.java
+++ b/api/src/main/java/org/apache/any23/writer/WriterFactoryRegistry.java
@@ -46,7 +46,7 @@ import org.slf4j.LoggerFactory;
public class WriterFactoryRegistry {
private static final Logger LOG = LoggerFactory.getLogger(WriterFactoryRegistry.class);
-
+
/**
* Singleton instance.
*/
@@ -76,11 +76,13 @@ public class WriterFactoryRegistry {
private final Collection<String> mimeTypes = new CopyOnWriteArraySet<>();
public WriterFactoryRegistry() {
- ServiceLoader<WriterFactory> serviceLoader = java.util.ServiceLoader.load(WriterFactory.class, this.getClass().getClassLoader());
+ ServiceLoader<WriterFactory> serviceLoader = java.util.ServiceLoader.load(WriterFactory.class,
+ this.getClass().getClassLoader());
Iterator<WriterFactory> iterator = serviceLoader.iterator();
-
- // use while(true) loop so that we can isolate all service loader errors from .next and .hasNext to a single service
+
+ // use while(true) loop so that we can isolate all service loader errors from .next and .hasNext to a single
+ // service
ArrayList<WriterFactory> factories = new ArrayList<>();
while (true) {
@@ -88,18 +90,20 @@ public class WriterFactoryRegistry {
if (!iterator.hasNext())
break;
factories.add(iterator.next());
- } catch(ServiceConfigurationError error) {
+ } catch (ServiceConfigurationError error) {
LOG.error("Found error loading a WriterFactory", error);
}
}
registerAll(factories.toArray(EMPTY_WRITERS));
}
-
+
/**
* Reads the identifier specified for the given {@link WriterFactory}.
*
- * @param writerClass writer class.
+ * @param writerClass
+ * writer class.
+ *
* @return identifier.
*/
public static String getIdentifier(WriterFactory writerClass) {
@@ -109,12 +113,14 @@ public class WriterFactoryRegistry {
/**
* Reads the <i>MIME Type</i> specified for the given {@link WriterFactory}.
*
- * @param writerClass writer class.
+ * @param writerClass
+ * writer class.
+ *
* @return MIME type.
*/
public static String getMimeType(WriterFactory writerClass) {
if (writerClass instanceof TripleWriterFactory) {
- return ((TripleWriterFactory)writerClass).getTripleFormat().getMimeType();
+ return ((TripleWriterFactory) writerClass).getTripleFormat().getMimeType();
} else if (writerClass instanceof DecoratingWriterFactory) {
return null;
} else {
@@ -131,19 +137,20 @@ public class WriterFactoryRegistry {
@SuppressWarnings("deprecation")
private static TripleFormat reportAndGetCompatFormat(WriterFactory f) {
- LOG.warn("{} must implement either {} or {}.", f.getClass(), TripleWriterFactory.class, DecoratingWriterFactory.class);
+ LOG.warn("{} must implement either {} or {}.", f.getClass(), TripleWriterFactory.class,
+ DecoratingWriterFactory.class);
final String mimeType = f.getMimeType();
RDFFormat fmt;
try {
fmt = f.getRdfFormat();
} catch (RuntimeException e) {
- return TripleFormat.of(mimeType, Collections.singleton(mimeType), null,
- Collections.emptySet(), null, TripleFormat.NONSTANDARD);
+ return TripleFormat.of(mimeType, Collections.singleton(mimeType), null, Collections.emptySet(), null,
+ TripleFormat.NONSTANDARD);
}
if (mimeType == null || fmt.hasDefaultMIMEType(mimeType)) {
return TripleFormat.of(fmt);
}
- //override default MIME type on mismatch
+ // override default MIME type on mismatch
return TripleFormat.of(fmt.getName(), Collections.singleton(mimeType), fmt.getCharset(),
fmt.getFileExtensions(), fmt.getStandardURI().stringValue(), TripleFormat.capabilities(fmt));
}
@@ -177,14 +184,16 @@ public class WriterFactoryRegistry {
/**
* Registers a new {@link WriterFactory} to the registry.
*
- * @param f the writer factory to be registered.
- * @throws IllegalArgumentException if the id or the mimetype are null
- * or empty strings or if the identifier has been already defined.
+ * @param f
+ * the writer factory to be registered.
+ *
+ * @throws IllegalArgumentException
+ * if the id or the mimetype are null or empty strings or if the identifier has been already defined.
*/
public void register(WriterFactory f) {
if (f == null)
throw new NullPointerException("writerClass cannot be null.");
- registerAll(new WriterFactory[]{f});
+ registerAll(new WriterFactory[] { f });
}
private void registerAll(WriterFactory[] factories) {
@@ -198,7 +207,7 @@ public class WriterFactoryRegistry {
for (int i = 0; i < count; i++) {
WriterFactory f = factories[i];
if (!(f instanceof BaseWriterFactory<?>)) {
- //backwards compatibility: view vanilla WriterFactory as TripleWriterFactory
+ // backwards compatibility: view vanilla WriterFactory as TripleWriterFactory
f = factories[i] = getCompatFactory(f);
}
final String id = ids[i] = f.getIdentifier();
@@ -206,7 +215,7 @@ public class WriterFactoryRegistry {
throw new IllegalArgumentException("Invalid identifier returned by writer " + f);
}
if (f instanceof TripleWriterFactory) {
- String mimeType = ((TripleWriterFactory)f).getTripleFormat().getMimeType();
+ String mimeType = ((TripleWriterFactory) f).getTripleFormat().getMimeType();
if (mimeType == null || mimeType.trim().isEmpty()) {
throw new IllegalArgumentException("Invalid MIME type returned by writer " + f);
}
@@ -226,7 +235,7 @@ public class WriterFactoryRegistry {
}
}
}
- //add in bulk to reduce writes to CopyOnWriteArrayList
+ // add in bulk to reduce writes to CopyOnWriteArrayList
writers.addAll(factoryList);
identifiers.addAll(idList);
for (Map.Entry<String, ArrayList<WriterFactory>> entry : mimes.entrySet()) {
@@ -239,7 +248,9 @@ public class WriterFactoryRegistry {
/**
* Verifies if a {@link WriterFactory} with given <code>id</code> identifier has been registered.
*
- * @param id identifier.
+ * @param id
+ * identifier.
+ *
* @return <code>true</code> if the identifier has been registered, <code>false</code> otherwise.
*/
public boolean hasIdentifier(String id) {
@@ -252,7 +263,7 @@ public class WriterFactoryRegistry {
* @return the list of all the specified identifiers.
*/
public List<String> getIdentifiers() {
- //no synchronized block needed for CopyOnWriteArrayList
+ // no synchronized block needed for CopyOnWriteArrayList
return Collections.unmodifiableList(identifiers);
}
@@ -260,7 +271,7 @@ public class WriterFactoryRegistry {
* @return the list of MIME types covered by the registered {@link WriterFactory} instances.
*/
public Collection<String> getMimeTypes() {
- //no synchronized block needed for CopyOnWriteArraySet
+ // no synchronized block needed for CopyOnWriteArraySet
return Collections.unmodifiableCollection(mimeTypes);
}
@@ -268,16 +279,17 @@ public class WriterFactoryRegistry {
* @return the list of all the registered {@link WriterFactory} instances.
*/
public List<WriterFactory> getWriters() {
- //no synchronized block needed for CopyOnWriteArrayList
+ // no synchronized block needed for CopyOnWriteArrayList
return Collections.unmodifiableList(writers);
}
/**
* Returns the {@link WriterFactory} identified by <code>id</code>.
*
- * @param id the writer identifier.
- * @return the {@link WriterFactory} matching the <code>id</code>
- * or <code>null</code> if not found.
+ * @param id
+ * the writer identifier.
+ *
+ * @return the {@link WriterFactory} matching the <code>id</code> or <code>null</code> if not found.
*/
public WriterFactory getWriterByIdentifier(String id) {
synchronized (idToWriter) {
@@ -288,32 +300,37 @@ public class WriterFactoryRegistry {
/**
* Returns all the writers matching the specified <code>mimeType</code>.
*
- * @param mimeType a MIMEType.
+ * @param mimeType
+ * a MIMEType.
+ *
* @return a list of matching writers or an empty list.
*/
public Collection<WriterFactory> getWritersByMimeType(String mimeType) {
- //no synchronized block needed for synchronized map
- //return CopyOnWriteArrayList to avoid ConcurrentModificationExceptions on iteration
+ // no synchronized block needed for synchronized map
+ // return CopyOnWriteArrayList to avoid ConcurrentModificationExceptions on iteration
List<WriterFactory> list = mimeToWriter.get(mimeType);
return list != null ? Collections.unmodifiableList(list) : Collections.emptyList();
}
/**
- * Returns an instance of {@link FormatWriter} ready to write on the given
- * {@link OutputStream}.
+ * Returns an instance of {@link FormatWriter} ready to write on the given {@link OutputStream}.
*
- * @param id the identifier of the {@link FormatWriter} to instantiate.
- * @param os the output stream.
+ * @param id
+ * the identifier of the {@link FormatWriter} to instantiate.
+ * @param os
+ * the output stream.
+ *
* @return the not <code>null</code> {@link FormatWriter} instance.
- * @throws NullPointerException if the <code>id</code> doesn't match any registered writer.
+ *
+ * @throws NullPointerException
+ * if the <code>id</code> doesn't match any registered writer.
*
- * @deprecated since 2.3. Use {@link #getWriterByIdentifier(String)}
- * in combination with {@link TripleWriterFactory#getTripleWriter(OutputStream, Settings)} instead.
+ * @deprecated since 2.3. Use {@link #getWriterByIdentifier(String)} in combination with
+ * {@link TripleWriterFactory#getTripleWriter(OutputStream, Settings)} instead.
*/
@Deprecated
public FormatWriter getWriterInstanceByIdentifier(String id, OutputStream os) {
- return Objects.requireNonNull(getWriterByIdentifier(id),
- "Cannot find writer with id " + id).getRdfWriter(os);
+ return Objects.requireNonNull(getWriterByIdentifier(id), "Cannot find writer with id " + id).getRdfWriter(os);
}
}
diff --git a/api/src/test/java/org/apache/any23/configuration/SettingsTest.java b/api/src/test/java/org/apache/any23/configuration/SettingsTest.java
index 80aef91..36f22a4 100644
--- a/api/src/test/java/org/apache/any23/configuration/SettingsTest.java
+++ b/api/src/test/java/org/apache/any23/configuration/SettingsTest.java
@@ -44,13 +44,13 @@ public class SettingsTest {
nonNull.withValue(null);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
}
@Test
public void testNullableSetting() {
- Setting<String> nullable = Setting.create("nulltest", (String)null);
+ Setting<String> nullable = Setting.create("nulltest", (String) null);
assertNull(nullable.withValue(null).getValue());
}
@@ -64,7 +64,7 @@ public class SettingsTest {
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
}
@@ -107,21 +107,23 @@ public class SettingsTest {
@Test
public void testGetNullSetting() {
- Setting<String> baseKey = Setting.create("foo", (String)null);
+ Setting<String> baseKey = Setting.create("foo", (String) null);
Settings settings = Settings.of(baseKey);
assertNull(settings.get(baseKey.withValue("not null")));
- //make sure we can go back to null
+ // make sure we can go back to null
baseKey.withValue("not null").withValue(null);
}
@Test
public void testSettingType() {
assertEquals(CharSequence.class, Setting.create("foo", CharSequence.class, "").getValueType());
- assertEquals(CharSequence.class, new Setting<CharSequence>("foo", ""){}.getValueType());
+ assertEquals(CharSequence.class, new Setting<CharSequence>("foo", "") {
+ }.getValueType());
- Type mapType = new Setting<Map<String, Integer>>("foo", Collections.emptyMap()){}.getValueType();
+ Type mapType = new Setting<Map<String, Integer>>("foo", Collections.emptyMap()) {
+ }.getValueType();
assertTrue(mapType instanceof ParameterizedType);
assertEquals("java.util.Map<java.lang.String, java.lang.Integer>", mapType.getTypeName());
@@ -132,20 +134,25 @@ public class SettingsTest {
}
}
- class Key2<Baz, V, Bar> extends Key0<V, Bar> { }
+ class Key2<Baz, V, Bar> extends Key0<V, Bar> {
+ }
- class Key3<V> extends Key2<Boolean, Integer, List<Optional<String>>> { }
+ class Key3<V> extends Key2<Boolean, Integer, List<Optional<String>>> {
+ }
- class Key4 extends Key3<Boolean> { }
+ class Key4 extends Key3<Boolean> {
+ }
Type complicatedType = new Key4().withValue(Collections.emptyList()).getValueType();
assertTrue(complicatedType instanceof ParameterizedType);
assertEquals("java.util.List<java.util.Optional<java.lang.String>>", complicatedType.getTypeName());
- class Key3Simple<V> extends Key2<Boolean, Integer, String> { }
+ class Key3Simple<V> extends Key2<Boolean, Integer, String> {
+ }
- class Key4Simple extends Key3Simple<Boolean> { }
+ class Key4Simple extends Key3Simple<Boolean> {
+ }
Type simpleType = new Key4Simple().withValue("").getValueType();
@@ -194,78 +201,84 @@ public class SettingsTest {
@SuppressWarnings("unchecked")
public void testBadSetting() {
try {
- new Setting("foo", null) {};
+ new Setting("foo", null) {
+ };
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
- new Setting<Integer>(null, null) {};
+ new Setting<Integer>(null, null) {
+ };
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
Setting.create(null, 0);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
- new Setting<Integer>(" ", null) {};
+ new Setting<Integer>(" ", null) {
+ };
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
Setting.create(" ", 0);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
Setting.create("foo", List.class, null);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
Setting.create("foo", boolean.class, null);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
Setting.create("foo", Integer[].class, null);
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
- new Setting<Integer[]>("foo", null) {};
+ new Setting<Integer[]>("foo", null) {
+ };
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
try {
- new Setting<List<Integer>[]>("foo", null) {};
+ new Setting<List<Integer>[]>("foo", null) {
+ };
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
class BadKeyCreator {
private <V> void badKey() {
- new Setting<V>("foo", null) {};
+ new Setting<V>("foo", null) {
+ };
}
}
@@ -273,9 +286,8 @@ public class SettingsTest {
new BadKeyCreator().badKey();
fail();
} catch (IllegalArgumentException e) {
- //test passes; ignore
+ // test passes; ignore
}
}
-
}
diff --git a/api/src/test/java/org/apache/any23/writer/TripleFormatTest.java b/api/src/test/java/org/apache/any23/writer/TripleFormatTest.java
index f91202c..d02a30a 100644
--- a/api/src/test/java/org/apache/any23/writer/TripleFormatTest.java
+++ b/api/src/test/java/org/apache/any23/writer/TripleFormatTest.java
@@ -29,11 +29,9 @@ public class TripleFormatTest {
@Test
public void testRdf4jRoundTripping() {
- RDFFormat[] formats = {
- RDFFormat.TRIX, RDFFormat.NQUADS, RDFFormat.RDFA, RDFFormat.TRIG,
- RDFFormat.N3, RDFFormat.RDFXML, RDFFormat.TURTLE, RDFFormat.JSONLD,
- RDFFormat.NTRIPLES, RDFFormat.BINARY, RDFFormat.RDFJSON
- };
+ RDFFormat[] formats = { RDFFormat.TRIX, RDFFormat.NQUADS, RDFFormat.RDFA, RDFFormat.TRIG, RDFFormat.N3,
+ RDFFormat.RDFXML, RDFFormat.TURTLE, RDFFormat.JSONLD, RDFFormat.NTRIPLES, RDFFormat.BINARY,
+ RDFFormat.RDFJSON };
for (RDFFormat expected : formats) {
TripleFormat tf = TripleFormat.of(expected);
diff --git a/cli/src/main/java/org/apache/any23/cli/BaseTool.java b/cli/src/main/java/org/apache/any23/cli/BaseTool.java
index 5f9f5b1..954d283 100644
--- a/cli/src/main/java/org/apache/any23/cli/BaseTool.java
+++ b/cli/src/main/java/org/apache/any23/cli/BaseTool.java
@@ -23,15 +23,15 @@ import java.io.PrintStream;
import java.io.UnsupportedEncodingException;
/**
- * This class reduces the verbosity of testing command-line
- * console output by intercepting the underlying {@link PrintStream}
- * when applicable and replacing it with a more concise version.
+ * This class reduces the verbosity of testing command-line console output by intercepting the underlying
+ * {@link PrintStream} when applicable and replacing it with a more concise version.
*
* @author Hans Brende (hansbrende@apache.org)
*/
abstract class BaseTool implements Tool {
abstract PrintStream getOut();
+
abstract void setOut(PrintStream out);
void run(boolean concise) throws Exception {
@@ -49,17 +49,17 @@ abstract class BaseTool implements Tool {
try {
stream.close();
} catch (Throwable th) {
- //ignore
+ // ignore
}
}
}
private static PrintStream concise(PrintStream out, boolean concise) {
try {
- return (concise && (out == System.out || out == System.err)) ? new ConcisePrintStream(out)
- : (out instanceof ConcisePrintStream ? ((ConcisePrintStream) out).out : out);
+ return (concise && (out == System.out || out == System.err)) ? new ConcisePrintStream(out)
+ : (out instanceof ConcisePrintStream ? ((ConcisePrintStream) out).out : out);
} catch (UnsupportedEncodingException e) {
- throw new RuntimeException("Error supporting UTF-8 encodings in ConcisePrintStream", e);
+ throw new RuntimeException("Error supporting UTF-8 encodings in ConcisePrintStream", e);
}
}
@@ -72,6 +72,7 @@ abstract class BaseTool implements Tool {
StringBuilder sb = new StringBuilder();
int lineCount;
boolean truncated = false;
+
@Override
public void write(int b) throws IOException {
if (sb == null) {
@@ -81,7 +82,7 @@ abstract class BaseTool implements Tool {
lineCount++;
}
if (lineCount == 0 && sb.length() < 200) {
- sb.append((char)b);
+ sb.append((char) b);
} else if (!Character.isWhitespace(b)) {
truncated = true;
}
diff --git a/cli/src/main/java/org/apache/any23/cli/ExtractorDocumentation.java b/cli/src/main/java/org/apache/any23/cli/ExtractorDocumentation.java
index b3fe637..ed19420 100644
--- a/cli/src/main/java/org/apache/any23/cli/ExtractorDocumentation.java
+++ b/cli/src/main/java/org/apache/any23/cli/ExtractorDocumentation.java
@@ -34,22 +34,22 @@ import java.io.PrintStream;
import java.util.Locale;
/**
- * This class provides some command-line documentation
- * about available extractors and their usage.
+ * This class provides some command-line documentation about available extractors and their usage.
*/
-@Parameters( commandNames = { "extractor" }, commandDescription= "Utility for obtaining documentation about metadata extractors.")
+@Parameters(commandNames = {
+ "extractor" }, commandDescription = "Utility for obtaining documentation about metadata extractors.")
public class ExtractorDocumentation extends BaseTool {
- @Parameter( names = { "-l", "--list" }, description = "shows the names of all available extractors" )
+ @Parameter(names = { "-l", "--list" }, description = "shows the names of all available extractors")
private boolean showList;
- @Parameter( names = { "-i", "--input" }, description = "shows example input for the given extractor" )
+ @Parameter(names = { "-i", "--input" }, description = "shows example input for the given extractor")
private String input;
- @Parameter( names = { "-o", "--output" }, description = "shows example output for the given extractor" )
+ @Parameter(names = { "-o", "--output" }, description = "shows example output for the given extractor")
private String output;
- @Parameter( names = { "-a", "--all" }, description = "shows a report about all available extractors" )
+ @Parameter(names = { "-a", "--all" }, description = "shows a report about all available extractors")
private boolean showAll;
private PrintStream out = System.out;
@@ -80,7 +80,8 @@ public class ExtractorDocumentation extends BaseTool {
/**
* Print an error message.
*
- * @param msg the error message to be printed
+ * @param msg
+ * the error message to be printed
*/
public void printError(String msg) {
System.err.println(msg);
@@ -88,22 +89,27 @@ public class ExtractorDocumentation extends BaseTool {
/**
* Prints the list of all the available extractors.
- * @param registry the {@link org.apache.any23.extractor.ExtractorRegistry}
- * containing all extractors
+ *
+ * @param registry
+ * the {@link org.apache.any23.extractor.ExtractorRegistry} containing all extractors
*/
public void printExtractorList(ExtractorRegistry registry) {
for (ExtractorFactory factory : registry.getExtractorGroup()) {
- out.println(String.format(Locale.ROOT, "%25s [%15s]", factory.getExtractorName(), factory.getExtractorLabel()));
+ out.println(
+ String.format(Locale.ROOT, "%25s [%15s]", factory.getExtractorName(), factory.getExtractorLabel()));
}
}
/**
* Prints an example of input for the provided extractor.
*
- * @param extractorName the name of the extractor
- * @param registry the {@link org.apache.any23.extractor.ExtractorRegistry}
- * containing all extractors
- * @throws IOException raised if no extractor is found with that name
+ * @param extractorName
+ * the name of the extractor
+ * @param registry
+ * the {@link org.apache.any23.extractor.ExtractorRegistry} containing all extractors
+ *
+ * @throws IOException
+ * raised if no extractor is found with that name
*/
public void printExampleInput(String extractorName, ExtractorRegistry registry) throws IOException {
ExtractorFactory<?> factory = getFactory(registry, extractorName);
@@ -118,13 +124,18 @@ public class ExtractorDocumentation extends BaseTool {
/**
* Prints an output example for the given extractor.
*
- * @param extractorName the extractor name
- * @param registry the {@link org.apache.any23.extractor.ExtractorRegistry}
- * containing all extractors
- * @throws IOException raised if no extractor is found with that name
- * @throws ExtractionException if there is an error duing extraction
+ * @param extractorName
+ * the extractor name
+ * @param registry
+ * the {@link org.apache.any23.extractor.ExtractorRegistry} containing all extractors
+ *
+ * @throws IOException
+ * raised if no extractor is found with that name
+ * @throws ExtractionException
+ * if there is an error duing extraction
*/
- public void printExampleOutput(String extractorName, ExtractorRegistry registry) throws IOException, ExtractionException {
+ public void printExampleOutput(String extractorName, ExtractorRegistry registry)
+ throws IOException, ExtractionException {
ExtractorFactory<?> factory = getFactory(registry, extractorName);
ExampleInputOutput example = new ExampleInputOutput(factory);
String output = example.getExampleOutput();
@@ -137,10 +148,13 @@ public class ExtractorDocumentation extends BaseTool {
/**
* Prints a complete report on all the available extractors.
*
- * @param registry the {@link org.apache.any23.extractor.ExtractorRegistry}
- * containing all extractors
- * @throws IOException raised if no extractor is found with that name
- * @throws ExtractionException if there is an error duing extraction
+ * @param registry
+ * the {@link org.apache.any23.extractor.ExtractorRegistry} containing all extractors
+ *
+ * @throws IOException
+ * raised if no extractor is found with that name
+ * @throws ExtractionException
+ * if there is an error duing extraction
*/
public void printReport(ExtractorRegistry registry) throws IOException, ExtractionException {
for (String extractorName : registry.getAllNames()) {
diff --git a/cli/src/main/java/org/apache/any23/cli/MicrodataParser.java b/cli/src/main/java/org/apache/any23/cli/MicrodataParser.java
index 8655c5a..91ab8a5 100644
--- a/cli/src/main/java/org/apache/any23/cli/MicrodataParser.java
+++ b/cli/src/main/java/org/apache/any23/cli/MicrodataParser.java
@@ -38,24 +38,20 @@ import java.util.regex.Matcher;
import java.util.regex.Pattern;
/**
- * Command line <i>Microdata</i> parser, accepting both files and URLs and
- * returing a <i>JSON</i> representation of the extracted metadata as described at
- * <a href="http://www.w3.org/TR/microdata/#json">Microdata JSON Specification</a>.
+ * Command line <i>Microdata</i> parser, accepting both files and URLs and returing a <i>JSON</i> representation of the
+ * extracted metadata as described at <a href="http://www.w3.org/TR/microdata/#json">Microdata JSON Specification</a>.
*
* @author Michele Mostarda (mostarda@fbk.eu)
*/
-@Parameters( commandNames = { "microdata" }, commandDescription = "Commandline Tool for extracting Microdata from file/HTTP source.")
+@Parameters(commandNames = {
+ "microdata" }, commandDescription = "Commandline Tool for extracting Microdata from file/HTTP source.")
public class MicrodataParser extends BaseTool {
private static final Pattern HTTP_DOCUMENT_PATTERN = Pattern.compile("^https?://.*");
private static final Pattern FILE_DOCUMENT_PATTERN = Pattern.compile("^file:(.*)$");
- @Parameter(
- arity = 1,
- description = "Input document URL, {http://path/to/resource.html|file:/path/to/localFile.html}",
- converter = MicrodataParserDocumentSourceConverter.class
- )
+ @Parameter(arity = 1, description = "Input document URL, {http://path/to/resource.html|file:/path/to/localFile.html}", converter = MicrodataParserDocumentSourceConverter.class)
private List<DocumentSource> document = new LinkedList<DocumentSource>();
private PrintStream out = System.out;
@@ -78,31 +74,30 @@ public class MicrodataParser extends BaseTool {
try {
final DocumentSource documentSource = document.get(0);
documentInputInputStream = documentSource.openInputStream();
- final TagSoupParser tagSoupParser = new TagSoupParser(
- documentInputInputStream,
- documentSource.getDocumentIRI()
- );
+ final TagSoupParser tagSoupParser = new TagSoupParser(documentInputInputStream,
+ documentSource.getDocumentIRI());
org.apache.any23.extractor.microdata.MicrodataParser.getMicrodataAsJSON(tagSoupParser.getDOM(), out);
} finally {
- if (documentInputInputStream != null) StreamUtils.closeGracefully(documentInputInputStream);
+ if (documentInputInputStream != null)
+ StreamUtils.closeGracefully(documentInputInputStream);
}
}
public static final class MicrodataParserDocumentSourceConverter implements IStringConverter<DocumentSource> {
@Override
- public DocumentSource convert( String value ) {
+ public DocumentSource convert(String value) {
final Matcher httpMatcher = HTTP_DOCUMENT_PATTERN.matcher(value);
if (httpMatcher.find()) {
try {
return new HTTPDocumentSource(DefaultHTTPClient.createInitializedHTTPClient(), value);
- } catch ( URISyntaxException e ) {
+ } catch (URISyntaxException e) {
throw new ParameterException("Invalid source IRI: '" + value + "'");
}
}
final Matcher fileMatcher = FILE_DOCUMENT_PATTERN.matcher(value);
if (fileMatcher.find()) {
- return new FileDocumentSource( new File( fileMatcher.group(1) ) );
+ return new FileDocumentSource(new File(fileMatcher.group(1)));
}
throw new ParameterException("Invalid source protocol: '" + value + "'");
}
diff --git a/cli/src/main/java/org/apache/any23/cli/MimeDetector.java b/cli/src/main/java/org/apache/any23/cli/MimeDetector.java
index d4ec916..f66b8b5 100644
--- a/cli/src/main/java/org/apache/any23/cli/MimeDetector.java
+++ b/cli/src/main/java/org/apache/any23/cli/MimeDetector.java
@@ -38,26 +38,21 @@ import java.util.LinkedList;
import java.util.List;
/**
- * Commandline tool to detect <b>MIME Type</b>s from
- * file, HTTP and direct input sources.
- * The implementation of this tool is based on {@link org.apache.any23.mime.TikaMIMETypeDetector}.
+ * Commandline tool to detect <b>MIME Type</b>s from file, HTTP and direct input sources. The implementation of this
+ * tool is based on {@link org.apache.any23.mime.TikaMIMETypeDetector}.
*
* @author Michele Mostarda (mostarda@fbk.eu)
*/
@Parameters(commandNames = { "mimes" }, commandDescription = "MIME Type Detector Tool.")
public class MimeDetector extends BaseTool {
- public static final String FILE_DOCUMENT_PREFIX = "file://";
+ public static final String FILE_DOCUMENT_PREFIX = "file://";
public static final String INLINE_DOCUMENT_PREFIX = "inline://";
- public static final String URL_DOCUMENT_RE = "^https?://.*";
+ public static final String URL_DOCUMENT_RE = "^https?://.*";
- @Parameter(
- arity = 1,
- description = "Input document URL, {http://path/to/resource.html|file:///path/to/local.file|inline:// some inline content}",
- converter = MimeDetectorDocumentSourceConverter.class
- )
+ @Parameter(arity = 1, description = "Input document URL, {http://path/to/resource.html|file:///path/to/local.file|inline:// some inline content}", converter = MimeDetectorDocumentSourceConverter.class)
private List<DocumentSource> document = new LinkedList<DocumentSource>();
private PrintStream out = System.out;
@@ -79,30 +74,27 @@ public class MimeDetector extends BaseTool {
final DocumentSource documentSource = document.get(0);
final MIMETypeDetector detector = new TikaMIMETypeDetector();
- final MIMEType mimeType = detector.guessMIMEType(
- documentSource.getDocumentIRI(),
- documentSource.openInputStream(),
- MIMEType.parse(documentSource.getContentType())
- );
+ final MIMEType mimeType = detector.guessMIMEType(documentSource.getDocumentIRI(),
+ documentSource.openInputStream(), MIMEType.parse(documentSource.getContentType()));
out.println(mimeType);
}
public static final class MimeDetectorDocumentSourceConverter implements IStringConverter<DocumentSource> {
@Override
- public DocumentSource convert( String document ) {
+ public DocumentSource convert(String document) {
if (document.startsWith(FILE_DOCUMENT_PREFIX)) {
- return new FileDocumentSource( new File( document.substring(FILE_DOCUMENT_PREFIX.length()) ) );
+ return new FileDocumentSource(new File(document.substring(FILE_DOCUMENT_PREFIX.length())));
}
if (document.startsWith(INLINE_DOCUMENT_PREFIX)) {
- return new StringDocumentSource( document.substring(INLINE_DOCUMENT_PREFIX.length()), "" );
+ return new StringDocumentSource(document.substring(INLINE_DOCUMENT_PREFIX.length()), "");
}
if (document.matches(URL_DOCUMENT_RE)) {
final HTTPClient client = new DefaultHTTPClient();
- client.init( DefaultHTTPClientConfiguration.singleton() );
+ client.init(DefaultHTTPClientConfiguration.singleton());
try {
return new HTTPDocumentSource(client, document);
- } catch ( URISyntaxException e ) {
+ } catch (URISyntaxException e) {
throw new IllegalArgumentException("Invalid source IRI: '" + document + "'");
}
}
diff --git a/cli/src/main/java/org/apache/any23/cli/PluginVerifier.java b/cli/src/main/java/org/apache/any23/cli/PluginVerifier.java
index f83ad14..602d22a 100644
--- a/cli/src/main/java/org/apache/any23/cli/PluginVerifier.java
+++ b/cli/src/main/java/org/apache/any23/cli/PluginVerifier.java
@@ -33,8 +33,7 @@ import java.util.List;
import java.util.Locale;
/**
- * Commandline utility to verify the <b>Any23</b> plugins
- * and extract basic information.
+ * Commandline utility to verify the <b>Any23</b> plugins and extract basic information.
*
* @author Michele Mostarda (mostarda@fbk.eu)
*/
@@ -43,10 +42,7 @@ public class PluginVerifier extends BaseTool {
private Any23PluginManager pluginManager = Any23PluginManager.getInstance();
- @Parameter(
- description = "plugins-dir",
- converter = FileConverter.class
- )
+ @Parameter(description = "plugins-dir", converter = FileConverter.class)
private List<File> pluginsDirs = new LinkedList<>();
private PrintStream out = System.out;
@@ -91,7 +87,8 @@ public class PluginVerifier extends BaseTool {
private void printPluginData(ExtractorFactory<?> extractorFactory, PrintStream ps) {
final Author authorAnnotation = extractorFactory.getClass().getAnnotation(Author.class);
- ps.printf(Locale.ROOT, "Plugin author : %s%n", authorAnnotation == null ? "<unknown>" : authorAnnotation.name());
+ ps.printf(Locale.ROOT, "Plugin author : %s%n",
+ authorAnnotation == null ? "<unknown>" : authorAnnotation.name());
ps.printf(Locale.ROOT, "Plugin factory : %s%n", extractorFactory.getClass());
ps.printf(Locale.ROOT, "Plugin mime-types: %s%n", getMimeTypesStr(extractorFactory.getSupportedMIMETypes()));
}
diff --git a/cli/src/main/java/org/apache/any23/cli/Rover.java b/cli/src/main/java/org/apache/any23/cli/Rover.java
index 488d61d..0274653 100644
--- a/cli/src/main/java/org/apache/any23/cli/Rover.java
+++ b/cli/src/main/java/org/apache/any23/cli/Rover.java
@@ -65,8 +65,8 @@ import java.util.Objects;
import static java.lang.String.format;
/**
- * A default rover implementation. Goes and fetches a URL using an hint
- * as to what format should require, then tries to convert it to RDF.
+ * A default rover implementation. Goes and fetches a URL using an hint as to what format should require, then tries to
... 34934 lines suppressed ...