FindBugs Bug Detector Report

The following document contains the results of FindBugs Report

FindBugs Version is 1.3.9

Threshold is medium

Effort is min

Summary

Classes Bugs Errors Missing Classes
269 193 0 0

Files

Class Bugs
eu.annocultor.cli.Cli 1
eu.annocultor.common.Cache 1
eu.annocultor.common.Helper 2
eu.annocultor.common.JarResources 2
eu.annocultor.common.Language$Lang 1
eu.annocultor.common.Utils 10
eu.annocultor.context.Concepts 2
eu.annocultor.context.EnvironmentImpl 4
eu.annocultor.context.Namespace 1
eu.annocultor.converter.Analyser 4
eu.annocultor.converter.Analyser$ValueCount 1
eu.annocultor.converter.Converter 2
eu.annocultor.converter.ConverterHandler 1
eu.annocultor.converter.ConverterHandlerDataObjects 1
eu.annocultor.converter.DataObjectImpl 1
eu.annocultor.converter.RdfDiffInt$DiffResults 1
eu.annocultor.converter.TaskImpl 1
eu.annocultor.converters.time.GenerateTimeOntologyTrunk 7
eu.annocultor.converters.time.OntologyToHtmlGenerator 1
eu.annocultor.data.destinations.AbstractFileWritingGraph 4
eu.annocultor.data.destinations.AbstractGraph 1
eu.annocultor.data.destinations.PropertiesFile 1
eu.annocultor.data.destinations.RdfGraph 1
eu.annocultor.data.sources.AbstractQueryDataSource$QueryIterator 1
eu.annocultor.data.sources.SqlDataSource 2
eu.annocultor.path.NamespacedName 2
eu.annocultor.path.Path 1
eu.annocultor.path.PathElement 2
eu.annocultor.path.PathMap 1
eu.annocultor.path.PathMap$MatchResult 1
eu.annocultor.reports.AbstractReporter 1
eu.annocultor.reports.ApprovalFormPairs 1
eu.annocultor.reports.ReportPresenter 2
eu.annocultor.reports.ReporterImpl$Counter 2
eu.annocultor.reports.ReporterImpl$TermCounter 1
eu.annocultor.reports.parts.ReportCounter 1
eu.annocultor.reports.parts.ReportCounter$ObjectCountPair 1
eu.annocultor.rules.BatchRule$WrappedRule 1
eu.annocultor.rules.BranchOnTermInVocabularyRule 2
eu.annocultor.rules.FacetRenamePropertyRule 5
eu.annocultor.rules.ReplaceValuesRule 2
eu.annocultor.tagger.postprocessors.AdminDivisionTermFilter 1
eu.annocultor.tagger.postprocessors.PeopleTermFilter 1
eu.annocultor.tagger.postprocessors.PopulationTermFilter 1
eu.annocultor.tagger.rules.AbstractLookupRule 1
eu.annocultor.tagger.rules.LookupPlaceRule 1
eu.annocultor.tagger.rules.LookupTermRule 2
eu.annocultor.tagger.rules.LookupTimeRule 2
eu.annocultor.tagger.rules.LookupWorkRule 1
eu.annocultor.tagger.rules.PairOfStrings 1
eu.annocultor.tagger.rules.PersonDetails 3
eu.annocultor.tagger.terms.Term 1
eu.annocultor.tagger.terms.TermList 1
eu.annocultor.tagger.vocabularies.AbstractVocabulary 5
eu.annocultor.tagger.vocabularies.DisambiguationContext 1
eu.annocultor.tagger.vocabularies.VocabularyOfPlaces 1
eu.annocultor.tagger.vocabularies.VocabularySerializer 2
eu.annocultor.triple.ResourceValue 1
eu.annocultor.triple.Triple 1
eu.annocultor.utils.DerbyHelper 5
eu.annocultor.utils.DerbyHelper$ConversionReportsDb 12
eu.annocultor.utils.DerbyHelper$ConversionResultsDb 4
eu.annocultor.utils.ImageDownloader 9
eu.annocultor.utils.ImageOnlineChecker 5
eu.annocultor.utils.SesameTestHelper 2
eu.annocultor.utils.SesameWriter 2
eu.annocultor.xconverter.api.PropertyRule 1
eu.annocultor.xconverter.impl.Converter 6
eu.annocultor.xconverter.impl.XConverter2Java 3
eu.annocultor.xconverter.impl.XConverter2Java$ProfileEntityResolver 1
eu.annocultor.xconverter.impl.XConverterFactory$MapObjectToObject 1
eu.annocultor.xconverter.impl.XConverterFactory$MapPathToProperty 1
eu.europeana.normalizer.AnnoCultorProfileExporter 3
eu.europeana.normalizer.Profile$FieldMapping 5
eu.europeana.normalizer.Profile$LanguageMapping 2
eu.europeana.normalizer.Profile$MapTo 3
eu.europeana.normalizer.Profile$RecordAddition 1
eu.europeana.normalizer.Profile$TypeMapping 2
org.json.JSONArray 6
org.json.JSONObject 8
org.json.JSONObject$Null 2
org.json.JSONStringer 1
org.json.JSONTokener 1

