PMD Results

The following document contains the results of PMD 6.21.0.

Violations By Priority

Priority 2

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU.java

Rule Violation Line
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 1466
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 1475

Priority 3

org/opentrafficsim/road/gtu/generator/AbstractGTUGeneratorOld.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 357–377
CollapsibleIfStatements These nested if statements could be combined 417–437

org/opentrafficsim/road/gtu/generator/CFRoomChecker.java

Rule Violation Line
EmptyCatchBlock Avoid empty catch blocks 54–57

org/opentrafficsim/road/gtu/generator/GeneratorPositions.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'biases'. 80
EmptyCatchBlock Avoid empty catch blocks 298–301
EmptyCatchBlock Avoid empty catch blocks 610–613
UnnecessaryModifier Unnecessary modifier 'public' on class 'ByValue': members of interface types are implicitly public 1066–1126

org/opentrafficsim/road/gtu/generator/od/StrategicalPlannerFactorySupplierOD.java

Rule Violation Line
UnnecessaryModifier Unnecessary modifier 'public' on interface 'TacticalPlannerFactorySupplierOD': members of interface types are implicitly public 106–118

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU.java

Rule Violation Line
EmptyCatchBlock Avoid empty catch blocks 1574–1577
EmptyCatchBlock Avoid empty catch blocks 1590–1593

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU2.java

Rule Violation Line
EmptyIfStmt Avoid empty if statements 592–594
EmptyCatchBlock Avoid empty catch blocks 1338–1341

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedIndividualGTU.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 52
SimplifiedTernary Ternary operators that can be simplified with || or && 96

org/opentrafficsim/road/gtu/lane/perception/AbstractPerceptionReiterable.java

Rule Violation Line
UselessQualifiedThis Useless qualified this usage in the same class. 125
UselessQualifiedThis Useless qualified this usage in the same class. 127
UselessQualifiedThis Useless qualified this usage in the same class. 128
UselessQualifiedThis Useless qualified this usage in the same class. 132
UselessQualifiedThis Useless qualified this usage in the same class. 133
UselessQualifiedThis Useless qualified this usage in the same class. 316

org/opentrafficsim/road/gtu/lane/perception/DownstreamNeighborsIterable.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 120–124

org/opentrafficsim/road/gtu/lane/perception/PerceptionCollectable.java

Rule Violation Line
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionCollector': members of interface types are implicitly public 76–95
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionAccumulator': members of interface types are implicitly public 111–121
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionFinalizer': members of interface types are implicitly public 137–145

org/opentrafficsim/road/gtu/lane/perception/RollingLaneStructureRecord.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 343–348

org/opentrafficsim/road/gtu/lane/perception/categories/DirectDefaultSimplePerception.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 749–752
CollapsibleIfStatements These nested if statements could be combined 883–900

org/opentrafficsim/road/gtu/lane/perception/categories/LaneBasedAbstractPerceptionCategory.java

Rule Violation Line
UnusedFormalParameter Avoid unused method parameters such as 'context'. 126

org/opentrafficsim/road/gtu/lane/perception/headway/HeadwayStopLine.java

Rule Violation Line
UselessOverridingMethod Overriding method merely calls super 37–40

org/opentrafficsim/road/gtu/lane/plan/operational/LaneChange.java

Rule Violation Line
UnusedFormalParameter Avoid unused method parameters such as 'planDistance'. 711
UnusedFormalParameter Avoid unused method parameters such as 'startPosition'. 712
UnusedFormalParameter Avoid unused method parameters such as 'width'. 712
UnusedFormalParameter Avoid unused method parameters such as 'from'. 712
UnusedFormalParameter Avoid unused method parameters such as 'toLine'. 713
UnusedFormalParameter Avoid unused method parameters such as 'fromLine'. 713
UnusedLocalVariable Avoid unused local variables such as 'f'. 725
UnusedLocalVariable Avoid unused local variables such as 'cumulLcLength'. 729

org/opentrafficsim/road/gtu/lane/plan/operational/LaneOperationalPlanBuilder.java

Rule Violation Line
UnusedLocalVariable Avoid unused local variables such as 'alternativeTried'. 349
UnusedFormalParameter Avoid unused method parameters such as 'startSpeed'. 555

