Audacity 3.2.0
|
A type of factory for Commands of various sorts. More...
#include <CommandBuilder.h>
Public Member Functions | |
CommandBuilder (AudacityProject &project, const wxString &cmdString) | |
CommandBuilder (AudacityProject &project, const wxString &cmdName, const wxString &cmdParams) | |
~CommandBuilder () | |
bool | WasValid () |
OldStyleCommandPointer | GetCommand () |
wxString | GetResponse () |
Private Member Functions | |
void | Failure (const wxString &msg={}) |
void | Success (const OldStyleCommandPointer &cmd) |
void | BuildCommand (AudacityProject &project, const wxString &cmdName, const wxString &cmdParams) |
void | BuildCommand (AudacityProject &project, const wxString &cmdString) |
Private Attributes | |
bool | mValid |
ResponseTargetPointer | mResponse |
OldStyleCommandPointer | mCommand |
wxString | mError |
A type of factory for Commands of various sorts.
CommandBuilder has the task of deciding what command is meant by a given command string, and producing a suitable command object. For now, it doesn't actually do any processing - it just passes everything on to the BatchCommand system by constructing BatchCommandEval objects.
Definition at line 32 of file CommandBuilder.h.
CommandBuilder::CommandBuilder | ( | AudacityProject & | project, |
const wxString & | cmdString | ||
) |
Definition at line 33 of file CommandBuilder.cpp.
References BuildCommand(), and project.
CommandBuilder::CommandBuilder | ( | AudacityProject & | project, |
const wxString & | cmdName, | ||
const wxString & | cmdParams | ||
) |
Definition at line 40 of file CommandBuilder.cpp.
References BuildCommand(), params, and project.
CommandBuilder::~CommandBuilder | ( | ) |
Definition at line 47 of file CommandBuilder.cpp.
|
private |
Definition at line 139 of file CommandBuilder.cpp.
References OldStyleCommandType::Create(), factory, Failure(), CommandDirectory::Get(), CommandSignature::GetDefaults(), CommandDirectory::LookUp(), mCommand, mResponse, params, project, Success(), and wxT().
Referenced by BuildCommand(), and CommandBuilder().
|
private |
Definition at line 243 of file CommandBuilder.cpp.
References BuildCommand(), Failure(), project, and wxT().
|
private |
Definition at line 73 of file CommandBuilder.cpp.
References mError, and mValid.
Referenced by BuildCommand().
OldStyleCommandPointer CommandBuilder::GetCommand | ( | ) |
Definition at line 56 of file CommandBuilder.cpp.
References mCommand, and mValid.
Referenced by ExecCommand().
wxString CommandBuilder::GetResponse | ( | ) |
Definition at line 65 of file CommandBuilder.cpp.
References mError, mResponse, mValid, and wxT().
Referenced by ExecCommand().
|
private |
Definition at line 79 of file CommandBuilder.cpp.
References mCommand, and mValid.
Referenced by BuildCommand().
bool CommandBuilder::WasValid | ( | ) |
Definition at line 51 of file CommandBuilder.cpp.
References mValid.
Referenced by ExecCommand().
|
private |
Definition at line 37 of file CommandBuilder.h.
Referenced by BuildCommand(), GetCommand(), and Success().
|
private |
Definition at line 38 of file CommandBuilder.h.
Referenced by Failure(), and GetResponse().
|
private |
Definition at line 36 of file CommandBuilder.h.
Referenced by BuildCommand(), and GetResponse().
|
private |
Definition at line 35 of file CommandBuilder.h.
Referenced by Failure(), GetCommand(), GetResponse(), Success(), and WasValid().