eu.annocultor.cli.Cli

Bug Category Details Line Priority
eu.annocultor.cli.Cli.commands isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 38 High

eu.annocultor.common.Cache

Bug Category Details Line Priority
Unread field: eu.annocultor.common.Cache.SIZE_LIMIT; should this field be static? PERFORMANCE SS_SHOULD_BE_STATIC 30 Medium

eu.annocultor.common.Helper

Bug Category Details Line Priority
eu.annocultor.common.Helper.importRDFXMLFile(Repository, String, File[]) explicitly invokes run on a thread (did you mean to start it instead?) MT_CORRECTNESS RU_INVOKE_RUN 354 Medium
Method eu.annocultor.common.Helper.generateTracingQuery(String, String, String, String, int) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 130 Medium

eu.annocultor.common.JarResources

Bug Category Details Line Priority
Method eu.annocultor.common.JarResources.init() invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead PERFORMANCE DM_NUMBER_CTOR 76 Medium
eu.annocultor.common.JarResources.init() may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 83 Medium

eu.annocultor.common.Language$Lang

Bug Category Details Line Priority
Uninitialized read of code in new eu.annocultor.common.Language$Lang(String, int, String, String, String) CORRECTNESS UR_UNINIT_READ 785 High

eu.annocultor.common.Utils

