Efficient Hill Climbers

Severity

Blocker 0
Critical 1
Major 674
Minor 618
Info 22

Rule

Switch cases should end with an unconditional "break" statement 1
Standard outputs should not be used directly to log anything 137
Local variable and method parameter names should comply with a naming convention 121
Control structures should use curly braces 63
Generic exceptions should never be thrown 43
Branches should have sufficient coverage by unit tests 42
Strings literals should be placed on the left side when checking for equality 36
Sections of code should not be "commented out" 34
Methods should not be too complex 30
Class variable fields should not have public accessibility 24
Source files should not have any duplicated blocks 24
Empty statements should be removed 10
Field names should comply with a naming convention 10
Method parameters, caught exceptions and foreach variables should not be reassigned 9
Utility classes should not have public constructors 8
Lambdas and anonymous classes should not have too many lines 8
Exception handlers should preserve the original exceptions 7
Statements should be on separate lines 7
Local variables should not shadow class fields 7
Try-catch blocks should not be nested 6
Collection.isEmpty() should be used to test for emptiness 6
Assignments should not be made from within sub-expressions 6
Useless parentheses around expressions should be removed to prevent any misunderstanding 5
Unused local variables should be removed 4
Generic wildcard types should not be used in return parameters 4
"switch case" clauses should not have too many lines 4
Close curly brace and the next "else", "catch" and "finally" keywords should be located on the same line 3
"switch" statements should end with "default" clauses 2
Collapsible "if" statements should be merged 2
Empty arrays and collections should be returned instead of null 2
Synchronized classes Vector, Hashtable, Stack and StringBuffer should not be used 2
Declarations should use Java collection interfaces such as "List" rather than specific implementation classes such as "LinkedList" 2
Loops should not contain more than a single "break" or "continue" statement 2
The default unnamed package should not be used 1
Unused method parameters should be removed 1
Only static class initializers should be used 1
Public methods should throw at most one checked exception 1
Magic numbers should not be used 432
Tabulation characters should not be used 72
Control flow statements "if", "for", "while", "switch" and "try" should not be nested too deeply 49
Useless imports should be removed 26
The members of an interface declaration or class should appear in a pre-defined order 16
Comments should not be located at the end of lines of code 11
String literals should not be duplicated 4
Array designators "[]" should be on the type, not the variable 4
Local Variables should not be declared and then immediately returned or thrown 2
Boolean literals should not be redundant 1
Overriding methods should do more than simply call the same method in the super class 1
"TODO" tags should be handled 22
  EfficientHillClimberTest.java 243
  PBSolutionTest.java 54
  PXScoresAlgorithm2Experiment.java 51
  MaxsatResultsParser.java 49
  MAXSAT.java 43
  LocalOptimaExperiment.java 36
  MAXkSAT.java 35
  Driver.java 34
  NKLandscapes.java 34
  RBallEfficientHillClimberForInstanceOf.java 34
  Driver.java 33
  WeightedGraphColoring.java 32
  NKLandscapesCircularDynProgBigDecimal.java 32
  NKLandscapesCircularDynProg.java 31
  TimeExperiment.java 30
  PartitionCrossoverWithScoresExperiment.java 29
  RBallQualityResultsKnownOptimumParser.java 26
  QualityExperiment.java 25
  NKVsMaxkSATExperiment.java 25
  MaxSATHpInitExperiment.java 25
  MaxSATExperiment.java 24
  PartitionCrossoverParser.java 24
  RBallQualityResultsTimeParser.java 23
  ExactSolutionNKExperiment.java 22
  RBallEfficientHillClimberSnapshot.java 22
  EfficientHillClimber.java 19
  NKLandscapesCircularDynProgBigDecimalTest.java 19
  RBallQualityResultsParser.java 18
  PBSolution.java 17
  ClassesDiscovery.java 17
  MinSATExperiment.java 15
  RBallEfficientHillClimber.java 11
  PartitionCrossover.java 9
  UtilityMethods.java 9
  PXParameters.java 9
  ProcessManager.java 8
  PartitionCrossoverResultsIntoLaTeX.java 8
  RBall4MAXSATSnapshot.java 7
  EmbeddedLandscape.java 7
  SetOfVars.java 7
  RBallPBMove.java 7
  RootedTreeGenerator.java 7
  GrayCodeBitFlipIterable.java 6
  SingleThreadCPUTimer.java 6
  DoubleLinkedList.java 6
  MaxNKStatistics.java 6
  AveragedSample.java 5
  CompleteEnumerationBigDecimal.java 4
  TwoStatesISArrayImplTest.java 4
  Sample.java 4
  WGCMove.java 4
  TabularData.java 3
  CompleteEnumeration.java 3
  IteratorFromArray.java 3
  TwoStatesISArrayImpl.java 3
  TinosFormatTest.java 3
  ExactSolutionMethod.java 3
  NaiveHillClimberSnapshot.java 3
  HillClimberSnapshot.java 3
  NaiveHillClimber.java 2
  TwoStatesIntegerSet.java 2
  HillClimber.java 2
  NKLandscapesTinosReader.java 2
  TwoStatesISSetImpl.java 2
  PartitionCrossoverForRBallHillClimber.java 2
  WGCSolution.java 2
  ParseResults.java 2
  RBall4MAXSATForInstanceOf.java 2
  PseudoBooleanFunction.java 2
  RBall4MAXSAT.java 2
  Seeds.java 2
  Experiments.java 2
  ExactSolutionNK.java 2
  NaiveHillClimberForInstanceOf.java 2
  HillClimberForInstanceOf.java 1
  StringFilter.java 1
  Process.java 1
  KBoundedEpistasisPBF.java 1
  Problem.java 1
  Move.java 1