Hi,
I disabled PMD rule "AssignmentInOperand", i.e., "Avoid assignments in
operands.". The code in question is as below:
byte[] tmp = new byte[4096];
int i = 0;
InputStream is = new FileInputStream(inputFile);
try {
while ((i = is.read(tmp)) >= 0) {
outputstream.write(tmp, 0, i);
}
} finally {
is.close();
}
I've already committed this change as I believe the snippet above is the best
way to write this code. Having that said, you still have a chance to shout out
if you strongly against this change :-)
Cheers,
Jervis
----------------------------
IONA Technologies PLC (registered in Ireland)
Registered Number: 171387
Registered Address: The IONA Building, Shelbourne Road, Dublin 4, Ireland