mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
[build] Change defaults for Java lints (#4300)
Removes the need to individually suppress the "serial" warning.
This commit is contained in:
@@ -57,7 +57,6 @@ public final class SplineParameterizer {
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("serial")
|
||||
public static class MalformedSplineException extends RuntimeException {
|
||||
/**
|
||||
* Create a new exception with the given message.
|
||||
|
||||
@@ -24,7 +24,7 @@ public final class NumericalIntegration {
|
||||
* @param dtSeconds The time over which to integrate.
|
||||
* @return the integration of dx/dt = f(x) for dt.
|
||||
*/
|
||||
@SuppressWarnings("ParameterName")
|
||||
@SuppressWarnings({"ParameterName", "overloads"})
|
||||
public static double rk4(DoubleFunction<Double> f, double x, double dtSeconds) {
|
||||
final var h = dtSeconds;
|
||||
final var k1 = f.apply(x);
|
||||
@@ -44,7 +44,7 @@ public final class NumericalIntegration {
|
||||
* @param dtSeconds The time over which to integrate.
|
||||
* @return The result of Runge Kutta integration (4th order).
|
||||
*/
|
||||
@SuppressWarnings("ParameterName")
|
||||
@SuppressWarnings({"ParameterName", "overloads"})
|
||||
public static double rk4(
|
||||
BiFunction<Double, Double, Double> f, double x, Double u, double dtSeconds) {
|
||||
final var h = dtSeconds;
|
||||
@@ -68,7 +68,7 @@ public final class NumericalIntegration {
|
||||
* @param dtSeconds The time over which to integrate.
|
||||
* @return the integration of dx/dt = f(x, u) for dt.
|
||||
*/
|
||||
@SuppressWarnings({"ParameterName", "MethodTypeParameterName"})
|
||||
@SuppressWarnings({"ParameterName", "MethodTypeParameterName", "overloads"})
|
||||
public static <States extends Num, Inputs extends Num> Matrix<States, N1> rk4(
|
||||
BiFunction<Matrix<States, N1>, Matrix<Inputs, N1>, Matrix<States, N1>> f,
|
||||
Matrix<States, N1> x,
|
||||
@@ -93,7 +93,7 @@ public final class NumericalIntegration {
|
||||
* @param dtSeconds The time over which to integrate.
|
||||
* @return 4th order Runge-Kutta integration of dx/dt = f(x) for dt.
|
||||
*/
|
||||
@SuppressWarnings({"ParameterName", "MethodTypeParameterName"})
|
||||
@SuppressWarnings({"ParameterName", "MethodTypeParameterName", "overloads"})
|
||||
public static <States extends Num> Matrix<States, N1> rk4(
|
||||
Function<Matrix<States, N1>, Matrix<States, N1>> f, Matrix<States, N1> x, double dtSeconds) {
|
||||
final var h = dtSeconds;
|
||||
|
||||
@@ -263,7 +263,6 @@ public final class TrajectoryGenerator {
|
||||
}
|
||||
|
||||
// Work around type erasure signatures
|
||||
@SuppressWarnings("serial")
|
||||
public static class ControlVectorList extends ArrayList<Spline.ControlVector> {
|
||||
public ControlVectorList(int initialCapacity) {
|
||||
super(initialCapacity);
|
||||
|
||||
@@ -320,7 +320,6 @@ public final class TrajectoryParameterizer {
|
||||
}
|
||||
}
|
||||
|
||||
@SuppressWarnings("serial")
|
||||
public static class TrajectoryGenerationException extends RuntimeException {
|
||||
public TrajectoryGenerationException(String message) {
|
||||
super(message);
|
||||
|
||||
Reference in New Issue
Block a user