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 |
---|---|---|---|
73 | 46 | 0 | 0 |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.KpiDirectedLanePosition.getPosition() may expose internal representation by returning KpiDirectedLanePosition.position | MALICIOUS_CODE | EI_EXPOSE_REP | 66 | Medium |
new org.opentrafficsim.kpi.sampling.KpiDirectedLanePosition(LaneDataInterface, Length, KpiGtuDirectionality) may expose internal representation by storing an externally mutable object into KpiDirectedLanePosition.position | MALICIOUS_CODE | EI_EXPOSE_REP2 | 47 | Medium |
Class org.opentrafficsim.kpi.sampling.KpiDirectedLanePosition defines non-transient non-serializable instance field lane | BAD_PRACTICE | SE_BAD_FIELD | Not available | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Class org.opentrafficsim.kpi.sampling.KpiLaneDirection defines non-transient non-serializable instance field lane | BAD_PRACTICE | SE_BAD_FIELD | Not available | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
new org.opentrafficsim.kpi.sampling.ListTable$ListRecord(ListTable, Object[]) may expose internal representation by storing an externally mutable object into ListTable$ListRecord.this$0 | MALICIOUS_CODE | EI_EXPOSE_REP2 | 175 | Medium |
new org.opentrafficsim.kpi.sampling.ListTable$ListRecord(ListTable, Object[]) may expose internal representation by storing an externally mutable object into ListTable$ListRecord.values | MALICIOUS_CODE | EI_EXPOSE_REP2 | 176 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.Query.getInterval() may expose internal representation by returning Query.interval | MALICIOUS_CODE | EI_EXPOSE_REP | 213 | Medium |
org.opentrafficsim.kpi.sampling.Query.getUpdateFrequency() may expose internal representation by returning Query.updateFrequency | MALICIOUS_CODE | EI_EXPOSE_REP | 205 | Medium |
new org.opentrafficsim.kpi.sampling.Query(Sampler, String, String, FilterDataSet, Frequency, Duration) may expose internal representation by storing an externally mutable object into Query.interval | MALICIOUS_CODE | EI_EXPOSE_REP2 | 125 | Medium |
new org.opentrafficsim.kpi.sampling.Query(Sampler, String, String, FilterDataSet, Frequency, Duration) may expose internal representation by storing an externally mutable object into Query.updateFrequency | MALICIOUS_CODE | EI_EXPOSE_REP2 | 124 | Medium |
org.opentrafficsim.kpi.sampling.Query.getTrajectoryGroups(Time, Time) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 360 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.Sampler.getSamplerData() may expose internal representation by returning Sampler.samplerData | MALICIOUS_CODE | EI_EXPOSE_REP | 80 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Read of unwritten field currentTrajectory in org.opentrafficsim.kpi.sampling.SamplerData$1.hasNext() | CORRECTNESS | NP_UNWRITTEN_FIELD | 457 | Medium |
Unread field: org.opentrafficsim.kpi.sampling.SamplerData$1.trajectory | PERFORMANCE | URF_UNREAD_FIELD | 448 | Medium |
Unwritten field: org.opentrafficsim.kpi.sampling.SamplerData$1.currentTrajectory | CORRECTNESS | UWF_UNWRITTEN_FIELD | 457 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: org.opentrafficsim.kpi.sampling.SamplerData$GtuTypeData.id | PERFORMANCE | URF_UNREAD_FIELD | 726 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: org.opentrafficsim.kpi.sampling.SamplerData$NodeData.id | PERFORMANCE | URF_UNREAD_FIELD | 701 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Unread field: org.opentrafficsim.kpi.sampling.SamplerData$RouteData.id | PERFORMANCE | URF_UNREAD_FIELD | 751 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.SpaceTimeRegion.getEndPosition() may expose internal representation by returning SpaceTimeRegion.endPosition | MALICIOUS_CODE | EI_EXPOSE_REP | 81 | Medium |
org.opentrafficsim.kpi.sampling.SpaceTimeRegion.getEndTime() may expose internal representation by returning SpaceTimeRegion.endTime | MALICIOUS_CODE | EI_EXPOSE_REP | 97 | Medium |
org.opentrafficsim.kpi.sampling.SpaceTimeRegion.getStartPosition() may expose internal representation by returning SpaceTimeRegion.startPosition | MALICIOUS_CODE | EI_EXPOSE_REP | 73 | Medium |
org.opentrafficsim.kpi.sampling.SpaceTimeRegion.getStartTime() may expose internal representation by returning SpaceTimeRegion.startTime | MALICIOUS_CODE | EI_EXPOSE_REP | 89 | Medium |
new org.opentrafficsim.kpi.sampling.SpaceTimeRegion(KpiLaneDirection, Length, Length, Time, Time) may expose internal representation by storing an externally mutable object into SpaceTimeRegion.endPosition | MALICIOUS_CODE | EI_EXPOSE_REP2 | 55 | Medium |
new org.opentrafficsim.kpi.sampling.SpaceTimeRegion(KpiLaneDirection, Length, Length, Time, Time) may expose internal representation by storing an externally mutable object into SpaceTimeRegion.endTime | MALICIOUS_CODE | EI_EXPOSE_REP2 | 57 | Medium |
new org.opentrafficsim.kpi.sampling.SpaceTimeRegion(KpiLaneDirection, Length, Length, Time, Time) may expose internal representation by storing an externally mutable object into SpaceTimeRegion.startPosition | MALICIOUS_CODE | EI_EXPOSE_REP2 | 54 | Medium |
new org.opentrafficsim.kpi.sampling.SpaceTimeRegion(KpiLaneDirection, Length, Length, Time, Time) may expose internal representation by storing an externally mutable object into SpaceTimeRegion.startTime | MALICIOUS_CODE | EI_EXPOSE_REP2 | 56 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.Trajectory.subSet(Trajectory$Boundaries) makes inefficient use of keySet iterator instead of entrySet iterator | PERFORMANCE | WMI_WRONG_MAP_ITERATOR | 818 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.Trajectory$SpaceTimeView.getDistance() may expose internal representation by returning Trajectory$SpaceTimeView.distance | MALICIOUS_CODE | EI_EXPOSE_REP | 1115 | Medium |
org.opentrafficsim.kpi.sampling.Trajectory$SpaceTimeView.getTime() may expose internal representation by returning Trajectory$SpaceTimeView.time | MALICIOUS_CODE | EI_EXPOSE_REP | 1124 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.TrajectoryGroup.getStartTime() may expose internal representation by returning TrajectoryGroup.startTime | MALICIOUS_CODE | EI_EXPOSE_REP | 92 | Medium |
new org.opentrafficsim.kpi.sampling.TrajectoryGroup(Time, Length, Length, KpiLaneDirection) may expose internal representation by storing an externally mutable object into TrajectoryGroup.endPosition | MALICIOUS_CODE | EI_EXPOSE_REP2 | 73 | Medium |
new org.opentrafficsim.kpi.sampling.TrajectoryGroup(Time, Length, Length, KpiLaneDirection) may expose internal representation by storing an externally mutable object into TrajectoryGroup.startPosition | MALICIOUS_CODE | EI_EXPOSE_REP2 | 72 | Medium |
new org.opentrafficsim.kpi.sampling.TrajectoryGroup(Time, Length, Length, KpiLaneDirection) may expose internal representation by storing an externally mutable object into TrajectoryGroup.startTime | MALICIOUS_CODE | EI_EXPOSE_REP2 | 71 | Medium |
Null passed for non-null parameter of new TrajectoryGroup(Time, Length, Length, KpiLaneDirection) in new org.opentrafficsim.kpi.sampling.TrajectoryGroup(Time, KpiLaneDirection) | CORRECTNESS | NP_NULL_PARAM_DEREF | 50 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Boxing/unboxing to parse a primitive org.opentrafficsim.kpi.sampling.data.ExtendedDataTypeDuration.parseValue(String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 61 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Boxing/unboxing to parse a primitive org.opentrafficsim.kpi.sampling.data.ExtendedDataTypeLength.parseValue(String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 61 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
Boxing/unboxing to parse a primitive org.opentrafficsim.kpi.sampling.data.ExtendedDataTypeSpeed.parseValue(String) | PERFORMANCE | DM_BOXED_PRIMITIVE_FOR_PARSING | 61 | High |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.indicator.AbstractIndicator.getValue(Query, Time, Time, List) may expose internal representation by storing an externally mutable object into AbstractIndicator.lastEndTime | MALICIOUS_CODE | EI_EXPOSE_REP2 | 75 | Medium |
org.opentrafficsim.kpi.sampling.indicator.AbstractIndicator.getValue(Query, Time, Time, List) may expose internal representation by storing an externally mutable object into AbstractIndicator.lastQuery | MALICIOUS_CODE | EI_EXPOSE_REP2 | 73 | Medium |
org.opentrafficsim.kpi.sampling.indicator.AbstractIndicator.getValue(Query, Time, Time, List) may expose internal representation by storing an externally mutable object into AbstractIndicator.lastStartTime | MALICIOUS_CODE | EI_EXPOSE_REP2 | 74 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.indicator.ConfidenceInterval.getLowerValue() may expose internal representation by returning ConfidenceInterval.lowerValue | MALICIOUS_CODE | EI_EXPOSE_REP | 41 | Medium |
org.opentrafficsim.kpi.sampling.indicator.ConfidenceInterval.getUpperValue() may expose internal representation by returning ConfidenceInterval.upperValue | MALICIOUS_CODE | EI_EXPOSE_REP | 49 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
org.opentrafficsim.kpi.sampling.indicator.Persistent.getMax() may expose internal representation by returning Persistent.max | MALICIOUS_CODE | EI_EXPOSE_REP | 176 | Medium |
org.opentrafficsim.kpi.sampling.indicator.Persistent.getMin() may expose internal representation by returning Persistent.min | MALICIOUS_CODE | EI_EXPOSE_REP | 168 | Medium |
org.opentrafficsim.kpi.sampling.indicator.Persistent.getSum() may expose internal representation by returning Persistent.sum | MALICIOUS_CODE | EI_EXPOSE_REP | 239 | Medium |
Bug | Category | Details | Line | Priority |
---|---|---|---|---|
new org.opentrafficsim.kpi.sampling.indicator.TotalDelay(Speed) may expose internal representation by storing an externally mutable object into TotalDelay.referenceSpeed | MALICIOUS_CODE | EI_EXPOSE_REP2 | 37 | Medium |