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
  RBall4MAXSATSnapshot.java 1
  Seeds.java 1
  WGCMove.java 1
  PartitionCrossoverParser.java 1
  TwoStatesISArrayImplTest.java 1
  PBSolution.java 1
  MAXSAT.java 1
  LocalOptimaExperiment.java 1
  AveragedSample.java 1
  PartitionCrossoverWithScoresExperiment.java 1
  DoubleLinkedList.java 1
  Problem.java 1
  MaxNKStatistics.java 1
  KBoundedEpistasisPBF.java 1
  NKLandscapesCircularDynProgBigDecimal.java 1
  PartitionCrossoverForRBallHillClimber.java 1
  PXScoresAlgorithm2Experiment.java 1
  ClassesDiscovery.java 1
  Move.java 1
  RBall4MAXSATForInstanceOf.java 1
  RootedTreeGenerator.java 1
  NaiveHillClimberSnapshot.java 1
  MaxsatResultsParser.java 1
  PBSolutionTest.java 1
  NKVsMaxkSATExperiment.java 1
  TabularData.java 1
  HillClimberSnapshot.java 1
  RBall4MAXSAT.java 1
  ProcessManager.java 1
  NaiveHillClimberForInstanceOf.java 1
  RBallPBMove.java 1
  NKLandscapesCircularDynProgBigDecimalTest.java 1
  Experiments.java 1
  EmbeddedLandscape.java 1
  NKLandscapesCircularDynProg.java 1
  PartitionCrossover.java 1
  Process.java 1
  NaiveHillClimber.java 1
  RBallEfficientHillClimberSnapshot.java 1
  TwoStatesIntegerSet.java 1
  Driver.java 1
  RBallQualityResultsTimeParser.java 1
  CompleteEnumerationBigDecimal.java 1
  PseudoBooleanFunction.java 1
  MinSATExperiment.java 1
  StringFilter.java 1
  HillClimberForInstanceOf.java 1
  UtilityMethods.java 1
  RBallQualityResultsParser.java 1
  CompleteEnumeration.java 1
  NKLandscapes.java 1
  MaxSATHpInitExperiment.java 1
  SetOfVars.java 1
  HillClimber.java 1
  TimeExperiment.java 1
  IteratorFromArray.java 1
  EfficientHillClimber.java 1
  RBallEfficientHillClimberForInstanceOf.java 1
  TwoStatesISSetImpl.java 1
  WeightedGraphColoring.java 1
  Sample.java 1
  ExactSolutionMethod.java 1
  QualityExperiment.java 1
  GrayCodeBitFlipIterable.java 1
  Driver.java 1
  RBallEfficientHillClimber.java 1
  TwoStatesISArrayImpl.java 1
  WGCSolution.java 1
  RBallQualityResultsKnownOptimumParser.java 1
  ParseResults.java 1
  MAXkSAT.java 1
  MaxSATExperiment.java 1