org/opentrafficsim/road/gtu/lane/tactical/LaneBasedCFLCTacticalPlanner.java

Rule Violation Line
UnusedLocalVariable Avoid unused local variables such as 'currentLaneFine'. 151

org/opentrafficsim/road/gtu/lane/tactical/LaneBasedGTUFollowingDirectedChangeTacticalPlanner.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 238–245
UnusedFormalParameter Avoid unused method parameters such as 'perception'. 508
UnusedFormalParameter Avoid unused method parameters such as 'lanePathInfo'. 508

org/opentrafficsim/road/gtu/lane/tactical/lmrs/AccelerationBusStop.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 75–84

org/opentrafficsim/road/gtu/lane/tactical/routesystem/DefaultRouteSystem.java

Rule Violation Line
UnusedPrivateMethod Avoid unused private methods such as 'determineSet(DirectedLanePosition,Length,Route,GTUType,Length)'. 78–79
UnusedFormalParameter Avoid unused method parameters such as 'route'. 78
UnusedFormalParameter Avoid unused method parameters such as 'distance'. 79

org/opentrafficsim/road/gtu/lane/tactical/toledo/Toledo.java

Rule Violation Line
UnusedFormalParameter Avoid unused method parameters such as 'gtu'. 716

org/opentrafficsim/road/gtu/lane/tactical/util/ConflictUtil.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 188–200
CollapsibleIfStatements These nested if statements could be combined 498–514

org/opentrafficsim/road/gtu/lane/tactical/util/Steering.java

Rule Violation Line
UnusedLocalVariable Avoid unused local variables such as 'speed'. 94
UnusedLocalVariable Avoid unused local variables such as 'realPlan'. 128

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Cooperation.java

Rule Violation Line
UnusedLocalVariable Avoid unused local variables such as 'b'. 85
SimplifiedTernary Ternary operators that can be simplified with || or && 93

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/LmrsData.java

Rule Violation Line
SimplifiedTernary Ternary operators that can be simplified with || or && 110

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/LmrsUtil.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 187–204
UnusedPrivateMethod Avoid unused private methods such as 'quickIntersectionScan(Parameters,SpeedLimitInfo,CarFollowingModel,Speed,LateralDirectionality,IntersectionPerception)'. 594–596

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Synchronization.java

Rule Violation Line
TooManyStaticImports Too many static imports may lead to messy code 1–836
SimplifiedTernary Ternary operators that can be simplified with || or && 397–398
SimplifiedTernary Ternary operators that can be simplified with || or && 414–415
UnnecessaryModifier Unnecessary modifier 'public' on method 'getMergeDistance': the method is declared in an interface type 499–511

org/opentrafficsim/road/network/factory/LaneFactory.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 108
UnusedFormalParameter Avoid unused method parameters such as 'simulator'. 387

org/opentrafficsim/road/network/lane/CrossSectionElement.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'newSimulator'. 355

org/opentrafficsim/road/network/lane/Lane.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 537–541
CollapsibleIfStatements These nested if statements could be combined 577–581

org/opentrafficsim/road/network/lane/LaneType.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'inverted'. 144

org/opentrafficsim/road/network/lane/NoTrafficLane.java

Rule Violation Line
UnusedPrivateMethod Avoid unused private methods such as 'directionalityNone(RoadNetwork)'. 35

org/opentrafficsim/road/network/lane/conflict/Conflict.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 420–440
CollapsibleIfStatements These nested if statements could be combined 851–870

org/opentrafficsim/road/network/lane/conflict/ConflictBuilder.java

Rule Violation Line
CollapsibleIfStatements These nested if statements could be combined 292–295

org/opentrafficsim/road/network/lane/object/BusStop.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 62

org/opentrafficsim/road/network/lane/object/Distraction.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 41

org/opentrafficsim/road/network/lane/object/SpeedSign.java

Rule Violation Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 62

Priority 4

org/opentrafficsim/road/gtu/generator/AbstractGTUGeneratorOld.java

Rule Violation Line
UselessParentheses Useless parentheses. 288
UselessParentheses Useless parentheses. 288
UselessParentheses Useless parentheses. 289
UselessParentheses Useless parentheses. 289

