SpotBugs Bug Detector Report

The following document contains the results of SpotBugs

SpotBugs Version is 4.7.1

Threshold is medium

Effort is default

Summary

Classes Bugs Errors Missing Classes
84 51 0 0

Files

Class Bugs
nl.tudelft.simulation.dsol.demo.visualization.VisualizationDemo 1
nl.tudelft.simulation.dsol.tutorial.mm1.MM1Application 1
nl.tudelft.simulation.dsol.tutorial.mm1.MM1ExperimentApplication 2
nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplication 1
nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplicationEvents 1
nl.tudelft.simulation.dsol.tutorial.section25.Customer 1
nl.tudelft.simulation.dsol.tutorial.section25.CustomerOrderApp 1
nl.tudelft.simulation.dsol.tutorial.section42.Customer 1
nl.tudelft.simulation.dsol.tutorial.section42.Retailer 4
nl.tudelft.simulation.dsol.tutorial.section42.Warehouse 1
nl.tudelft.simulation.dsol.tutorial.section42.policies.StationaryPolicy 1
nl.tudelft.simulation.dsol.tutorial.section43.PredatorPreyModel 1
nl.tudelft.simulation.examples.dsol.animation.BallAnimation 1
nl.tudelft.simulation.examples.dsol.animation.BallModel 1
nl.tudelft.simulation.examples.dsol.animation.BallSwingApplication$1 1
nl.tudelft.simulation.examples.dsol.animation.DiscreteBall 1
nl.tudelft.simulation.examples.dsol.animation.continuous.Ball 2
nl.tudelft.simulation.examples.dsol.animation.gis.EsriCsvSwingApplication$EmptyModel 1
nl.tudelft.simulation.examples.dsol.animation.gis.EsriXmlSwingApplication$EmptyModel 1
nl.tudelft.simulation.examples.dsol.animation.gis.OsmSwingApplication$EmptyModel 2
nl.tudelft.simulation.examples.dsol.dess.DESSModel 1
nl.tudelft.simulation.examples.dsol.mm1queue.MM1QueueModel 1
nl.tudelft.simulation.examples.dsol.mm1queue.Release 1
nl.tudelft.simulation.examples.dsol.mm1queue.Seize 1
nl.tudelft.simulation.examples.dsol.terminal.AGV 1
nl.tudelft.simulation.examples.dsol.terminal.ConsoleRunnerTerminal 3
nl.tudelft.simulation.examples.dsol.terminal.Container 5
nl.tudelft.simulation.examples.dsol.terminal.ExperimentRunnerTerminal 2
nl.tudelft.simulation.examples.dsol.terminal.IntResource 3
nl.tudelft.simulation.examples.dsol.terminal.QC 1
nl.tudelft.simulation.examples.dsol.terminal.Terminal 1
nl.tudelft.simulation.examples.dsol.timesharedcomputer.CPU 1
nl.tudelft.simulation.examples.dsol.timesharedcomputer.Job 2
nl.tudelft.simulation.examples.dsol.timesharedcomputer.Terminal 2

nl.tudelft.simulation.dsol.demo.visualization.VisualizationDemo

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.demo.visualization.VisualizationDemo() invokes nl.tudelft.simulation.dsol.demo.visualization.VisualizationDemo$DrawObjectsThread.start() MT_CORRECTNESS SC_START_IN_CTOR 64 Medium

nl.tudelft.simulation.dsol.tutorial.mm1.MM1Application

Bug Category Details Line Priority
nl.tudelft.simulation.dsol.tutorial.mm1.MM1Application.terminate() invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 56 Medium

nl.tudelft.simulation.dsol.tutorial.mm1.MM1ExperimentApplication

Bug Category Details Line Priority
nl.tudelft.simulation.dsol.tutorial.mm1.MM1ExperimentApplication.reportFinalStatistics() invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 112 Medium
nl.tudelft.simulation.dsol.tutorial.mm1.MM1ExperimentApplication.reportFinalStatistics() makes inefficient use of keySet iterator instead of entrySet iterator PERFORMANCE WMI_WRONG_MAP_ITERATOR 103 Medium

nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplication

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplication(MM1Panel, MM1Model, DevsSimulator) may expose internal representation by storing an externally mutable object into MM1SwingApplication.model MALICIOUS_CODE EI_EXPOSE_REP2 43 Medium

nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplicationEvents

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.mm1.MM1SwingApplicationEvents(MM1Panel, MM1Model, DevsSimulator) may expose internal representation by storing an externally mutable object into MM1SwingApplicationEvents.model MALICIOUS_CODE EI_EXPOSE_REP2 50 Medium

nl.tudelft.simulation.dsol.tutorial.section25.Customer

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.section25.Customer(DevsSimulatorInterface) may expose internal representation by storing an externally mutable object into Customer.simulator MALICIOUS_CODE EI_EXPOSE_REP2 30 Medium

nl.tudelft.simulation.dsol.tutorial.section25.CustomerOrderApp

Bug Category Details Line Priority
nl.tudelft.simulation.dsol.tutorial.section25.CustomerOrderApp.notify(Event) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 50 Medium

nl.tudelft.simulation.dsol.tutorial.section42.Customer

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.section42.Customer(DevsSimulatorInterface, SellerInterface) may expose internal representation by storing an externally mutable object into Customer.simulator MALICIOUS_CODE EI_EXPOSE_REP2 48 Medium

nl.tudelft.simulation.dsol.tutorial.section42.Retailer

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.section42.Retailer(DevsSimulatorInterface, SellerInterface) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 87 Medium
new nl.tudelft.simulation.dsol.tutorial.section42.Retailer(DevsSimulatorInterface, SellerInterface) may expose internal representation by storing an externally mutable object into Retailer.simulator MALICIOUS_CODE EI_EXPOSE_REP2 73 Medium
Class nl.tudelft.simulation.dsol.tutorial.section42.Retailer defines non-transient non-serializable instance field orderingPolicy BAD_PRACTICE SE_BAD_FIELD Not available Medium
nl.tudelft.simulation.dsol.tutorial.section42.policies.StationaryPolicy stored into non-transient field Retailer.orderingPolicy BAD_PRACTICE SE_BAD_FIELD_STORE 75 Medium

nl.tudelft.simulation.dsol.tutorial.section42.Warehouse

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.section42.Warehouse(DevsSimulatorInterface) may expose internal representation by storing an externally mutable object into Warehouse.simulator MALICIOUS_CODE EI_EXPOSE_REP2 35 Medium

nl.tudelft.simulation.dsol.tutorial.section42.policies.StationaryPolicy

Bug Category Details Line Priority
new nl.tudelft.simulation.dsol.tutorial.section42.policies.StationaryPolicy(SimulatorInterface) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 42 Medium

nl.tudelft.simulation.dsol.tutorial.section43.PredatorPreyModel

Bug Category Details Line Priority
nl.tudelft.simulation.dsol.tutorial.section43.PredatorPreyModel.getChart() may expose internal representation by returning PredatorPreyModel.chart MALICIOUS_CODE EI_EXPOSE_REP 88 Medium

nl.tudelft.simulation.examples.dsol.animation.BallAnimation

Bug Category Details Line Priority
Check for oddness that won't work for negative numbers in new nl.tudelft.simulation.examples.dsol.animation.BallAnimation(Ball, SimulatorInterface) STYLE IM_BAD_CHECK_FOR_ODD 50 Medium

nl.tudelft.simulation.examples.dsol.animation.BallModel

Bug Category Details Line Priority
Class nl.tudelft.simulation.examples.dsol.animation.BallModel defines non-transient non-serializable instance field ballList BAD_PRACTICE SE_BAD_FIELD Not available Medium

nl.tudelft.simulation.examples.dsol.animation.BallSwingApplication$1

Bug Category Details Line Priority
Boxing/unboxing to parse a primitive nl.tudelft.simulation.examples.dsol.animation.BallSwingApplication$1.searchObject(String) PERFORMANCE DM_BOXED_PRIMITIVE_FOR_PARSING 60 High

nl.tudelft.simulation.examples.dsol.animation.DiscreteBall

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.animation.DiscreteBall(int, DevsSimulatorInterface) may expose internal representation by storing an externally mutable object into DiscreteBall.simulator MALICIOUS_CODE EI_EXPOSE_REP2 55 Medium

nl.tudelft.simulation.examples.dsol.animation.continuous.Ball

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.animation.continuous.Ball(int, DessSimulatorInterface) may expose internal representation by storing an externally mutable object into Ball.simulator MALICIOUS_CODE EI_EXPOSE_REP2 49 Medium
The class name nl.tudelft.simulation.examples.dsol.animation.continuous.Ball shadows the simple name of the superclass nl.tudelft.simulation.examples.dsol.animation.Ball BAD_PRACTICE NM_SAME_SIMPLE_NAME_AS_SUPERCLASS 22-87 High

