Banking_System_Server  1.0.0
Qt-based banking app for user/admin account management, transactions, secure server communication via PostgreSQL/Supabase.
UpdatePasswordRequest Class Reference

The UpdatePasswordRequest class handles password update requests for users. More...

#include <UpdatePasswordRequest.h>

Inheritance diagram for UpdatePasswordRequest:
Inheritance graph
Collaboration diagram for UpdatePasswordRequest:
Collaboration graph

Public Member Functions

 UpdatePasswordRequest ()
 Constructor for the UpdatePasswordRequest class. More...
 
QJsonObject execute (const QJsonObject &jsonObj, QMutex &m) override
 Executes the password update request. More...
 
- Public Member Functions inherited from Request
virtual ~Request ()
 Virtual destructor for the Request class. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Request
bool isDBConnectionValid (DB::DatabaseManager *dbManager)
 Checks if the database connection is valid. More...
 
QJsonObject CreateDBConnectionError (QJsonObject &response, QJsonObject &dataObj)
 Creates a JSON response indicating a database connection error. More...
 
QJsonObject CreateErrorResponse (QJsonObject &response, QJsonObject &dataObj, QString message)
 Creates a generic error JSON response. More...
 

Detailed Description

The UpdatePasswordRequest class handles password update requests for users.

This class processes password update requests, validates user credentials, and updates the password in the database.

Constructor & Destructor Documentation

◆ UpdatePasswordRequest()

UpdatePasswordRequest::UpdatePasswordRequest ( )
inline

Constructor for the UpdatePasswordRequest class.

Initializes the DatabaseManager instance for handling database operations.

Member Function Documentation

◆ execute()

QJsonObject UpdatePasswordRequest::execute ( const QJsonObject &  jsonObj,
QMutex &  m 
)
inlineoverridevirtual

Executes the password update request.

This method processes the JSON request to update the user's password. It validates user credentials and updates the password in the database.

Parameters
jsonObjThe JSON object containing the request data.
mThe mutex to lock during the execution.
Returns
A JSON object containing the response data.

Implements Request.

Here is the call graph for this function:

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