org/opentrafficsim/road/gtu/generator/GeneratorPositions.java

Rule Violation Line
UselessParentheses Useless parentheses. 960
UselessParentheses Useless parentheses. 1169

org/opentrafficsim/road/gtu/generator/od/ODApplier.java

Rule Violation Line
UselessParentheses Useless parentheses. 304

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU2.java

Rule Violation Line
UselessParentheses Useless parentheses. 1087

org/opentrafficsim/road/gtu/lane/VehicleModel.java

Rule Violation Line
UselessParentheses Useless parentheses. 44

org/opentrafficsim/road/gtu/lane/perception/DownstreamNeighborsIterable.java

Rule Violation Line
UselessParentheses Useless parentheses. 102

org/opentrafficsim/road/gtu/lane/perception/RelativeLane.java

Rule Violation Line
UselessParentheses Useless parentheses. 65

org/opentrafficsim/road/gtu/lane/perception/RollingLaneStructure.java

Rule Violation Line
UselessParentheses Useless parentheses. 481
UselessParentheses Useless parentheses. 1333–1334
UselessParentheses Useless parentheses. 1334–1335
UselessParentheses Useless parentheses. 1420–1421
UselessParentheses Useless parentheses. 1421–1422
UselessParentheses Useless parentheses. 1503–1504
UselessParentheses Useless parentheses. 1504
UselessParentheses Useless parentheses. 1532–1533
UselessParentheses Useless parentheses. 1533

org/opentrafficsim/road/gtu/lane/perception/RollingLaneStructureRecord.java

Rule Violation Line
UselessParentheses Useless parentheses. 343–344
UselessParentheses Useless parentheses. 344–345

org/opentrafficsim/road/gtu/lane/perception/UpstreamNeighborsIterable.java

Rule Violation Line
UselessParentheses Useless parentheses. 75

org/opentrafficsim/road/gtu/lane/perception/categories/DirectDefaultSimplePerception.java

Rule Violation Line
UselessParentheses Useless parentheses. 952
UselessParentheses Useless parentheses. 952
UselessParentheses Useless parentheses. 953
UselessParentheses Useless parentheses. 953

org/opentrafficsim/road/gtu/lane/perception/categories/DirectInfrastructurePerception.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.road.gtu.lane.Break' 22
UselessParentheses Useless parentheses. 412–413
UselessParentheses Useless parentheses. 413
UselessParentheses Useless parentheses. 428
UselessParentheses Useless parentheses. 428
UselessParentheses Useless parentheses. 441
UselessParentheses Useless parentheses. 441
UselessParentheses Useless parentheses. 444
UselessParentheses Useless parentheses. 444–445
UselessParentheses Useless parentheses. 455
UselessParentheses Useless parentheses. 455–456
UselessParentheses Useless parentheses. 655
UselessParentheses Useless parentheses. 655–656

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/DirectNeighborsPerception.java

Rule Violation Line
UselessParentheses Useless parentheses. 273–274
UselessParentheses Useless parentheses. 275–276

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/HeadwayGtuType.java

Rule Violation Line
UselessParentheses Useless parentheses. 211

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/TaskHeadwayCollector.java

Rule Violation Line
UselessParentheses Useless parentheses. 81

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationHeadway.java

Rule Violation Line
UselessParentheses Useless parentheses. 46

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationSituationalAwareness.java

Rule Violation Line
UselessParentheses Useless parentheses. 88

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationSpeed.java

Rule Violation Line
UselessParentheses Useless parentheses. 41

org/opentrafficsim/road/gtu/lane/perception/mental/Fuller.java

Rule Violation Line
UselessParentheses Useless parentheses. 180

org/opentrafficsim/road/gtu/lane/perception/mental/TaskHeadwayBased.java

Rule Violation Line
UselessParentheses Useless parentheses. 56

org/opentrafficsim/road/gtu/lane/plan/operational/LaneChange.java

Rule Violation Line
UselessParentheses Useless parentheses. 640
UselessParentheses Useless parentheses. 826