nl.tudelft.simulation.examples.dsol.animation.gis.EsriCsvSwingApplication$EmptyModel

Bug Category Details Line Priority
Hard coded reference to an absolute pathname in nl.tudelft.simulation.examples.dsol.animation.gis.EsriCsvSwingApplication$EmptyModel.constructModel() STYLE DMI_HARDCODED_ABSOLUTE_FILENAME 104 Medium

nl.tudelft.simulation.examples.dsol.animation.gis.EsriXmlSwingApplication$EmptyModel

Bug Category Details Line Priority
Hard coded reference to an absolute pathname in nl.tudelft.simulation.examples.dsol.animation.gis.EsriXmlSwingApplication$EmptyModel.constructModel() STYLE DMI_HARDCODED_ABSOLUTE_FILENAME 104 Medium

nl.tudelft.simulation.examples.dsol.animation.gis.OsmSwingApplication$EmptyModel

Bug Category Details Line Priority
Hard coded reference to an absolute pathname in nl.tudelft.simulation.examples.dsol.animation.gis.OsmSwingApplication$EmptyModel.constructModel() STYLE DMI_HARDCODED_ABSOLUTE_FILENAME 104 Medium
Hard coded reference to an absolute pathname in nl.tudelft.simulation.examples.dsol.animation.gis.OsmSwingApplication$EmptyModel.constructModel() STYLE DMI_HARDCODED_ABSOLUTE_FILENAME 106 Medium

nl.tudelft.simulation.examples.dsol.dess.DESSModel

Bug Category Details Line Priority
nl.tudelft.simulation.examples.dsol.dess.DESSModel.getDistanceChart() may expose internal representation by returning DESSModel.distanceChart MALICIOUS_CODE EI_EXPOSE_REP 60 Medium

nl.tudelft.simulation.examples.dsol.mm1queue.MM1QueueModel

Bug Category Details Line Priority
Exception is caught when Exception is not thrown in nl.tudelft.simulation.examples.dsol.mm1queue.MM1QueueModel.constructModel() STYLE REC_CATCH_EXCEPTION 130 Medium

nl.tudelft.simulation.examples.dsol.mm1queue.Release

Bug Category Details Line Priority
The class name nl.tudelft.simulation.examples.dsol.mm1queue.Release shadows the simple name of the superclass nl.tudelft.simulation.dsol.formalisms.flow.Release BAD_PRACTICE NM_SAME_SIMPLE_NAME_AS_SUPERCLASS 25-64 High

nl.tudelft.simulation.examples.dsol.mm1queue.Seize

Bug Category Details Line Priority
The class name nl.tudelft.simulation.examples.dsol.mm1queue.Seize shadows the simple name of the superclass nl.tudelft.simulation.dsol.formalisms.flow.Seize BAD_PRACTICE NM_SAME_SIMPLE_NAME_AS_SUPERCLASS 33-56 High

nl.tudelft.simulation.examples.dsol.terminal.AGV

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.terminal.AGV(DevsSimulatorInterface, String, long, DistContinuous) may expose internal representation by storing an externally mutable object into AGV.agvTime MALICIOUS_CODE EI_EXPOSE_REP2 36 Medium

nl.tudelft.simulation.examples.dsol.terminal.ConsoleRunnerTerminal

Bug Category Details Line Priority
Dead store to seed in new nl.tudelft.simulation.examples.dsol.terminal.ConsoleRunnerTerminal() STYLE DLS_DEAD_LOCAL_STORE 52 Medium
nl.tudelft.simulation.examples.dsol.terminal.ConsoleRunnerTerminal.notify(Event) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 87 Medium
nl.tudelft.simulation.examples.dsol.terminal.ConsoleRunnerTerminal.terminate(DevsSimulator, int, int, int) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 75 Medium

