| <large>libXpertMassCore and libXpertMassGui Developer Documentation</large>

- libXpertMassGui
- MassDataClientServerConfigDlg

# MsXpS::libXpertMassGui::MassDataClientServerConfigDlg Class

class MsXpS::libXpertMassGui::MassDataClientServerConfigDlg

The MassDataClientServerConfigDlg class provides a mass data client-server network connection configuration dialog window. More...

Header: | `#include <MsXpS/libXpertMassGui/MassDataClientServerConfigDlg.hpp>`
Inherits: | QDialog

- List of all members, including inherited members
- MassDataClientServerConfigDlg is part of libXpertMassGui Utilities.

## Public Functions

| MassDataClientServerConfigDlg(QWidget *program_window_p, const QString &applicationName, const QString &description, std::pair<QString, int> server_ip_config = std::pair("", 0))
virtual | ~MassDataClientServerConfigDlg()
void | clientFailingFeedback(const QString &error)
void | message(const QString &message, int timeout = 3000)
void | updateClientConfigurationData(const QString &ip_address, int port_number)

## Protected Functions

void | readSettings(const QString &config_settings_file_path)
void | writeSettings(const QString &config_settings_file_path)

## Reimplemented Protected Functions

virtual void | closeEvent(QCloseEvent *event) override

## Protected Variables

QString | m_applicationName
QWidget * | mp_programWindow
Ui::MassDataClientServerConfigDlg * | mp_ui

## Detailed Description

## Member Function Documentation

### MassDataClientServerConfigDlg::MassDataClientServerConfigDlg(QWidget *program_window_p, const QString &applicationName, const QString &description, std::pair<QString, int> server_ip_config = std::pair("", 0))

Constructs a MassDataClientServerConfigDlg instance.

- program_window_p: the program's main window.
- applicationName: the name of the application, typically massXpert3 or mineXpert3, for example.
- description: the string describing what this dialog window is for (used for the window title).
- server_ip_config: a pair of values, IP address as a string and port number as an integer.

### `[virtual noexcept]` MassDataClientServerConfigDlg::~MassDataClientServerConfigDlg()

Destructs this MassDataClientServerConfigDlg instance.

### void MassDataClientServerConfigDlg::clientFailingFeedback(const QString &error)

Writes the error to the message line edit widget.

After a imeout of 10 seconds, the message is erased.

### `[override virtual protected]` void MassDataClientServerConfigDlg::closeEvent(QCloseEvent *event)

Reimplements: QDialog::closeEvent(QCloseEvent *e).

Does not close the window, just hides it (event is not used).

### void MassDataClientServerConfigDlg::message(const QString &message, int timeout = 3000)

Writes the message to the message line edit widget.

After timeout milliseconds, the message is erased. By default that timeout is 3000 ms.

### `[protected]` void MassDataClientServerConfigDlg::readSettings(const QString &config_settings_file_path)

Reads the settings of this dialog window from config_settings_file_path.

### void MassDataClientServerConfigDlg::updateClientConfigurationData(const QString &ip_address, int port_number)

Update the client configuration on the basis of ip_address and port_number. This is the configuration of the server to which this client will connect.

### `[protected]` void MassDataClientServerConfigDlg::writeSettings(const QString &config_settings_file_path)

Writes the settings of the dialog window to config_settings_file_path for later restoration.

## Member Variable Documentation

### QString MassDataClientServerConfigDlg::m_applicationName

This variable holds the name of the application.

### QWidget *MassDataClientServerConfigDlg::mp_programWindow

This variable holds the main program window.

### Ui::MassDataClientServerConfigDlg *MassDataClientServerConfigDlg::mp_ui

This variable holds the graphical user interface definition.