org/opentrafficsim/road/gtu/lane/plan/operational/LaneOperationalPlanBuilder.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.core.gtu.GTUDirectionality' 25
UnusedImports Avoid unused imports such as 'org.opentrafficsim.core.gtu.RelativePosition' 27
UselessParentheses Useless parentheses. 495

org/opentrafficsim/road/gtu/lane/tactical/LaneBasedGTUFollowingDirectedChangeTacticalPlanner.java

Rule Violation Line
UselessParentheses Useless parentheses. 236
UselessParentheses Useless parentheses. 266
UselessParentheses Useless parentheses. 629

org/opentrafficsim/road/gtu/lane/tactical/lmrs/IncentiveGetInLane.java

Rule Violation Line
UselessParentheses Useless parentheses. 90

org/opentrafficsim/road/gtu/lane/tactical/toledo/Toledo.java

Rule Violation Line
UselessParentheses Useless parentheses. 162
UselessParentheses Useless parentheses. 163–164

org/opentrafficsim/road/gtu/lane/tactical/util/ConflictUtil.java

Rule Violation Line
UselessParentheses Useless parentheses. 849–850

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Cooperation.java

Rule Violation Line
UselessParentheses Useless parentheses. 43
UselessParentheses Useless parentheses. 44
UselessParentheses Useless parentheses. 79
UselessParentheses Useless parentheses. 80
UselessParentheses Useless parentheses. 124
UselessParentheses Useless parentheses. 125

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/LmrsUtil.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.road.gtu.lane.Break' 24

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Synchronization.java

Rule Violation Line
UselessParentheses Useless parentheses. 350
UselessParentheses Useless parentheses. 401–402
UselessParentheses Useless parentheses. 426
UselessParentheses Useless parentheses. 736
UselessParentheses Useless parentheses. 736

org/opentrafficsim/road/gtu/strategical/od/SplitFraction.java

Rule Violation Line
UselessParentheses Useless parentheses. 199
UselessParentheses Useless parentheses. 200

org/opentrafficsim/road/gtu/strategical/route/LaneBasedStrategicalRoutePlanner.java

Rule Violation Line
UselessParentheses Useless parentheses. 164
UselessParentheses Useless parentheses. 164
UselessParentheses Useless parentheses. 234
UselessParentheses Useless parentheses. 234–235
UselessParentheses Useless parentheses. 250–251
UselessParentheses Useless parentheses. 251–252

org/opentrafficsim/road/gtu/strategical/route/RouteGeneratorOD.java

Rule Violation Line
UselessParentheses Useless parentheses. 128

org/opentrafficsim/road/network/control/rampmetering/AlineaSwitch.java

Rule Violation Line
UselessParentheses Useless parentheses. 60

org/opentrafficsim/road/network/control/rampmetering/RwsSwitch.java

Rule Violation Line
UselessParentheses Useless parentheses. 63

org/opentrafficsim/road/network/lane/CrossSectionElement.java

Rule Violation Line
UselessParentheses Useless parentheses. 271
UselessParentheses Useless parentheses. 272
UselessParentheses Useless parentheses. 272

org/opentrafficsim/road/network/lane/Lane.java

Rule Violation Line
UnusedImports Avoid unused imports such as 'org.djutils.metadata.MetaData' 29
UnusedImports Avoid unused imports such as 'org.djutils.metadata.ObjectDescriptor' 30
UselessParentheses Useless parentheses. 532–533
UselessParentheses Useless parentheses. 534–535
UselessParentheses Useless parentheses. 572–573
UselessParentheses Useless parentheses. 574–575
UselessParentheses Useless parentheses. 1514
UselessParentheses Useless parentheses. 1515
UselessParentheses Useless parentheses. 1542
UselessParentheses Useless parentheses. 1543

org/opentrafficsim/road/network/lane/conflict/Conflict.java

Rule Violation Line
UselessParentheses Useless parentheses. 188
UselessParentheses Useless parentheses. 189

org/opentrafficsim/road/network/lane/conflict/ConflictBuilder.java

Rule Violation Line
UselessParentheses Useless parentheses. 300
UselessParentheses Useless parentheses. 468
UselessParentheses Useless parentheses. 469
UselessParentheses Useless parentheses. 619
UselessParentheses Useless parentheses. 619
UselessParentheses Useless parentheses. 627
UselessParentheses Useless parentheses. 627

