mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-23 01:21:42 +00:00
[wpilibj] Fix typos in error messages for non-null assertions (#4014)
This commit is contained in:
@@ -112,9 +112,9 @@ public class MecanumControllerCommand extends CommandBase {
|
||||
|
||||
m_controller =
|
||||
new HolonomicDriveController(
|
||||
requireNonNullParam(xController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(yController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(thetaController, "thetaController", "SwerveControllerCommand"));
|
||||
requireNonNullParam(xController, "xController", "MecanumControllerCommand"),
|
||||
requireNonNullParam(yController, "yController", "MecanumControllerCommand"),
|
||||
requireNonNullParam(thetaController, "thetaController", "MecanumControllerCommand"));
|
||||
|
||||
m_desiredRotation =
|
||||
requireNonNullParam(desiredRotation, "desiredRotation", "MecanumControllerCommand");
|
||||
@@ -255,9 +255,9 @@ public class MecanumControllerCommand extends CommandBase {
|
||||
|
||||
m_controller =
|
||||
new HolonomicDriveController(
|
||||
requireNonNullParam(xController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(yController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(thetaController, "thetaController", "SwerveControllerCommand"));
|
||||
requireNonNullParam(xController, "xController", "MecanumControllerCommand"),
|
||||
requireNonNullParam(yController, "yController", "MecanumControllerCommand"),
|
||||
requireNonNullParam(thetaController, "thetaController", "MecanumControllerCommand"));
|
||||
|
||||
m_desiredRotation =
|
||||
requireNonNullParam(desiredRotation, "desiredRotation", "MecanumControllerCommand");
|
||||
|
||||
@@ -39,10 +39,10 @@ public class PIDCommand extends CommandBase {
|
||||
DoubleSupplier setpointSource,
|
||||
DoubleConsumer useOutput,
|
||||
Subsystem... requirements) {
|
||||
requireNonNullParam(controller, "controller", "SynchronousPIDCommand");
|
||||
requireNonNullParam(measurementSource, "measurementSource", "SynchronousPIDCommand");
|
||||
requireNonNullParam(setpointSource, "setpointSource", "SynchronousPIDCommand");
|
||||
requireNonNullParam(useOutput, "useOutput", "SynchronousPIDCommand");
|
||||
requireNonNullParam(controller, "controller", "PIDCommand");
|
||||
requireNonNullParam(measurementSource, "measurementSource", "PIDCommand");
|
||||
requireNonNullParam(setpointSource, "setpointSource", "PIDCommand");
|
||||
requireNonNullParam(useOutput, "useOutput", "PIDCommand");
|
||||
|
||||
m_controller = controller;
|
||||
m_useOutput = useOutput;
|
||||
|
||||
@@ -42,10 +42,10 @@ public class ProfiledPIDCommand extends CommandBase {
|
||||
Supplier<State> goalSource,
|
||||
BiConsumer<Double, State> useOutput,
|
||||
Subsystem... requirements) {
|
||||
requireNonNullParam(controller, "controller", "SynchronousPIDCommand");
|
||||
requireNonNullParam(measurementSource, "measurementSource", "SynchronousPIDCommand");
|
||||
requireNonNullParam(goalSource, "goalSource", "SynchronousPIDCommand");
|
||||
requireNonNullParam(useOutput, "useOutput", "SynchronousPIDCommand");
|
||||
requireNonNullParam(controller, "controller", "ProfiledPIDCommand");
|
||||
requireNonNullParam(measurementSource, "measurementSource", "ProfiledPIDCommand");
|
||||
requireNonNullParam(goalSource, "goalSource", "ProfiledPIDCommand");
|
||||
requireNonNullParam(useOutput, "useOutput", "ProfiledPIDCommand");
|
||||
|
||||
m_controller = controller;
|
||||
m_useOutput = useOutput;
|
||||
|
||||
@@ -119,7 +119,8 @@ public class RamseteCommand extends CommandBase {
|
||||
m_pose = requireNonNullParam(pose, "pose", "RamseteCommand");
|
||||
m_follower = requireNonNullParam(follower, "follower", "RamseteCommand");
|
||||
m_kinematics = requireNonNullParam(kinematics, "kinematics", "RamseteCommand");
|
||||
m_output = requireNonNullParam(outputMetersPerSecond, "output", "RamseteCommand");
|
||||
m_output =
|
||||
requireNonNullParam(outputMetersPerSecond, "outputMetersPerSecond", "RamseteCommand");
|
||||
|
||||
m_feedforward = null;
|
||||
m_speeds = null;
|
||||
|
||||
@@ -79,11 +79,11 @@ public class SwerveControllerCommand extends CommandBase {
|
||||
m_controller =
|
||||
new HolonomicDriveController(
|
||||
requireNonNullParam(xController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(yController, "xController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(yController, "yController", "SwerveControllerCommand"),
|
||||
requireNonNullParam(thetaController, "thetaController", "SwerveControllerCommand"));
|
||||
|
||||
m_outputModuleStates =
|
||||
requireNonNullParam(outputModuleStates, "frontLeftOutput", "SwerveControllerCommand");
|
||||
requireNonNullParam(outputModuleStates, "outputModuleStates", "SwerveControllerCommand");
|
||||
|
||||
m_desiredRotation =
|
||||
requireNonNullParam(desiredRotation, "desiredRotation", "SwerveControllerCommand");
|
||||
|
||||
Reference in New Issue
Block a user