Skip to content

Commit 09c86c9

Browse files
committed
Fixed PMD violations.
1 parent f4f92f0 commit 09c86c9

File tree

2 files changed

+1
-11
lines changed

2 files changed

+1
-11
lines changed

LICENSE-3RD-PARTY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
# Third-party dependencies
22
* Apache License, Version 2.0:
3-
* [jcommander](https://jcommander.org)
43
* [Jackson-annotations](https://github.com/FasterXML/jackson)
54
* [Jackson-core](https://github.com/FasterXML/jackson-core)
65
* [jackson-databind](https://github.com/FasterXML/jackson)
@@ -19,6 +18,7 @@
1918
* [Byte Buddy (without dependencies)](https://bytebuddy.net/byte-buddy)
2019
* [Apache Commons Math](http://commons.apache.org/proper/commons-math/)
2120
* [AssertJ Core](https://assertj.github.io/doc/#assertj-core)
21+
* [jcommander](https://jcommander.org)
2222
* [testng](https://testng.org)
2323
* Eclipse Public License (EPL), Version 1.0:
2424
* [Logback Classic Module](http://logback.qos.ch/logback-classic)

java/src/main/java/com/github/cowwoc/requirements10/java/internal/message/diff/DiffGenerator.java

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,6 @@ private void writeDelta(AbstractDelta<Integer> delta, DiffWriter writer)
153153
writer.writeInserted(fromCodepoints(delta.getTarget().getLines()));
154154
break;
155155
}
156-
default:
157-
throw new AssertionError("Unexpected type: " + delta.getType());
158156
}
159157
}
160158

@@ -202,8 +200,6 @@ public boolean isEmpty(String line)
202200
DiffConstants.POSTFIX), "");
203201
break;
204202
}
205-
default:
206-
throw new AssertionError(encoding.name());
207203
}
208204
return containsOnly(line, paddingMarker);
209205
}
@@ -448,8 +444,6 @@ private static <T> int numberOfUnequalDeltas(List<AbstractDelta<T>> deltas)
448444
result += 2;
449445
break;
450446
}
451-
default:
452-
throw new AssertionError(delta.getType().name());
453447
}
454448
}
455449
return result;
@@ -627,8 +621,6 @@ private int shortestDelta(List<AbstractDelta<Integer>> deltas)
627621
result = Math.min(result, fromCodepoints(delta.getTarget().getLines()).length());
628622
break;
629623
}
630-
default:
631-
throw new AssertionError(delta.getType().name());
632624
}
633625
}
634626
return result;
@@ -671,8 +663,6 @@ private int longestWord(List<AbstractDelta<Integer>> deltas)
671663
lengthOfTarget += fromCodepoints(delta.getTarget().getLines()).length();
672664
break;
673665
}
674-
default:
675-
throw new AssertionError(delta.getType().name());
676666
}
677667
}
678668
int result = Math.max(lengthOfSource, lengthOfTarget);

0 commit comments

Comments
 (0)