org/opentrafficsim/road/network/lane/conflict/ConflictBuilderParallel.java

Rule Violation Line
UselessParentheses Useless parentheses. 726
UselessParentheses Useless parentheses. 727
UselessParentheses Useless parentheses. 876
UselessParentheses Useless parentheses. 876
UselessParentheses Useless parentheses. 884
UselessParentheses Useless parentheses. 884

org/opentrafficsim/road/network/lane/conflict/DefaultConflictRule.java

Rule Violation Line
UselessParentheses Useless parentheses. 111
UselessParentheses Useless parentheses. 112

Files

org/opentrafficsim/road/gtu/generator/AbstractGTUGeneratorOld.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 288
UselessParentheses Useless parentheses. 4 288
UselessParentheses Useless parentheses. 4 289
UselessParentheses Useless parentheses. 4 289
CollapsibleIfStatements These nested if statements could be combined 3 357–377
CollapsibleIfStatements These nested if statements could be combined 3 417–437

org/opentrafficsim/road/gtu/generator/CFRoomChecker.java

Rule Violation Priority Line
EmptyCatchBlock Avoid empty catch blocks 3 54–57

org/opentrafficsim/road/gtu/generator/GeneratorPositions.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'biases'. 3 80
EmptyCatchBlock Avoid empty catch blocks 3 298–301
EmptyCatchBlock Avoid empty catch blocks 3 610–613
UselessParentheses Useless parentheses. 4 960
UnnecessaryModifier Unnecessary modifier 'public' on class 'ByValue': members of interface types are implicitly public 3 1066–1126
UselessParentheses Useless parentheses. 4 1169

org/opentrafficsim/road/gtu/generator/od/ODApplier.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 304

org/opentrafficsim/road/gtu/generator/od/StrategicalPlannerFactorySupplierOD.java

Rule Violation Priority Line
UnnecessaryModifier Unnecessary modifier 'public' on interface 'TacticalPlannerFactorySupplierOD': members of interface types are implicitly public 3 106–118

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU.java

Rule Violation Priority Line
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 2 1466
BooleanInstantiation Avoid instantiating Boolean objects; reference Boolean.TRUE or Boolean.FALSE or call Boolean.valueOf() instead. 2 1475
EmptyCatchBlock Avoid empty catch blocks 3 1574–1577
EmptyCatchBlock Avoid empty catch blocks 3 1590–1593

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedGTU2.java

Rule Violation Priority Line
EmptyIfStmt Avoid empty if statements 3 592–594
UselessParentheses Useless parentheses. 4 1087
EmptyCatchBlock Avoid empty catch blocks 3 1338–1341

org/opentrafficsim/road/gtu/lane/AbstractLaneBasedIndividualGTU.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 3 52
SimplifiedTernary Ternary operators that can be simplified with || or && 3 96

org/opentrafficsim/road/gtu/lane/VehicleModel.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 44

org/opentrafficsim/road/gtu/lane/perception/AbstractPerceptionReiterable.java

Rule Violation Priority Line
UselessQualifiedThis Useless qualified this usage in the same class. 3 125
UselessQualifiedThis Useless qualified this usage in the same class. 3 127
UselessQualifiedThis Useless qualified this usage in the same class. 3 128
UselessQualifiedThis Useless qualified this usage in the same class. 3 132
UselessQualifiedThis Useless qualified this usage in the same class. 3 133
UselessQualifiedThis Useless qualified this usage in the same class. 3 316

org/opentrafficsim/road/gtu/lane/perception/DownstreamNeighborsIterable.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 102
CollapsibleIfStatements These nested if statements could be combined 3 120–124

org/opentrafficsim/road/gtu/lane/perception/PerceptionCollectable.java

Rule Violation Priority Line
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionCollector': members of interface types are implicitly public 3 76–95
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionAccumulator': members of interface types are implicitly public 3 111–121
UnnecessaryModifier Unnecessary modifier 'public' on interface 'PerceptionFinalizer': members of interface types are implicitly public 3 137–145

org/opentrafficsim/road/gtu/lane/perception/RelativeLane.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 65

