Enable PMD rule SingularField and fix violations
This commit is contained in:
parent
3b77f93c00
commit
a07fc132d2
5 changed files with 3 additions and 9 deletions
|
@ -38,7 +38,6 @@ public class WayLinker extends MapCreatorBase implements Runnable {
|
|||
private File trafficTilesIn;
|
||||
private File dataTilesOut;
|
||||
private File borderFileIn;
|
||||
private File restrictionsFileIn;
|
||||
|
||||
private String dataTilesSuffix;
|
||||
|
||||
|
@ -157,7 +156,6 @@ public class WayLinker extends MapCreatorBase implements Runnable {
|
|||
this.trafficTilesIn = new File("../traffic");
|
||||
this.dataTilesOut = dataTilesOut;
|
||||
this.borderFileIn = borderFileIn;
|
||||
this.restrictionsFileIn = restrictionsFileIn;
|
||||
this.dataTilesSuffix = dataTilesSuffix;
|
||||
|
||||
BExpressionMetaData meta = new BExpressionMetaData();
|
||||
|
|
|
@ -16,8 +16,6 @@ import btools.util.ByteDataWriter;
|
|||
public final class DirectWeaver extends ByteDataWriter {
|
||||
private long id64Base;
|
||||
|
||||
private int size = 0;
|
||||
|
||||
public DirectWeaver(StatCoderContext bc, DataBuffers dataBuffers, int lonIdx, int latIdx, int divisor, TagValueValidator wayValidator, WaypointMatcher waypointMatcher, OsmNodesMap hollowNodes) {
|
||||
super(null);
|
||||
int cellsize = 1000000 / divisor;
|
||||
|
@ -31,7 +29,7 @@ public final class DirectWeaver extends ByteDataWriter {
|
|||
NoisyDiffCoder extLatDiff = new NoisyDiffCoder(bc);
|
||||
NoisyDiffCoder transEleDiff = new NoisyDiffCoder(bc);
|
||||
|
||||
size = bc.decodeNoisyNumber(5);
|
||||
int size = bc.decodeNoisyNumber(5);
|
||||
|
||||
int[] faid = size > dataBuffers.ibuf2.length ? new int[size] : dataBuffers.ibuf2;
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ public final class NodesCache {
|
|||
|
||||
private long cacheSum = 0;
|
||||
private long maxmemtiles;
|
||||
private boolean detailed;
|
||||
private boolean detailed; // NOPMD used in constructor
|
||||
|
||||
private boolean garbageCollectionEnabled = false;
|
||||
private boolean ghostCleaningDone = false;
|
||||
|
|
|
@ -19,7 +19,6 @@ final public class PhysicalFile {
|
|||
long[] fileIndex = new long[25];
|
||||
int[] fileHeaderCrcs;
|
||||
|
||||
private int fileIndexCrc;
|
||||
public long creationTime;
|
||||
|
||||
String fileName;
|
||||
|
@ -75,7 +74,7 @@ final public class PhysicalFile {
|
|||
byte[] iobuffer = dataBuffers.iobuffer;
|
||||
ra = new RandomAccessFile(f, "r");
|
||||
ra.readFully(iobuffer, 0, 200);
|
||||
fileIndexCrc = Crc32.crc(iobuffer, 0, 200);
|
||||
int fileIndexCrc = Crc32.crc(iobuffer, 0, 200);
|
||||
ByteDataReader dis = new ByteDataReader(iobuffer);
|
||||
for (int i = 0; i < 25; i++) {
|
||||
long lv = dis.readLong();
|
||||
|
|
|
@ -34,7 +34,6 @@
|
|||
<exclude name="SimplifiableTestAssertion" />
|
||||
<exclude name="SimplifiedTernary" />
|
||||
<exclude name="SimplifyBooleanReturns" />
|
||||
<exclude name="SingularField" />
|
||||
<exclude name="UncommentedEmptyConstructor" />
|
||||
<exclude name="UncommentedEmptyMethodBody" />
|
||||
<exclude name="UnnecessaryFullyQualifiedName" />
|
||||
|
|
Loading…
Reference in a new issue