nl.tudelft.simulation.examples.dsol.terminal.Container

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.terminal.Container(DevsSimulatorInterface, int, QC, AGV, Ship) may expose internal representation by storing an externally mutable object into Container.agv MALICIOUS_CODE EI_EXPOSE_REP2 53 Medium
new nl.tudelft.simulation.examples.dsol.terminal.Container(DevsSimulatorInterface, int, QC, AGV, Ship) may expose internal representation by storing an externally mutable object into Container.qc MALICIOUS_CODE EI_EXPOSE_REP2 52 Medium
new nl.tudelft.simulation.examples.dsol.terminal.Container(DevsSimulatorInterface, int, QC, AGV, Ship) may expose internal representation by storing an externally mutable object into Container.ship MALICIOUS_CODE EI_EXPOSE_REP2 54 Medium
new nl.tudelft.simulation.examples.dsol.terminal.Container(DevsSimulatorInterface, int, QC, AGV, Ship) may expose internal representation by storing an externally mutable object into Container.simulator MALICIOUS_CODE EI_EXPOSE_REP2 50 Medium
Inconsistent synchronization of nl.tudelft.simulation.examples.dsol.terminal.Container.phase; locked 80% of time MT_CORRECTNESS IS2_INCONSISTENT_SYNC 148 Medium

nl.tudelft.simulation.examples.dsol.terminal.ExperimentRunnerTerminal

Bug Category Details Line Priority
nl.tudelft.simulation.examples.dsol.terminal.ExperimentRunnerTerminal.notify(Event) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 129 Medium
nl.tudelft.simulation.examples.dsol.terminal.ExperimentRunnerTerminal.terminate(DevsSimulator, int, int, int, Terminal) invokes System.exit(...), which shuts down the entire virtual machine BAD_PRACTICE DM_EXIT 112 Medium

nl.tudelft.simulation.examples.dsol.terminal.IntResource

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.terminal.IntResource(DevsSimulatorInterface, String, long) may expose internal representation by storing an externally mutable object into IntResource.simulator MALICIOUS_CODE EI_EXPOSE_REP2 85 Medium
Inconsistent synchronization of nl.tudelft.simulation.examples.dsol.terminal.IntResource.claimedCapacity; locked 57% of time MT_CORRECTNESS IS2_INCONSISTENT_SYNC 114 Medium
Class nl.tudelft.simulation.examples.dsol.terminal.IntResource defines non-transient non-serializable instance field requests BAD_PRACTICE SE_BAD_FIELD Not available Medium

nl.tudelft.simulation.examples.dsol.terminal.QC

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.terminal.QC(DevsSimulatorInterface, String, long, DistContinuous) may expose internal representation by storing an externally mutable object into QC.qcTime MALICIOUS_CODE EI_EXPOSE_REP2 36 Medium

nl.tudelft.simulation.examples.dsol.terminal.Terminal

Bug Category Details Line Priority
nl.tudelft.simulation.examples.dsol.terminal.Terminal.getShip() may expose internal representation by returning Terminal.ship MALICIOUS_CODE EI_EXPOSE_REP 100 Medium

nl.tudelft.simulation.examples.dsol.timesharedcomputer.CPU

Bug Category Details Line Priority
nl.tudelft.simulation.examples.dsol.timesharedcomputer.CPU.getQueue() may expose internal representation by returning CPU.queue MALICIOUS_CODE EI_EXPOSE_REP 79 Medium

nl.tudelft.simulation.examples.dsol.timesharedcomputer.Job

Bug Category Details Line Priority
nl.tudelft.simulation.examples.dsol.timesharedcomputer.Job.getOwner() may expose internal representation by returning Job.source MALICIOUS_CODE EI_EXPOSE_REP 70 Medium
new nl.tudelft.simulation.examples.dsol.timesharedcomputer.Job(DistContinuous, Station, double) may expose internal representation by storing an externally mutable object into Job.source MALICIOUS_CODE EI_EXPOSE_REP2 32 Medium

nl.tudelft.simulation.examples.dsol.timesharedcomputer.Terminal

Bug Category Details Line Priority
new nl.tudelft.simulation.examples.dsol.timesharedcomputer.Terminal(DevsSimulatorInterface, Station, DistContinuous, DistContinuous) may expose internal representation by storing an externally mutable object into Terminal.jobSize MALICIOUS_CODE EI_EXPOSE_REP2 48 Medium
new nl.tudelft.simulation.examples.dsol.timesharedcomputer.Terminal(DevsSimulatorInterface, Station, DistContinuous, DistContinuous) may expose internal representation by storing an externally mutable object into Terminal.thinkDelay MALICIOUS_CODE EI_EXPOSE_REP2 47 Medium