org/opentrafficsim/road/gtu/lane/perception/RollingLaneStructure.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 481
UselessParentheses Useless parentheses. 4 1333–1334
UselessParentheses Useless parentheses. 4 1334–1335
UselessParentheses Useless parentheses. 4 1420–1421
UselessParentheses Useless parentheses. 4 1421–1422
UselessParentheses Useless parentheses. 4 1503–1504
UselessParentheses Useless parentheses. 4 1504
UselessParentheses Useless parentheses. 4 1532–1533
UselessParentheses Useless parentheses. 4 1533

org/opentrafficsim/road/gtu/lane/perception/RollingLaneStructureRecord.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 343–344
CollapsibleIfStatements These nested if statements could be combined 3 343–348
UselessParentheses Useless parentheses. 4 344–345

org/opentrafficsim/road/gtu/lane/perception/UpstreamNeighborsIterable.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 75

org/opentrafficsim/road/gtu/lane/perception/categories/DirectDefaultSimplePerception.java

Rule Violation Priority Line
CollapsibleIfStatements These nested if statements could be combined 3 749–752
CollapsibleIfStatements These nested if statements could be combined 3 883–900
UselessParentheses Useless parentheses. 4 952
UselessParentheses Useless parentheses. 4 952
UselessParentheses Useless parentheses. 4 953
UselessParentheses Useless parentheses. 4 953

org/opentrafficsim/road/gtu/lane/perception/categories/DirectInfrastructurePerception.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.road.gtu.lane.Break' 4 22
UselessParentheses Useless parentheses. 4 412–413
UselessParentheses Useless parentheses. 4 413
UselessParentheses Useless parentheses. 4 428
UselessParentheses Useless parentheses. 4 428
UselessParentheses Useless parentheses. 4 441
UselessParentheses Useless parentheses. 4 441
UselessParentheses Useless parentheses. 4 444
UselessParentheses Useless parentheses. 4 444–445
UselessParentheses Useless parentheses. 4 455
UselessParentheses Useless parentheses. 4 455–456
UselessParentheses Useless parentheses. 4 655
UselessParentheses Useless parentheses. 4 655–656

org/opentrafficsim/road/gtu/lane/perception/categories/LaneBasedAbstractPerceptionCategory.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused method parameters such as 'context'. 3 126

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/DirectNeighborsPerception.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 273–274
UselessParentheses Useless parentheses. 4 275–276

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/HeadwayGtuType.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 211

org/opentrafficsim/road/gtu/lane/perception/categories/neighbors/TaskHeadwayCollector.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 81

org/opentrafficsim/road/gtu/lane/perception/headway/HeadwayStopLine.java

Rule Violation Priority Line
UselessOverridingMethod Overriding method merely calls super 3 37–40

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationHeadway.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 46

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationSituationalAwareness.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 88

org/opentrafficsim/road/gtu/lane/perception/mental/AdaptationSpeed.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 41

org/opentrafficsim/road/gtu/lane/perception/mental/Fuller.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 180

org/opentrafficsim/road/gtu/lane/perception/mental/TaskHeadwayBased.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 56

org/opentrafficsim/road/gtu/lane/plan/operational/LaneChange.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 640
UnusedFormalParameter Avoid unused method parameters such as 'planDistance'. 3 711
UnusedFormalParameter Avoid unused method parameters such as 'startPosition'. 3 712
UnusedFormalParameter Avoid unused method parameters such as 'width'. 3 712
UnusedFormalParameter Avoid unused method parameters such as 'from'. 3 712
UnusedFormalParameter Avoid unused method parameters such as 'toLine'. 3 713
UnusedFormalParameter Avoid unused method parameters such as 'fromLine'. 3 713
UnusedLocalVariable Avoid unused local variables such as 'f'. 3 725
UnusedLocalVariable Avoid unused local variables such as 'cumulLcLength'. 3 729
UselessParentheses Useless parentheses. 4 826

org/opentrafficsim/road/gtu/lane/plan/operational/LaneOperationalPlanBuilder.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.core.gtu.GTUDirectionality' 4 25
UnusedImports Avoid unused imports such as 'org.opentrafficsim.core.gtu.RelativePosition' 4 27
UnusedLocalVariable Avoid unused local variables such as 'alternativeTried'. 3 349
UselessParentheses Useless parentheses. 4 495
UnusedFormalParameter Avoid unused method parameters such as 'startSpeed'. 3 555

org/opentrafficsim/road/gtu/lane/tactical/LaneBasedCFLCTacticalPlanner.java

Rule Violation Priority Line
UnusedLocalVariable Avoid unused local variables such as 'currentLaneFine'. 3 151

org/opentrafficsim/road/gtu/lane/tactical/LaneBasedGTUFollowingDirectedChangeTacticalPlanner.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 236
CollapsibleIfStatements These nested if statements could be combined 3 238–245
UselessParentheses Useless parentheses. 4 266
UnusedFormalParameter Avoid unused method parameters such as 'perception'. 3 508
UnusedFormalParameter Avoid unused method parameters such as 'lanePathInfo'. 3 508
UselessParentheses Useless parentheses. 4 629

org/opentrafficsim/road/gtu/lane/tactical/lmrs/AccelerationBusStop.java

Rule Violation Priority Line
CollapsibleIfStatements These nested if statements could be combined 3 75–84

org/opentrafficsim/road/gtu/lane/tactical/lmrs/IncentiveGetInLane.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 90

org/opentrafficsim/road/gtu/lane/tactical/routesystem/DefaultRouteSystem.java

Rule Violation Priority Line
UnusedPrivateMethod Avoid unused private methods such as 'determineSet(DirectedLanePosition,Length,Route,GTUType,Length)'. 3 78–79
UnusedFormalParameter Avoid unused method parameters such as 'route'. 3 78
UnusedFormalParameter Avoid unused method parameters such as 'distance'. 3 79

org/opentrafficsim/road/gtu/lane/tactical/toledo/Toledo.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 162
UselessParentheses Useless parentheses. 4 163–164
UnusedFormalParameter Avoid unused method parameters such as 'gtu'. 3 716

org/opentrafficsim/road/gtu/lane/tactical/util/ConflictUtil.java

Rule Violation Priority Line
CollapsibleIfStatements These nested if statements could be combined 3 188–200
CollapsibleIfStatements These nested if statements could be combined 3 498–514
UselessParentheses Useless parentheses. 4 849–850

org/opentrafficsim/road/gtu/lane/tactical/util/Steering.java

Rule Violation Priority Line
UnusedLocalVariable Avoid unused local variables such as 'speed'. 3 94
UnusedLocalVariable Avoid unused local variables such as 'realPlan'. 3 128

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Cooperation.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 43
UselessParentheses Useless parentheses. 4 44
UselessParentheses Useless parentheses. 4 79
UselessParentheses Useless parentheses. 4 80
UnusedLocalVariable Avoid unused local variables such as 'b'. 3 85
SimplifiedTernary Ternary operators that can be simplified with || or && 3 93
UselessParentheses Useless parentheses. 4 124
UselessParentheses Useless parentheses. 4 125

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/LmrsData.java

Rule Violation Priority Line
SimplifiedTernary Ternary operators that can be simplified with || or && 3 110

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/LmrsUtil.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'org.opentrafficsim.road.gtu.lane.Break' 4 24
CollapsibleIfStatements These nested if statements could be combined 3 187–204
UnusedPrivateMethod Avoid unused private methods such as 'quickIntersectionScan(Parameters,SpeedLimitInfo,CarFollowingModel,Speed,LateralDirectionality,IntersectionPerception)'. 3 594–596

org/opentrafficsim/road/gtu/lane/tactical/util/lmrs/Synchronization.java

Rule Violation Priority Line
TooManyStaticImports Too many static imports may lead to messy code 3 1–836
UselessParentheses Useless parentheses. 4 350
SimplifiedTernary Ternary operators that can be simplified with || or && 3 397–398
UselessParentheses Useless parentheses. 4 401–402
SimplifiedTernary Ternary operators that can be simplified with || or && 3 414–415
UselessParentheses Useless parentheses. 4 426
UnnecessaryModifier Unnecessary modifier 'public' on method 'getMergeDistance': the method is declared in an interface type 3 499–511
UselessParentheses Useless parentheses. 4 736
UselessParentheses Useless parentheses. 4 736

