Package xbot.common.command
Class BaseCommand
java.lang.Object
edu.wpi.first.wpilibj2.command.Command
xbot.common.command.BaseCommand
- All Implemented Interfaces:
Sendable,IPropertySupport
- Direct Known Subclasses:
BaseMaintainerCommand,BaseSequentialCommandGroup,BaseSetpointCommand,BaseWaitForMaintainerCommand,ChangeActiveSwerveModuleCommand,ConfigurePropertiesCommand,DelayViaSupplierCommand,PurePursuitCommand,ResetDistanceCommand,ResetSimulatorPositionCommand,SetAutonomousCommand,SetRobotHeadingCommand,SimpleWaitForMaintainerCommand,SwerveSimpleBezierCommand,SwerveSimpleTrajectoryCommand
Enhanced version of WPILib's Command that allows for extension of existing
functionality.
-
Nested Class Summary
Nested classes/interfaces inherited from class edu.wpi.first.wpilibj2.command.Command
Command.InterruptionBehavior -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final AKitLoggerprotected final org.apache.logging.log4j.Loggerprotected final TimeLoggerprotected final Alert -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidend(boolean isInterrupted) voidvoidincludeOnSmartDashboard(String label) voidvoidrequires(BaseSubsystem subsystem) Deprecated.booleanvoidsetRunsWhenDisabled(boolean value) Methods inherited from class edu.wpi.first.wpilibj2.command.Command
addRequirements, addRequirements, alongWith, andThen, andThen, asProxy, beforeStarting, beforeStarting, cancel, deadlineFor, deadlineWith, execute, finallyDo, finallyDo, getInterruptionBehavior, getName, getRequirements, getSubsystem, handleInterrupt, hasRequirement, ignoringDisable, initSendable, isFinished, isScheduled, onlyIf, onlyWhile, raceWith, repeatedly, schedule, setName, setSubsystem, unless, until, withDeadline, withInterruptBehavior, withName, withTimeout, withTimeout
-
Field Details
-
runningAlert
-
log
protected final org.apache.logging.log4j.Logger log -
aKitLog
-
monitor
-
-
Constructor Details
-
BaseCommand
public BaseCommand()
-
-
Method Details
-
runsWhenDisabled
public boolean runsWhenDisabled()- Overrides:
runsWhenDisabledin classCommand
-
setRunsWhenDisabled
public void setRunsWhenDisabled(boolean value) -
getPrefix
- Specified by:
getPrefixin interfaceIPropertySupport
-
initialize
public void initialize()- Overrides:
initializein classCommand
-
end
public void end(boolean isInterrupted) -
includeOnSmartDashboard
public void includeOnSmartDashboard() -
includeOnSmartDashboard
-
requires
Deprecated.Suggest useCommand.addRequirements(edu.wpi.first.wpilibj2.command.Subsystem...)instead.- Parameters:
subsystem- Requirement to add
-
Command.addRequirements(edu.wpi.first.wpilibj2.command.Subsystem...)instead.