8 #ifndef DIAGNOSTIC_CLIENT_LIB_APPL_SRC_COMMON_DIAGNOSTIC_MANAGER_H
9 #define DIAGNOSTIC_CLIENT_LIB_APPL_SRC_COMMON_DIAGNOSTIC_MANAGER_H
11 #include <condition_variable>
22 namespace conversation {
23 class DiagClientConversation;
58 virtual
void Main() noexcept;
73 virtual
void Run() noexcept = 0;
88 std::string_view conversation_name) noexcept = 0;
Class type to contains a value (of type ValueType), or an error (of type ErrorType)
Class to manage Diagnostic Client.
Parent class to create Diagnostic Manager.
virtual void Initialize() noexcept=0
Function to initialize the DiagnosticManager.
virtual void Main() noexcept
Function to manage the whole lifecycle of DiagnosticManager.
virtual void Run() noexcept=0
Function to run DiagnosticManager.
virtual void Shutdown() noexcept=0
Function to shutdown the DiagnosticManager.
DiagnosticManager(const DiagnosticManager &other) noexcept=delete
Deleted copy assignment and copy constructor.
DiagnosticManager() noexcept
Constructs an instance of DiagnosticManager.
virtual conversation::DiagClientConversation GetDiagnosticClientConversation(std::string_view conversation_name) noexcept=0
Function to get required diag client conversation object based on conversation name.
bool exit_requested_
Flag to terminate the main thread.
DiagnosticManager & operator=(const DiagnosticManager &other) noexcept=delete
virtual core_type::Result< diag::client::vehicle_info::VehicleInfoMessageResponseUniquePtr, DiagClient::VehicleInfoResponseError > SendVehicleIdentificationRequest(diag::client::vehicle_info::VehicleInfoListRequestType vehicle_info_request) noexcept=0
Function to send vehicle identification request and get the Diagnostic Server list.
std::condition_variable cond_var_
Conditional variable to block the thread.
DiagnosticManager & operator=(DiagnosticManager &&other) noexcept=delete
DiagnosticManager(DiagnosticManager &&other) noexcept=delete
Deleted move assignment and move constructor.
std::mutex mutex_
For locking critical section of code.
virtual ~DiagnosticManager() noexcept
Destructs an instance of DiagnosticManager.
virtual Result< void > SignalShutdown() noexcept
Function to initiate shutdown of DiagnosticManager.
VehicleAddrInfoRequest VehicleInfoListRequestType
Type alias of request storage type used while sending vehicle identification request.
std::unique_ptr< VehicleInfoMessage > VehicleInfoMessageResponseUniquePtr
The unique_ptr for Vehicle Identification Response Message.