org/opentrafficsim/road/gtu/strategical/od/SplitFraction.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 199
UselessParentheses Useless parentheses. 4 200

org/opentrafficsim/road/gtu/strategical/route/LaneBasedStrategicalRoutePlanner.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 164
UselessParentheses Useless parentheses. 4 164
UselessParentheses Useless parentheses. 4 234
UselessParentheses Useless parentheses. 4 234–235
UselessParentheses Useless parentheses. 4 250–251
UselessParentheses Useless parentheses. 4 251–252

org/opentrafficsim/road/gtu/strategical/route/RouteGeneratorOD.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 128

org/opentrafficsim/road/network/control/rampmetering/AlineaSwitch.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 60

org/opentrafficsim/road/network/control/rampmetering/RwsSwitch.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 63

org/opentrafficsim/road/network/factory/LaneFactory.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 3 108
UnusedFormalParameter Avoid unused method parameters such as 'simulator'. 3 387

org/opentrafficsim/road/network/lane/CrossSectionElement.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 271
UselessParentheses Useless parentheses. 4 272
UselessParentheses Useless parentheses. 4 272
UnusedFormalParameter Avoid unused constructor parameters such as 'newSimulator'. 3 355

org/opentrafficsim/road/network/lane/Lane.java

Rule Violation Priority Line
UnusedImports Avoid unused imports such as 'org.djutils.metadata.MetaData' 4 29
UnusedImports Avoid unused imports such as 'org.djutils.metadata.ObjectDescriptor' 4 30
UselessParentheses Useless parentheses. 4 532–533
UselessParentheses Useless parentheses. 4 534–535
CollapsibleIfStatements These nested if statements could be combined 3 537–541
UselessParentheses Useless parentheses. 4 572–573
UselessParentheses Useless parentheses. 4 574–575
CollapsibleIfStatements These nested if statements could be combined 3 577–581
UselessParentheses Useless parentheses. 4 1514
UselessParentheses Useless parentheses. 4 1515
UselessParentheses Useless parentheses. 4 1542
UselessParentheses Useless parentheses. 4 1543

org/opentrafficsim/road/network/lane/LaneType.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'inverted'. 3 144

org/opentrafficsim/road/network/lane/NoTrafficLane.java

Rule Violation Priority Line
UnusedPrivateMethod Avoid unused private methods such as 'directionalityNone(RoadNetwork)'. 3 35

org/opentrafficsim/road/network/lane/conflict/Conflict.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 188
UselessParentheses Useless parentheses. 4 189
CollapsibleIfStatements These nested if statements could be combined 3 420–440
CollapsibleIfStatements These nested if statements could be combined 3 851–870

org/opentrafficsim/road/network/lane/conflict/ConflictBuilder.java

Rule Violation Priority Line
CollapsibleIfStatements These nested if statements could be combined 3 292–295
UselessParentheses Useless parentheses. 4 300
UselessParentheses Useless parentheses. 4 468
UselessParentheses Useless parentheses. 4 469
UselessParentheses Useless parentheses. 4 619
UselessParentheses Useless parentheses. 4 619
UselessParentheses Useless parentheses. 4 627
UselessParentheses Useless parentheses. 4 627

org/opentrafficsim/road/network/lane/conflict/ConflictBuilderParallel.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 726
UselessParentheses Useless parentheses. 4 727
UselessParentheses Useless parentheses. 4 876
UselessParentheses Useless parentheses. 4 876
UselessParentheses Useless parentheses. 4 884
UselessParentheses Useless parentheses. 4 884

org/opentrafficsim/road/network/lane/conflict/DefaultConflictRule.java

Rule Violation Priority Line
UselessParentheses Useless parentheses. 4 111
UselessParentheses Useless parentheses. 4 112

org/opentrafficsim/road/network/lane/object/BusStop.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 3 62

org/opentrafficsim/road/network/lane/object/Distraction.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 3 41

org/opentrafficsim/road/network/lane/object/SpeedSign.java

Rule Violation Priority Line
UnusedFormalParameter Avoid unused constructor parameters such as 'simulator'. 3 62