mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
Remove static import usage in SelectCommand example (#2442)
This commit is contained in:
committed by
GitHub
parent
184fae4ba5
commit
f6df9217b6
@@ -1,5 +1,5 @@
|
||||
/*----------------------------------------------------------------------------*/
|
||||
/* Copyright (c) 2018-2019 FIRST. All Rights Reserved. */
|
||||
/* Copyright (c) 2018-2020 FIRST. All Rights Reserved. */
|
||||
/* Open Source Software - may be modified and shared by FRC teams. The code */
|
||||
/* must be accompanied by the FIRST BSD license file in the root directory of */
|
||||
/* the project. */
|
||||
@@ -15,8 +15,6 @@ import edu.wpi.first.wpilibj2.command.Command;
|
||||
import edu.wpi.first.wpilibj2.command.PrintCommand;
|
||||
import edu.wpi.first.wpilibj2.command.SelectCommand;
|
||||
|
||||
import static java.util.Map.entry;
|
||||
|
||||
/**
|
||||
* This class is where the bulk of the robot should be declared. Since Command-based is a
|
||||
* "declarative" paradigm, very little robot logic should actually be handled in the {@link Robot}
|
||||
@@ -43,9 +41,9 @@ public class RobotContainer {
|
||||
new SelectCommand(
|
||||
// Maps selector values to commands
|
||||
Map.ofEntries(
|
||||
entry(CommandSelector.ONE, new PrintCommand("Command one was selected!")),
|
||||
entry(CommandSelector.TWO, new PrintCommand("Command two was selected!")),
|
||||
entry(CommandSelector.THREE, new PrintCommand("Command three was selected!"))
|
||||
Map.entry(CommandSelector.ONE, new PrintCommand("Command one was selected!")),
|
||||
Map.entry(CommandSelector.TWO, new PrintCommand("Command two was selected!")),
|
||||
Map.entry(CommandSelector.THREE, new PrintCommand("Command three was selected!"))
|
||||
),
|
||||
this::select
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user