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
,BaseSetpointCommand
,BaseWaitForMaintainerCommand
,ChangeActiveSwerveModuleCommand
,ConfigurePropertiesCommand
,DelayViaSupplierCommand
,PurePursuitCommand
,ResetDistanceCommand
,ResetSimulatorPositionCommand
,SetAutonomousCommand
,SetRobotHeadingCommand
,SimpleWaitForMaintainerCommand
,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
Modifier and TypeFieldDescriptionprotected final AKitLogger
protected final org.apache.logging.log4j.Logger
protected final TimeLogger
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
includeOnSmartDashboard
(String label) abstract void
void
requires
(BaseSubsystem subsystem) Deprecated.boolean
void
setRunsWhenDisabled
(boolean value) Methods inherited from class edu.wpi.first.wpilibj2.command.Command
addRequirements, addRequirements, alongWith, andThen, andThen, asProxy, beforeStarting, beforeStarting, cancel, deadlineFor, deadlineWith, end, 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
-
log
protected final org.apache.logging.log4j.Logger log -
aKitLog
-
monitor
-
-
Constructor Details
-
BaseCommand
public BaseCommand()
-
-
Method Details
-
runsWhenDisabled
public boolean runsWhenDisabled()- Overrides:
runsWhenDisabled
in classCommand
-
setRunsWhenDisabled
public void setRunsWhenDisabled(boolean value) -
getPrefix
- Specified by:
getPrefix
in interfaceIPropertySupport
-
initialize
public abstract void initialize()- Overrides:
initialize
in classCommand
-
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.