56 const std::string
getInfo(
const unsigned int indent = 0)
const;
104 const bool isHelp()
const;
162 std::atomic<bool> _running;
Aggregates custom exception headers.
This file contains the definition of the UserControls class, which manages user input and control sta...
Manages a thread for user controls.
const bool isRunning() const
Checks if the thread is running.
void toggleHelp()
Toggles the help state.
void toggleRecording()
Toggles the recording state.
const bool isLooping() const
Checks if looping is enabled.
void startThread()
Starts the thread to run the spamUserChoice function.
void toggleLooping()
Toggles the looping state.
void stopThread(const unsigned int delay=2)
Stops the thread safely.
void togglePlaying()
Toggles the playing state.
const bool isPlaying() const
Checks if playing is enabled.
void setUserChoice(const std::string &userChoice)
Processes the user choice.
const bool isHelp() const
Checks if help is enabled.
const bool isRecording() const
Checks if recording is enabled.
void setEcho(const bool echo)
Sets the echo state.
const std::string getInfo(const unsigned int indent=0) const
Dumps the current state of the variables for debugging purposes.
void setRecording(const bool recording)
Sets the recording state.
const bool hangUpTheCall() const
Checks if the call should be hung up.
void setPlaying(const bool playing)
Sets the playing state.
void setLooping(const bool looping)
Sets the looping state.
const bool isEcho() const
Checks if echo is enabled.
void toggleEcho()
Toggles the echo state.
void showPrompt() const
Displays the prompt to the user.
void setHelp(const bool help)
Sets the help state.
Manages user input and control states.
std::ostream & operator<<(std::ostream &os, const ThreadCapsule &network)
Overloads the stream insertion operator for ThreadCapsule.