Bug Category Details Line Priority
Load of known null value in eu.annocultor.common.Utils.compareFiles(File, File, int) STYLE NP_LOAD_OF_KNOWN_NULL_VALUE 191 Medium
Method eu.annocultor.common.Utils.loadFileToString(String, String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 232 Medium
Method eu.annocultor.common.Utils.loadURLToString(String, String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 265 Medium
Method eu.annocultor.common.Utils.merge(String[], String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 292 Medium
Method eu.annocultor.common.Utils.readResourceFileAsString(String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 391 Medium
Method eu.annocultor.common.Utils.readResourceFileFromSamePackageAsString(Class, String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 423 Medium
Method eu.annocultor.common.Utils.show(Collection, String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 123 Medium
Method eu.annocultor.common.Utils.show(String[], String) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 135 Medium

eu.annocultor.context.Concepts

Bug Category Details Line Priority
eu.annocultor.context.Concepts.conceptClasses isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 319 High
Unread field: eu.annocultor.context.Concepts.log PERFORMANCE URF_UNREAD_FIELD 48 Medium

eu.annocultor.context.EnvironmentImpl

Bug Category Details Line Priority
eu.annocultor.context.EnvironmentImpl.concepts should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
Method eu.annocultor.context.EnvironmentImpl.toString() concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 51 Medium
Write to static field eu.annocultor.context.EnvironmentImpl.isVocabularyInitialized from instance method eu.annocultor.context.EnvironmentImpl.initializeVocabularies() STYLE ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD 261 High

eu.annocultor.context.Namespace

Bug Category Details Line Priority
eu.annocultor.context.Namespace.equals(Object) checks for operand being a String BAD_PRACTICE EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS 59 High

eu.annocultor.converter.Analyser

Bug Category Details Line Priority
Dead store to analyser in eu.annocultor.converter.Analyser.main(String[]) STYLE DLS_DEAD_LOCAL_STORE 132 High
eu.annocultor.converter.Analyser.MAX_VALUES should be package protected MALICIOUS_CODE MS_PKGPROTECT 86 Medium
eu.annocultor.converter.Analyser.MAX_VALUE_SIZE should be package protected MALICIOUS_CODE MS_PKGPROTECT 85 Medium
Method eu.annocultor.converter.Analyser.computeAndExportStatistics(SortedMap, File) makes inefficient use of keySet iterator instead of entrySet iterator PERFORMANCE WMI_WRONG_MAP_ITERATOR 367 Medium

eu.annocultor.converter.Analyser$ValueCount

Bug Category Details Line Priority
eu.annocultor.converter.Analyser$ValueCount.equals(Object) checks for operand being a String BAD_PRACTICE EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS 294 High

eu.annocultor.converter.Converter

Bug Category Details Line Priority
eu.annocultor.converter.Converter.startConversion() ignores exceptional return value of java.io.File.mkdir() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 124 Medium
Unread field: eu.annocultor.converter.Converter.tester PERFORMANCE URF_UNREAD_FIELD 55 Medium

eu.annocultor.converter.ConverterHandler

Bug Category Details Line Priority
Method eu.annocultor.converter.ConverterHandler.reportException(Exception) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 488 Medium

eu.annocultor.converter.ConverterHandlerDataObjects

Bug Category Details Line Priority
Unread field: eu.annocultor.converter.ConverterHandlerDataObjects.log PERFORMANCE URF_UNREAD_FIELD 38 Medium

eu.annocultor.converter.DataObjectImpl

Bug Category Details Line Priority
Method eu.annocultor.converter.DataObjectImpl.toString() concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 182 Medium

eu.annocultor.converter.RdfDiffInt$DiffResults

Bug Category Details Line Priority
Method eu.annocultor.converter.RdfDiffInt$DiffResults.findDiff(RdfDiffInt$ResourceType, RdfDiffInt$Operation) makes inefficient use of keySet iterator instead of entrySet iterator PERFORMANCE WMI_WRONG_MAP_ITERATOR 122 Medium

eu.annocultor.converter.TaskImpl

Bug Category Details Line Priority
TaskImpl is incompatible with expected argument type eu.annocultor.xconverter.api.Graph in eu.annocultor.converter.TaskImpl.addGraph(Graph) CORRECTNESS GC_UNRELATED_TYPES 104 Medium

eu.annocultor.converters.time.GenerateTimeOntologyTrunk

Bug Category Details Line Priority
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.ad should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.bc should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.centuryTemplates should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.decadesTemplates should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.halfsTemplates should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.quartersTemplates should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium
eu.annocultor.converters.time.GenerateTimeOntologyTrunk.thirdsTemplates should be package protected MALICIOUS_CODE MS_PKGPROTECT Not available Medium

eu.annocultor.converters.time.OntologyToHtmlGenerator

Bug Category Details Line Priority
eu.annocultor.converters.time.OntologyToHtmlGenerator.main(String[]) ignores exceptional return value of java.io.File.mkdirs() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 56 Medium

eu.annocultor.data.destinations.AbstractFileWritingGraph

Bug Category Details Line Priority
Load of known null value in eu.annocultor.data.destinations.AbstractFileWritingGraph.checkTriple(Triple) STYLE NP_LOAD_OF_KNOWN_NULL_VALUE 146 Medium
Method eu.annocultor.data.destinations.AbstractFileWritingGraph.add(Triple) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 282 Medium
Method eu.annocultor.data.destinations.AbstractFileWritingGraph.getReport(Property) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 330 Medium
Unread field: eu.annocultor.data.destinations.AbstractFileWritingGraph.MAX_TRIPLES_PER_FILE; should this field be static? PERFORMANCE SS_SHOULD_BE_STATIC 43 Medium

eu.annocultor.data.destinations.AbstractGraph

Bug Category Details Line Priority
Unread field: eu.annocultor.data.destinations.AbstractGraph.log PERFORMANCE URF_UNREAD_FIELD 28 Medium

eu.annocultor.data.destinations.PropertiesFile

Bug Category Details Line Priority

eu.annocultor.data.destinations.RdfGraph

Bug Category Details Line Priority
eu.annocultor.data.destinations.RdfGraph defines equals but not hashCode BAD_PRACTICE HE_EQUALS_NO_HASHCODE 65-68 Medium

eu.annocultor.data.sources.AbstractQueryDataSource$QueryIterator

Bug Category Details Line Priority
Should eu.annocultor.data.sources.AbstractQueryDataSource$QueryIterator be a _static_ inner class? PERFORMANCE SIC_INNER_SHOULD_BE_STATIC 104-134 Medium

eu.annocultor.data.sources.SqlDataSource

Bug Category Details Line Priority
eu.annocultor.data.sources.SqlDataSource.parseQuery(DefaultHandler, String, Path, Path) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 73 Medium

eu.annocultor.path.NamespacedName

Bug Category Details Line Priority
Equals method for eu.annocultor.path.NamespacedName assumes the argument is of type NamespacedName BAD_PRACTICE BC_EQUALS_METHOD_SHOULD_WORK_FOR_ALL_OBJECTS 56 Medium
eu.annocultor.path.NamespacedName.equals(Object) does not check for null argument BAD_PRACTICE NP_EQUALS_SHOULD_HANDLE_NULL_ARGUMENT 56-57 High

eu.annocultor.path.Path

Bug Category Details Line Priority
Method eu.annocultor.path.Path.formatPath(Path, Namespaces) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 383 Medium

eu.annocultor.path.PathElement

Bug Category Details Line Priority
Equals method for eu.annocultor.path.PathElement assumes the argument is of type PathElement BAD_PRACTICE BC_EQUALS_METHOD_SHOULD_WORK_FOR_ALL_OBJECTS 264 Medium
eu.annocultor.path.PathElement.equals(Object) does not check for null argument BAD_PRACTICE NP_EQUALS_SHOULD_HANDLE_NULL_ARGUMENT 261-265 High

eu.annocultor.path.PathMap

Bug Category Details Line Priority
Method eu.annocultor.path.PathMap.toString() concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 45 Medium

eu.annocultor.path.PathMap$MatchResult

Bug Category Details Line Priority
Unwritten field: eu.annocultor.path.PathMap$MatchResult.attributeName CORRECTNESS UWF_UNWRITTEN_FIELD 269 Medium

eu.annocultor.reports.AbstractReporter

Bug Category Details Line Priority
new eu.annocultor.reports.AbstractReporter(File, String) ignores exceptional return value of java.io.File.mkdirs() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 279 Medium

eu.annocultor.reports.ApprovalFormPairs

Bug Category Details Line Priority
eu.annocultor.tagger.terms.CodeURI is incompatible with expected argument type String in eu.annocultor.reports.ApprovalFormPairs.main(String[]) CORRECTNESS GC_UNRELATED_TYPES 121 High

eu.annocultor.reports.ReportPresenter

Bug Category Details Line Priority
eu.annocultor.reports.ReportPresenter.makeHtmlReport() ignores exceptional return value of java.io.File.delete() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 70 Medium
eu.annocultor.reports.ReportPresenter.makeHtmlReport() ignores exceptional return value of java.io.File.mkdirs() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 215 Medium

eu.annocultor.reports.ReporterImpl$Counter

Bug Category Details Line Priority
eu.annocultor.reports.ReporterImpl$Counter.equals(Object) checks for operand being a String BAD_PRACTICE EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS 186 High
Unread field: eu.annocultor.reports.ReporterImpl$Counter.trgProperty PERFORMANCE URF_UNREAD_FIELD 152 Medium

eu.annocultor.reports.ReporterImpl$TermCounter

Bug Category Details Line Priority
eu.annocultor.reports.ReporterImpl$TermCounter defines compareTo(ReporterImpl$TermCounter) and uses Object.equals() BAD_PRACTICE EQ_COMPARETO_USE_OBJECT_EQUALS 114-118 Medium

eu.annocultor.reports.parts.ReportCounter

Bug Category Details Line Priority

eu.annocultor.reports.parts.ReportCounter$ObjectCountPair

Bug Category Details Line Priority
eu.annocultor.reports.parts.ReportCounter$ObjectCountPair defines compareTo(ReportCounter$ObjectCountPair) and uses Object.equals() BAD_PRACTICE EQ_COMPARETO_USE_OBJECT_EQUALS 152 Medium

eu.annocultor.rules.BatchRule$WrappedRule

Bug Category Details Line Priority
Should eu.annocultor.rules.BatchRule$WrappedRule be a _static_ inner class? PERFORMANCE SIC_INNER_SHOULD_BE_STATIC 125-146 Medium

eu.annocultor.rules.BranchOnTermInVocabularyRule

Bug Category Details Line Priority
Unread field: eu.annocultor.rules.BranchOnTermInVocabularyRule.propertyName PERFORMANCE URF_UNREAD_FIELD 58 Medium
Unread field: eu.annocultor.rules.BranchOnTermInVocabularyRule.vocabulary PERFORMANCE URF_UNREAD_FIELD 59 Medium

eu.annocultor.rules.FacetRenamePropertyRule

Bug Category Details Line Priority
eu.annocultor.triple.Value is incompatible with expected argument type String in eu.annocultor.rules.FacetRenamePropertyRule.fire(Triple, DataObject) CORRECTNESS GC_UNRELATED_TYPES 227 High
Double assignment of field FacetRenamePropertyRule.facetToLang in new eu.annocultor.rules.FacetRenamePropertyRule(Map, Path, Namespace, Path, String, Map, Path, Graph, PropertyRule, PropertyRule) CORRECTNESS SA_FIELD_DOUBLE_ASSIGNMENT 171 Medium
Unread field: eu.annocultor.rules.FacetRenamePropertyRule.facetToLang PERFORMANCE URF_UNREAD_FIELD 99 Medium
Unread field: eu.annocultor.rules.FacetRenamePropertyRule.lang PERFORMANCE URF_UNREAD_FIELD 97 Medium
Unread field: eu.annocultor.rules.FacetRenamePropertyRule.langProperty PERFORMANCE URF_UNREAD_FIELD 172 Medium

eu.annocultor.rules.ReplaceValuesRule

Bug Category Details Line Priority
new eu.annocultor.rules.ReplaceValuesRule(String[], String[], Path, PropertyRule[]) may expose internal representation by storing an externally mutable object into ReplaceValuesRule.originalValues MALICIOUS_CODE EI_EXPOSE_REP2 83 Medium
new eu.annocultor.rules.ReplaceValuesRule(String[], String[], Path, PropertyRule[]) may expose internal representation by storing an externally mutable object into ReplaceValuesRule.replacements MALICIOUS_CODE EI_EXPOSE_REP2 84 Medium

eu.annocultor.tagger.postprocessors.AdminDivisionTermFilter

Bug Category Details Line Priority
Dead store to selectedTerms in eu.annocultor.tagger.postprocessors.AdminDivisionTermFilter.disambiguate(TermList, DisambiguationContext) STYLE DLS_DEAD_LOCAL_STORE 43 Medium

eu.annocultor.tagger.postprocessors.PeopleTermFilter

Bug Category Details Line Priority
Method eu.annocultor.tagger.postprocessors.PeopleTermFilter.toString(Set) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 228 Medium

eu.annocultor.tagger.postprocessors.PopulationTermFilter

Bug Category Details Line Priority
Dead store to selectedTerms in eu.annocultor.tagger.postprocessors.PopulationTermFilter.disambiguate(TermList, DisambiguationContext) STYLE DLS_DEAD_LOCAL_STORE 46 Medium

eu.annocultor.tagger.rules.AbstractLookupRule

Bug Category Details Line Priority
Unread field: eu.annocultor.tagger.rules.AbstractLookupRule.log PERFORMANCE URF_UNREAD_FIELD 62 Medium

eu.annocultor.tagger.rules.LookupPlaceRule

Bug Category Details Line Priority
eu.annocultor.tagger.rules.LookupPlaceRule.vocabularies isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 54 High

eu.annocultor.tagger.rules.LookupTermRule

Bug Category Details Line Priority
eu.annocultor.tagger.rules.LookupTermRule.allVocabularies isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 47 High
Unread field: eu.annocultor.tagger.rules.LookupTermRule.parent PERFORMANCE URF_UNREAD_FIELD 195 Medium

eu.annocultor.tagger.rules.LookupTimeRule

Bug Category Details Line Priority
eu.annocultor.tagger.rules.LookupTimeRule.allVocabularies isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 50 High
Unread field: eu.annocultor.tagger.rules.LookupTimeRule.parent PERFORMANCE URF_UNREAD_FIELD 202 Medium

eu.annocultor.tagger.rules.LookupWorkRule

Bug Category Details Line Priority
eu.annocultor.tagger.rules.LookupWorkRule.vocabularies isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 42 High

eu.annocultor.tagger.rules.PairOfStrings

Bug Category Details Line Priority
eu.annocultor.tagger.rules.PairOfStrings defines equals and uses Object.hashCode() BAD_PRACTICE HE_EQUALS_USE_HASHCODE 38-55 High

eu.annocultor.tagger.rules.PersonDetails

Bug Category Details Line Priority
Unread field: eu.annocultor.tagger.rules.PersonDetails.COMMA; should this field be static? PERFORMANCE SS_SHOULD_BE_STATIC 37 Medium
Unwritten field: eu.annocultor.tagger.rules.PersonDetails.birthPlace CORRECTNESS UWF_UNWRITTEN_FIELD 90 Medium
Unwritten field: eu.annocultor.tagger.rules.PersonDetails.deathPlace CORRECTNESS UWF_UNWRITTEN_FIELD 94 Medium

eu.annocultor.tagger.terms.Term

Bug Category Details Line Priority
eu.annocultor.tagger.terms.Term defines compareTo(Term) and uses Object.equals() BAD_PRACTICE EQ_COMPARETO_USE_OBJECT_EQUALS 130-146 Medium

eu.annocultor.tagger.terms.TermList

Bug Category Details Line Priority
Method eu.annocultor.tagger.terms.TermList.toString() concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 106 Medium

eu.annocultor.tagger.vocabularies.AbstractVocabulary

Bug Category Details Line Priority
eu.annocultor.tagger.vocabularies.AbstractVocabulary.loadMap(File, String[], String, String, boolean, File, VocabularySerializer) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 295 Medium
eu.annocultor.tagger.vocabularies.AbstractVocabulary.loadMap(File, String[], String, String, boolean, File, VocabularySerializer) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 391 Medium
Nullcheck of cacheDir at line 271 of value previously dereferenced in eu.annocultor.tagger.vocabularies.AbstractVocabulary.loadMap(File, String[], String, String, boolean, File, VocabularySerializer) CORRECTNESS RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE 239 Medium
Method eu.annocultor.tagger.vocabularies.AbstractVocabulary.loadMap(File, String[], String, String, boolean, File, VocabularySerializer) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 387 Medium

eu.annocultor.tagger.vocabularies.DisambiguationContext

Bug Category Details Line Priority
eu.annocultor.tagger.vocabularies.DisambiguationContext.NO_DISAMBIGUATION isn't final but should be MALICIOUS_CODE MS_SHOULD_BE_FINAL 44 High

eu.annocultor.tagger.vocabularies.VocabularyOfPlaces

Bug Category Details Line Priority
Unread field: eu.annocultor.tagger.vocabularies.VocabularyOfPlaces.placeTypes PERFORMANCE URF_UNREAD_FIELD 52 Medium

eu.annocultor.tagger.vocabularies.VocabularySerializer

Bug Category Details Line Priority
Method eu.annocultor.tagger.vocabularies.VocabularySerializer.serializeToProperties() concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 166 Medium
Unread field: eu.annocultor.tagger.vocabularies.VocabularySerializer.log PERFORMANCE URF_UNREAD_FIELD 44 Medium

eu.annocultor.triple.ResourceValue

Bug Category Details Line Priority
eu.annocultor.triple.ResourceValue.equals(Object) checks for operand being a String BAD_PRACTICE EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS 49 High

eu.annocultor.triple.Triple

Bug Category Details Line Priority
eu.annocultor.triple.Triple.equals(Object) does not check for null argument BAD_PRACTICE NP_EQUALS_SHOULD_HANDLE_NULL_ARGUMENT 186 High

eu.annocultor.utils.DerbyHelper

Bug Category Details Line Priority
Hard coded reference to an absolute pathname in eu.annocultor.utils.DerbyHelper.main(String[]) STYLE DMI_HARDCODED_ABSOLUTE_FILENAME 54 Medium
eu.annocultor.utils.DerbyHelper.computeDiff(String, String, String, Repository) may fail to close Connection BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 542 Medium
eu.annocultor.utils.DerbyHelper.computeDiff(String, String, String, Repository) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 544 Medium

eu.annocultor.utils.DerbyHelper$ConversionReportsDb

Bug Category Details Line Priority
Dead store to stmt in eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeCounterToDb(String, Long, String, String, String, String, String, List) STYLE DLS_DEAD_LOCAL_STORE 379 Medium
Dead store to stmt in eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeTransactionToDb(String, String, String) STYLE DLS_DEAD_LOCAL_STORE 490 Medium
eu.annocultor.utils.DerbyHelper$ConversionReportsDb.closeReporterDB(String) may fail to close Connection BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 253 Medium
eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeCounterToDb(String, Long, String, String, String, String, String, List) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 379 Medium
eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeTransactionToDb(String, String, String) may fail to close Connection BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 487 Medium
eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeTransactionToDb(String, String, String) may fail to close PreparedStatement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 491 Medium
eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeTransactionToDb(String, String, String) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 490 Medium
A prepared statement is generated from a nonconstant String at eu.annocultor.utils.DerbyHelper$ConversionReportsDb.writeTransactionToDb(String, String, String) SECURITY SQL_PREPARED_STATEMENT_GENERATED_FROM_NONCONSTANT_STRING 491 High

eu.annocultor.utils.DerbyHelper$ConversionResultsDb

Bug Category Details Line Priority
eu.annocultor.utils.DerbyHelper$ConversionResultsDb.createConverterTables(String) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 69 Medium
eu.annocultor.utils.DerbyHelper$ConversionResultsDb.writeRdfToDb(String, String, String, Repository) may fail to close PreparedStatement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 145 Medium
eu.annocultor.utils.DerbyHelper$ConversionResultsDb.writeRdfToDb(String, String, String, Repository) may fail to close Statement BAD_PRACTICE ODR_OPEN_DATABASE_RESOURCE 135 Medium

eu.annocultor.utils.ImageDownloader

Bug Category Details Line Priority
Test for floating point equality in eu.annocultor.utils.ImageDownloader.createListOfImagesThatExist(String, String) STYLE FE_FLOATING_POINT_EQUALITY 192 High
Test for floating point equality in eu.annocultor.utils.ImageDownloader.downloadImages(String, String, String) STYLE FE_FLOATING_POINT_EQUALITY 111 High
integral division result cast to double or float in eu.annocultor.utils.ImageDownloader.createListOfImagesThatExist(String, String) STYLE ICAST_IDIV_CAST_TO_DOUBLE 192 Medium
integral division result cast to double or float in eu.annocultor.utils.ImageDownloader.downloadImages(String, String, String) STYLE ICAST_IDIV_CAST_TO_DOUBLE 111 Medium
eu.annocultor.utils.ImageDownloader.createListOfImagesThatExist(String, String) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 126 Medium
eu.annocultor.utils.ImageDownloader.createListOfImagesThatExist(String, String) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 199 Medium
eu.annocultor.utils.ImageDownloader.downloadImages(String, String, String) may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 59 Medium

eu.annocultor.utils.ImageOnlineChecker

Bug Category Details Line Priority
eu.annocultor.utils.ImageOnlineChecker.load() may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 80 Medium
eu.annocultor.utils.ImageOnlineChecker.save() may fail to close stream BAD_PRACTICE OS_OPEN_STREAM 98 Medium
eu.annocultor.utils.ImageOnlineChecker.save() ignores exceptional return value of java.io.File.mkdir() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 96 Medium

eu.annocultor.utils.SesameTestHelper

Bug Category Details Line Priority
Unwritten field: eu.annocultor.utils.SesameTestHelper.files CORRECTNESS UWF_UNWRITTEN_FIELD 63 Medium
Unwritten field: eu.annocultor.utils.SesameTestHelper.tmp CORRECTNESS UWF_UNWRITTEN_FIELD 60 Medium

eu.annocultor.utils.SesameWriter

Bug Category Details Line Priority
eu.annocultor.utils.SesameWriter.createRDFXMLWriter(File, Namespaces, String, String, int, int, String[]) ignores exceptional return value of java.io.File.delete() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 64 Medium
Method eu.annocultor.utils.SesameWriter.createRDFXMLWriter(File, Namespaces, String, String, int, int, String[]) concatenates strings using + in a loop PERFORMANCE SBSC_USE_STRINGBUFFER_CONCATENATION 103 Medium

eu.annocultor.xconverter.api.PropertyRule

Bug Category Details Line Priority
instanceof will always return true in eu.annocultor.xconverter.api.PropertyRule.setObjectRule(ObjectRule), since all eu.annocultor.xconverter.api.PropertyRule are instances of eu.annocultor.xconverter.api.PropertyRule STYLE BC_VACUOUS_INSTANCEOF 79 Medium

eu.annocultor.xconverter.impl.Converter

Bug Category Details Line Priority
Dead store to classParameters in eu.annocultor.xconverter.impl.Converter.run(File, File, PrintWriter, OutputStream) STYLE DLS_DEAD_LOCAL_STORE 175 Medium
eu.annocultor.xconverter.impl.Converter.compile(File, File, PrintWriter, OutputStream) ignores exceptional return value of java.io.File.delete() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 101 Medium
eu.annocultor.xconverter.impl.Converter.compile(File, File, PrintWriter, OutputStream) ignores exceptional return value of java.io.File.mkdir() BAD_PRACTICE RV_RETURN_VALUE_IGNORED_BAD_PRACTICE 69 Medium

eu.annocultor.xconverter.impl.XConverter2Java

Bug Category Details Line Priority
Dead store to schemaFile in eu.annocultor.xconverter.impl.XConverter2Java.run(File, InputStream, String, OutputStream, File) STYLE DLS_DEAD_LOCAL_STORE 162 High
Dead store to factory in eu.annocultor.xconverter.impl.XConverter2Java.run(File, InputStream, String, OutputStream, File) STYLE DLS_DEAD_LOCAL_STORE 156 Medium

eu.annocultor.xconverter.impl.XConverter2Java$ProfileEntityResolver

Bug Category Details Line Priority
Should eu.annocultor.xconverter.impl.XConverter2Java$ProfileEntityResolver be a _static_ inner class? PERFORMANCE SIC_INNER_SHOULD_BE_STATIC 59-82 Medium

eu.annocultor.xconverter.impl.XConverterFactory$MapObjectToObject

Bug Category Details Line Priority
Should eu.annocultor.xconverter.impl.XConverterFactory$MapObjectToObject be a _static_ inner class? PERFORMANCE SIC_INNER_SHOULD_BE_STATIC 281-295 Medium

eu.annocultor.xconverter.impl.XConverterFactory$MapPathToProperty

Bug Category Details Line Priority
Should eu.annocultor.xconverter.impl.XConverterFactory$MapPathToProperty be a _static_ inner class? PERFORMANCE SIC_INNER_SHOULD_BE_STATIC 247-261 Medium

eu.europeana.normalizer.AnnoCultorProfileExporter

Bug Category Details Line Priority
Read of unwritten field doc in eu.europeana.normalizer.AnnoCultorProfileExporter.addLeaveElement(Element, String, String) CORRECTNESS NP_UNWRITTEN_FIELD 40 Medium
Unwritten field: eu.europeana.normalizer.AnnoCultorProfileExporter.doc CORRECTNESS UWF_UNWRITTEN_FIELD 40 Medium

eu.europeana.normalizer.Profile$FieldMapping

Bug Category Details Line Priority
eu.europeana.normalizer.Profile$FieldMapping defines compareTo(Profile$FieldMapping) and uses Object.equals() BAD_PRACTICE EQ_COMPARETO_USE_OBJECT_EQUALS 104 Medium
Unused field: eu.europeana.normalizer.Profile$FieldMapping.acceptField PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$FieldMapping.chooseFirst PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$FieldMapping.chooseLast PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$FieldMapping.discardRecord PERFORMANCE UUF_UNUSED_FIELD Not available Medium

eu.europeana.normalizer.Profile$LanguageMapping

Bug Category Details Line Priority
Unused field: eu.europeana.normalizer.Profile$LanguageMapping.code PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$LanguageMapping.from PERFORMANCE UUF_UNUSED_FIELD Not available Medium

eu.europeana.normalizer.Profile$MapTo

Bug Category Details Line Priority
Unread field: eu.europeana.normalizer.Profile$MapTo.key PERFORMANCE URF_UNREAD_FIELD 115 Medium
Unused field: eu.europeana.normalizer.Profile$MapTo.concatenateSuffix PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$MapTo.order PERFORMANCE UUF_UNUSED_FIELD Not available Medium

eu.europeana.normalizer.Profile$RecordAddition

Bug Category Details Line Priority
Unused field: eu.europeana.normalizer.Profile$RecordAddition.ifMissing PERFORMANCE UUF_UNUSED_FIELD Not available Medium

eu.europeana.normalizer.Profile$TypeMapping

Bug Category Details Line Priority
Unused field: eu.europeana.normalizer.Profile$TypeMapping.from PERFORMANCE UUF_UNUSED_FIELD Not available Medium
Unused field: eu.europeana.normalizer.Profile$TypeMapping.type PERFORMANCE UUF_UNUSED_FIELD Not available Medium

org.json.JSONArray

Bug Category Details Line Priority
Method new org.json.JSONArray(JSONTokener) invokes inefficient new Character(char) constructor; use Character.valueOf(char) instead PERFORMANCE DM_NUMBER_CTOR 156 Medium
Method org.json.JSONArray.put(int) invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead PERFORMANCE DM_NUMBER_CTOR 688 Medium
Method org.json.JSONArray.put(int, int) invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead PERFORMANCE DM_NUMBER_CTOR 803 Medium
Method org.json.JSONArray.put(int, long) invokes inefficient new Long(long) constructor; use Long.valueOf(long) instead PERFORMANCE DM_NUMBER_CTOR 821 Medium
Method org.json.JSONArray.put(long) invokes inefficient new Long(long) constructor; use Long.valueOf(long) instead PERFORMANCE DM_NUMBER_CTOR 701 Medium
org.json.JSONArray.toString() may return null BAD_PRACTICE NP_TOSTRING_COULD_RETURN_NULL 928 Medium

org.json.JSONObject

Bug Category Details Line Priority
instanceof will always return true in org.json.JSONObject.valueToString(Object), since all String are instances of String STYLE BC_VACUOUS_INSTANCEOF 1462 Medium
instanceof will always return true in org.json.JSONObject.valueToString(Object, int, int), since all String are instances of String STYLE BC_VACUOUS_INSTANCEOF 1520 Medium
Method org.json.JSONObject.put(String, int) invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead PERFORMANCE DM_NUMBER_CTOR 1059 Medium
Method org.json.JSONObject.put(String, long) invokes inefficient new Long(long) constructor; use Long.valueOf(long) instead PERFORMANCE DM_NUMBER_CTOR 1076 Medium
Call to equals() with null argument in org.json.JSONObject.valueToString(Object) CORRECTNESS EC_NULL_ARG 1447 Medium
Call to equals() with null argument in org.json.JSONObject.valueToString(Object, int, int) CORRECTNESS EC_NULL_ARG 1511 Medium
org.json.JSONObject.toString() may return null BAD_PRACTICE NP_TOSTRING_COULD_RETURN_NULL 1329 Medium
Exception is caught when Exception is not thrown in new org.json.JSONObject(Object) STYLE REC_CATCH_EXCEPTION 322 Medium

org.json.JSONObject$Null

Bug Category Details Line Priority
org.json.JSONObject$Null.equals(Object) is unusual STYLE EQ_UNUSUAL 126 Medium
org.json.JSONObject$Null defines equals and uses Object.hashCode() BAD_PRACTICE HE_EQUALS_USE_HASHCODE 126 Medium

org.json.JSONStringer

Bug Category Details Line Priority
org.json.JSONStringer.toString() may return null BAD_PRACTICE NP_TOSTRING_COULD_RETURN_NULL 84 Medium

org.json.JSONTokener

Bug Category Details Line Priority
Method org.json.JSONTokener.nextValue() invokes inefficient new Integer(int) constructor; use Integer.valueOf(int) instead PERFORMANCE DM_NUMBER_CTOR 429 Medium