Remove unused local variables and imports

This commit is contained in:
Owen Stephens 2017-10-23 07:45:58 +01:00
parent 23b643426a
commit 46c3ec100e

View File

@ -167,7 +167,6 @@ public class MultiValuedCellSplitOperation extends AbstractOperation {
String s = value instanceof String ? ((String) value) : value.toString(); String s = value instanceof String ? ((String) value) : value.toString();
String[] values = null; String[] values = null;
if("lengths".equals(_mode)) { if("lengths".equals(_mode)) {
//do split by lengths
if (_fieldLengths.length >= 0 && _fieldLengths[0] > 0) { if (_fieldLengths.length >= 0 && _fieldLengths[0] > 0) {
values = new String[_fieldLengths.length]; values = new String[_fieldLengths.length];
@ -176,9 +175,9 @@ public class MultiValuedCellSplitOperation extends AbstractOperation {
for (int i = 0; i < _fieldLengths.length; i++) { for (int i = 0; i < _fieldLengths.length; i++) {
int thisIndex = lastIndex; int thisIndex = lastIndex;
Object o2 = _fieldLengths[i]; Object o = _fieldLengths[i];
if (o2 instanceof Number) { if (o instanceof Number) {
thisIndex = Math.min(s.length(), lastIndex + Math.max(0, ((Number) o2).intValue())); thisIndex = Math.min(s.length(), lastIndex + Math.max(0, ((Number) o).intValue()));
} }
values[i] = s.substring(lastIndex, thisIndex); values[i] = s.substring(lastIndex, thisIndex);