PathPlannerLib
Loading...
Searching...
No Matches
pathplanner::CommandUtil Class Reference

Static Public Member Functions

static frc2::CommandPtr wrappedEventCommand (std::shared_ptr< frc2::Command > command)
 
static frc2::CommandPtr commandFromJson (const wpi::json &json, bool loadChoreoPaths, bool mirror)
 

Member Function Documentation

◆ commandFromJson()

frc2::CommandPtr CommandUtil::commandFromJson ( const wpi::json &  json,
bool  loadChoreoPaths,
bool  mirror 
)
static

Builds a command from the given JSON.

Parameters
commandJsonthe JSON to build the command from
loadChoreoPathsLoad path commands using choreo trajectories
Returns
a command built from the JSON

◆ wrappedEventCommand()

frc2::CommandPtr CommandUtil::wrappedEventCommand ( std::shared_ptr< frc2::Command >  command)
static

Wraps a command with a functional command that calls the command's initialize, execute, end, and isFinished methods. This allows a command in the event map to be reused multiple times in different command groups

Parameters
commandshared pointer to the command to wrap
Returns
a functional command that wraps the given command

The documentation for this class was generated from the following files: