The following document contains the results of SpotBugs
SpotBugs Version is 4.7.1
Threshold is medium
Effort is default
| Classes | Bugs | Errors | Missing Classes |
|---|---|---|---|
| 25 | 39 | 0 | 0 |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Hard coded reference to an absolute pathname in nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$ServerThread.run() | STYLE | DMI_HARDCODED_ABSOLUTE_FILENAME | 87 | High |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$XHRHandler.setParameters(DSOLModel, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 510 | High |
| Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$XHRHandler.setParameters(DSOLModel, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 515 | High |
| Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$XHRHandler.setParameters(DSOLModel, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 530 | High |
| Boxing/unboxing to parse a primitive nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$XHRHandler.setParameters(DSOLModel, String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 525 | High |
| Exception is caught when Exception is not thrown in nl.tudelft.simulation.dsol.web.AbstractTestDemoServer$XHRHandler.setParameters(DSOLModel, String) | STYLE | REC_CATCH_EXCEPTION | 558 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| instanceof will always return false in nl.tudelft.simulation.dsol.web.DSOLWebModel.handle(String, Request, HttpServletRequest, HttpServletResponse), since a Number cannot be a java.util.Calendar | CORRECTNESS | BC_IMPOSSIBLE_INSTANCEOF | 476 | Medium |
| Dead store to params in nl.tudelft.simulation.dsol.web.DSOLWebModel.handle(String, Request, HttpServletRequest, HttpServletResponse) | STYLE | DLS_DEAD_LOCAL_STORE | 210 | Medium |
| nl.tudelft.simulation.dsol.web.DSOLWebModel.getAnimationPanel() may expose internal representation by returning DSOLWebModel.animationPanel | MALICIOUS_CODE | EI_EXPOSE_REP | 111 | Medium |
| nl.tudelft.simulation.dsol.web.DSOLWebModel.getSimulator() may expose internal representation by returning DSOLWebModel.simulator | MALICIOUS_CODE | EI_EXPOSE_REP | 103 | Medium |
| new nl.tudelft.simulation.dsol.web.DSOLWebModel(String, SimulatorInterface) may expose internal representation by storing an externally mutable object into DSOLWebModel.simulator | MALICIOUS_CODE | EI_EXPOSE_REP2 | 75 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.DSOLWebServer.getAnimationPanel() may expose internal representation by returning DSOLWebServer.animationPanel | MALICIOUS_CODE | EI_EXPOSE_REP | 150 | Medium |
| nl.tudelft.simulation.dsol.web.DSOLWebServer.getSimulator() may expose internal representation by returning DSOLWebServer.simulator | MALICIOUS_CODE | EI_EXPOSE_REP | 142 | Medium |
| new nl.tudelft.simulation.dsol.web.DSOLWebServer(String, SimulatorInterface, Bounds2d) may expose internal representation by storing an externally mutable object into DSOLWebServer.simulator | MALICIOUS_CODE | EI_EXPOSE_REP2 | 78 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Hard coded reference to an absolute pathname in nl.tudelft.simulation.dsol.web.DSOLWebServer$ServerThread.run() | STYLE | DMI_HARDCODED_ABSOLUTE_FILENAME | 105 | High |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| instanceof will always return false in nl.tudelft.simulation.dsol.web.DSOLWebServer$XHRHandler.handle(String, Request, HttpServletRequest, HttpServletResponse), since a Number cannot be a java.util.Calendar | CORRECTNESS | BC_IMPOSSIBLE_INSTANCEOF | 535 | Medium |
| Dead store to params in nl.tudelft.simulation.dsol.web.DSOLWebServer$XHRHandler.handle(String, Request, HttpServletRequest, HttpServletResponse) | STYLE | DLS_DEAD_LOCAL_STORE | 269 | Medium |
| new nl.tudelft.simulation.dsol.web.DSOLWebServer$XHRHandler(DSOLWebServer) may expose internal representation by storing an externally mutable object into DSOLWebServer$XHRHandler.webServer | MALICIOUS_CODE | EI_EXPOSE_REP2 | 258 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.HTMLDevice.getConfigurations() may expose internal representation by returning HTMLDevice.htmlGraphicsConfigurations | MALICIOUS_CODE | EI_EXPOSE_REP | 53 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphics2D.getRenderingHints() may expose internal representation by returning HTMLGraphics2D.renderingHints | MALICIOUS_CODE | EI_EXPOSE_REP | 652 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphics2D.getTransform() may expose internal representation by returning HTMLGraphics2D.affineTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 723 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsConfiguration.getBounds() may expose internal representation by returning HTMLGraphicsConfiguration.bounds | MALICIOUS_CODE | EI_EXPOSE_REP | 98 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsConfiguration.getDefaultTransform() may expose internal representation by returning HTMLGraphicsConfiguration.identityTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 82 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsConfiguration.getDevice() may expose internal representation by returning HTMLGraphicsConfiguration.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP | 47 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsConfiguration.getNormalizingTransform() may expose internal representation by returning HTMLGraphicsConfiguration.identityTransform | MALICIOUS_CODE | EI_EXPOSE_REP | 90 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsConfiguration.setDevice(HTMLDevice) may expose internal representation by storing an externally mutable object into HTMLGraphicsConfiguration.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP2 | 58 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsEnvironment.createGraphics(BufferedImage) may expose internal representation by returning HTMLGraphicsEnvironment.graphics2D | MALICIOUS_CODE | EI_EXPOSE_REP | 67 | Medium |
| nl.tudelft.simulation.dsol.web.animation.HTMLGraphicsEnvironment.getDefaultScreenDevice() may expose internal representation by returning HTMLGraphicsEnvironment.htmlDevice | MALICIOUS_CODE | EI_EXPOSE_REP | 59 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| Should nl.tudelft.simulation.dsol.web.animation.TestSwing$CustomPanel be a _static_ inner class? | PERFORMANCE | SIC_INNER_SHOULD_BE_STATIC | 57-67 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLAnimationPanel.getDragLine() may expose internal representation by returning HTMLAnimationPanel.dragLine | MALICIOUS_CODE | EI_EXPOSE_REP | 381 | Medium |
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLAnimationPanel.getToggleButtons() may expose internal representation by returning HTMLAnimationPanel.toggleButtons | MALICIOUS_CODE | EI_EXPOSE_REP | 571 | Medium |
| new nl.tudelft.simulation.dsol.web.animation.D2.HTMLAnimationPanel(Bounds2d, Dimension, SimulatorInterface) may expose internal representation by storing an externally mutable object into HTMLAnimationPanel.simulator | MALICIOUS_CODE | EI_EXPOSE_REP2 | 109 | Medium |
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLAnimationPanel.isShowClass(Class) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 180 | Medium |
| Bug | Category | Details | Line | Priority |
|---|---|---|---|---|
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.getPreferredSize() may expose internal representation by returning HTMLGridPanel.preferredSize | MALICIOUS_CODE | EI_EXPOSE_REP | 504 | Medium |
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.getSize() may expose internal representation by returning HTMLGridPanel.size | MALICIOUS_CODE | EI_EXPOSE_REP | 456 | Medium |
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.setPreferredSize(Dimension) may expose internal representation by storing an externally mutable object into HTMLGridPanel.preferredSize | MALICIOUS_CODE | EI_EXPOSE_REP2 | 512 | Medium |
| nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.setSize(Dimension) may expose internal representation by storing an externally mutable object into HTMLGridPanel.size | MALICIOUS_CODE | EI_EXPOSE_REP2 | 464 | Medium |
| Inconsistent synchronization of nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.extent; locked 91% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 200 | Medium |
| Inconsistent synchronization of nl.tudelft.simulation.dsol.web.animation.D2.HTMLGridPanel.renderableScale; locked 66% of time | MT_CORRECTNESS | IS2_INCONSISTENT_SYNC | 601 | Medium |