[wpilibj] Make Java TrapezoidProfile.Constraints an immutable class (#3687)

This commit is contained in:
Tyler Veness
2021-10-28 00:17:36 -07:00
committed by GitHub
parent 187f50a344
commit 8723caf78d
2 changed files with 3 additions and 7 deletions

View File

@@ -52,14 +52,10 @@ public class TrapezoidProfile {
public static class Constraints {
@SuppressWarnings("MemberName")
public double maxVelocity;
public final double maxVelocity;
@SuppressWarnings("MemberName")
public double maxAcceleration;
public Constraints() {
MathSharedStore.reportUsage(MathUsageId.kTrajectory_TrapezoidProfile, 1);
}
public final double maxAcceleration;
/**
* Construct constraints for a TrapezoidProfile.