Loading...
Searching...
No Matches
libdar::user_interaction_blind Class Reference
API

full implementation class for user_interaction, which shows nothing and assumes answer "no" to any question More...

`#include <user_interaction_blind.hpp>`

Inherits libdar::user_interaction.

## Public Member Functions

| user_interaction_blind (const user_interaction_blind &ref)=default
| user_interaction_blind (user_interaction_blind &&ref) noexcept=default
user_interaction_blind & | operator= (const user_interaction_blind &ref)=default
user_interaction_blind & | operator= (user_interaction_blind &&ref) noexcept=default
Public Member Functions inherited from libdar::user_interaction
| user_interaction (const user_interaction &ref)=default
| user_interaction (user_interaction &&ref) noexcept=default
user_interaction & | operator= (const user_interaction &ref)=default
user_interaction & | operator= (user_interaction &&ref) noexcept=default
void | message (const std::string &message)
void | pause (const std::string &message)
std::string | get_string (const std::string &message, bool echo)
secu_string | get_secu_string (const std::string &message, bool echo)
virtual void | printf (const char *format,...)
| libdar uses this call to format output before sending to the message() method.
bool | cancellation_requested () const
| known whether cancellation was requested for the current thread or an added thread
void | add_thread_to_monitor (pthread_t tid)
| add a thread to monitor
void | remove_thread_from_monitor (pthread_t tid)
| remove a thread from monitoring

## Protected Member Functions

virtual void | inherited_message (const std::string &message) override
virtual bool | inherited_pause (const std::string &message) override
| method used to ask a boolean question to the user.
virtual std::string | inherited_get_string (const std::string &message, bool echo) override
| method used to ask a question that needs an arbitrary answer.
virtual secu_string | inherited_get_secu_string (const std::string &message, bool echo) override
| same a get_string() but uses libdar::secu_string instead of std::string

## Detailed Description

full implementation class for user_interaction, which shows nothing and assumes answer "no" to any question

Definition at line 46 of file user_interaction_blind.hpp.

## Constructor & Destructor Documentation

## user_interaction_blind()

libdar::user_interaction_blind::user_interaction_blind | ( |  | ) |

inline

Definition at line 49 of file user_interaction_blind.hpp.

## Member Function Documentation

## inherited_get_secu_string()

virtual secu_string libdar::user_interaction_blind::inherited_get_secu_string | ( | const std::string & | message,
|  | bool | echo )

inline override protected virtual

same a get_string() but uses libdar::secu_string instead of std::string

Parameters

  [in] | message | is the question to display to the user.
  [in] | echo | is set to false is the answer must not be shown while the user answers.

Returns
  the user's answer.

Note
  messages passed by libdar are not ending with a newline by default its up to the implementation to separate messages by the adequate mean

Implements libdar::user_interaction.

Definition at line 60 of file user_interaction_blind.hpp.

## inherited_get_string()

virtual std::string libdar::user_interaction_blind::inherited_get_string | ( | const std::string & | message,
|  | bool | echo )

inline override protected virtual

method used to ask a question that needs an arbitrary answer.

Parameters

  [in] | message | is the question to display to the user.
  [in] | echo | is set to false is the answer must not be shown while the user answers.

Returns
  the user's answer.

Note
  messages passed by libdar are not ending with a newline by default its up to the implementation to separate messages by the adequate mean

Implements libdar::user_interaction.

Definition at line 59 of file user_interaction_blind.hpp.

## inherited_message()

virtual void libdar::user_interaction_blind::inherited_message | ( | const std::string & | message | ) |

inline override protected virtual

method used to display a warning or a message to the user.

Parameters

  [in] | message | is the message to display.

Note
  messages passed by libdar are not ending with a newline by default its up to the implementation to separate messages by the adequate mean

Implements libdar::user_interaction.

Definition at line 57 of file user_interaction_blind.hpp.

## inherited_pause()

virtual bool libdar::user_interaction_blind::inherited_pause | ( | const std::string & | message | ) |

inline override protected virtual

method used to ask a boolean question to the user.

Parameters

  [in] | message | The boolean question to ask to the user

Returns
  the answer of the user (true/yes or no/false)

Note
  messages passed by libdar are not ending with a newline by default its up to the implementation to separate messages by the adequate mean

Implements libdar::user_interaction.

Definition at line 58 of file user_interaction_blind.hpp.

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

- user_interaction_blind.hpp