mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-07-02 02:51:42 +00:00
[docs] Change NewCommands to Commands v2 (NFC) (#8702)
This commit is contained in:
@@ -32,7 +32,7 @@ namespace wpi::cmd {
|
||||
* <p>Note: ALWAYS create a subclass by extending CommandHelper<Base, Subclass>,
|
||||
* or decorators will not function!
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see CommandScheduler
|
||||
* @see CommandHelper
|
||||
|
||||
@@ -19,7 +19,7 @@ namespace wpi::cmd {
|
||||
* <p>Note: ALWAYS create a subclass by extending CommandHelper<Base, Subclass>,
|
||||
* or decorators will not function!
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
template <std::derived_from<Command> Base, typename CRTP>
|
||||
class CommandHelper : public Base {
|
||||
|
||||
@@ -32,7 +32,7 @@ class Subsystem;
|
||||
* with the scheduler using RegisterSubsystem() in order for their Periodic()
|
||||
* methods to be called and for their default commands to be scheduled.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class CommandScheduler final
|
||||
: public wpi::util::Sendable,
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see ScheduleCommand
|
||||
*/
|
||||
|
||||
@@ -21,7 +21,7 @@ namespace wpi::cmd {
|
||||
* Note that the supplier <i>must</i> create a new Command each call. For
|
||||
* selecting one of a preallocated set of commands, use SelectCommand.
|
||||
*
|
||||
* <p>This class is provided by the NewCommands VendorDep
|
||||
* <p>This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class DeferredCommand : public CommandHelper<Command, DeferredCommand> {
|
||||
public:
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace wpi::cmd {
|
||||
* complexity it is usually better practice to write a proper class for it than
|
||||
* to inline it.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class FunctionalCommand : public CommandHelper<Command, FunctionalCommand> {
|
||||
public:
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace wpi::cmd {
|
||||
* the same iteration of the scheduler. Users can either pass in a Runnable and
|
||||
* a set of requirements, or else subclass this command if desired.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class InstantCommand : public CommandHelper<FunctionalCommand, InstantCommand> {
|
||||
public:
|
||||
|
||||
@@ -23,7 +23,7 @@ namespace wpi::cmd {
|
||||
* make the executed code thread-safe. If you do not know what "thread-safe"
|
||||
* means, that is a good sign that you should not use this class.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class NotifierCommand : public CommandHelper<Command, NotifierCommand> {
|
||||
public:
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class ParallelCommandGroup
|
||||
: public CommandHelper<Command, ParallelCommandGroup> {
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class ParallelDeadlineGroup
|
||||
: public CommandHelper<Command, ParallelDeadlineGroup> {
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class ParallelRaceGroup : public CommandHelper<Command, ParallelRaceGroup> {
|
||||
public:
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace wpi::cmd {
|
||||
/**
|
||||
* A command that prints a string when initialized.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class PrintCommand : public CommandHelper<InstantCommand, PrintCommand> {
|
||||
public:
|
||||
|
||||
@@ -22,7 +22,7 @@ namespace wpi::cmd {
|
||||
* else the composition will cancel itself when the proxy is reached. If this
|
||||
* command is interrupted, it will cancel the command.
|
||||
*
|
||||
* <p>This class is provided by the NewCommands VendorDep
|
||||
* <p>This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class ProxyCommand : public CommandHelper<Command, ProxyCommand> {
|
||||
public:
|
||||
|
||||
@@ -27,7 +27,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* <p>This class is provided by the NewCommands VendorDep
|
||||
* <p>This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class RepeatCommand : public CommandHelper<Command, RepeatCommand> {
|
||||
public:
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace wpi::cmd {
|
||||
* Command.Until() to give it one. If you only wish
|
||||
* to execute a Runnable once, use InstantCommand.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class RunCommand : public CommandHelper<FunctionalCommand, RunCommand> {
|
||||
public:
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace wpi::cmd {
|
||||
* composition will not know about the status of the scheduled commands, and
|
||||
* will treat this command as finishing instantly.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class ScheduleCommand : public CommandHelper<Command, ScheduleCommand> {
|
||||
public:
|
||||
|
||||
@@ -31,7 +31,7 @@ namespace wpi::cmd {
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
template <typename Key>
|
||||
class SelectCommand : public CommandHelper<Command, SelectCommand<Key>> {
|
||||
|
||||
@@ -30,7 +30,7 @@ const size_t invalid_index = std::numeric_limits<size_t>::max();
|
||||
* composition or scheduled individually, and the composition requires all
|
||||
* subsystems its components require.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class SequentialCommandGroup
|
||||
: public CommandHelper<Command, SequentialCommandGroup> {
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace wpi::cmd {
|
||||
* subclass it or use Command.WithTimeout() or Command.Until() to give
|
||||
* it one.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class StartEndCommand
|
||||
: public CommandHelper<FunctionalCommand, StartEndCommand> {
|
||||
|
||||
@@ -33,7 +33,7 @@ class CommandPtr;
|
||||
* SubsystemBase class offers a simple base for user implementations
|
||||
* that handles this.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see Command
|
||||
* @see CommandScheduler
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace wpi::cmd {
|
||||
* A base for subsystems that handles registration in the constructor, and
|
||||
* provides a more intuitive method for setting the default command.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class SubsystemBase : public Subsystem,
|
||||
public wpi::util::Sendable,
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace wpi::cmd {
|
||||
/**
|
||||
* A command that does nothing but takes a specified amount of time to finish.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class WaitCommand : public CommandHelper<Command, WaitCommand> {
|
||||
public:
|
||||
|
||||
@@ -15,7 +15,7 @@ namespace wpi::cmd {
|
||||
* A command that does nothing but ends after a specified match time or
|
||||
* condition. Useful for CommandGroups.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class WaitUntilCommand : public CommandHelper<Command, WaitUntilCommand> {
|
||||
public:
|
||||
|
||||
@@ -11,7 +11,7 @@ namespace wpi::cmd {
|
||||
* A class used to bind command scheduling to gamepad button presses. Can be
|
||||
* composed with other buttons with the operators in Trigger.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see Trigger
|
||||
*/
|
||||
|
||||
@@ -11,7 +11,7 @@ namespace wpi::cmd {
|
||||
* A class used to bind command scheduling to joystick button presses. Can be
|
||||
* composed with other buttons with the operators in Trigger.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see Trigger
|
||||
*/
|
||||
|
||||
@@ -16,7 +16,7 @@ namespace wpi::cmd {
|
||||
/**
|
||||
* A Button that uses a NetworkTable boolean field.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class NetworkButton : public Trigger {
|
||||
public:
|
||||
|
||||
@@ -13,7 +13,7 @@ namespace wpi::cmd {
|
||||
* A class used to bind command scheduling to joystick POV presses. Can be
|
||||
* composed with other buttons with the operators in Trigger.
|
||||
*
|
||||
* This class is provided by the NewCommands VendorDep
|
||||
* This class is provided by the Commands v2 VendorDep
|
||||
*
|
||||
* @see Trigger
|
||||
*/
|
||||
|
||||
@@ -26,7 +26,7 @@ class Command;
|
||||
* <p>Triggers can easily be composed for advanced functionality using the
|
||||
* {@link #operator!}, {@link #operator||}, {@link #operator&&} operators.
|
||||
*
|
||||
* <p>This class is provided by the NewCommands VendorDep
|
||||
* <p>This class is provided by the Commands v2 VendorDep
|
||||
*/
|
||||
class Trigger {
|
||||
public:
|
||||
|
||||
Reference in New Issue
Block a user