-
Notifications
You must be signed in to change notification settings - Fork 0
/
Context.h
40 lines (36 loc) · 1.1 KB
/
Context.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef CONTEXT_H
#define CONTEXT_H
#include "Complaint.h"
#include "MaitreD.h"
/**
* @class Context
*
* @brief A class that maintains a reference to one of the Complaint strategy objects.
*/
class Context
{
private:
Complaint* type;///< The current complaint strategy.
public:
/**
* @brief Constructor for a Context object.
*
* @param type A pointer to the Complaint object representing the current complaint strategy.
*/
Context(Complaint* type);
/**
* @brief Destructor for the Context object.
*/
virtual ~Context();
/**
* @brief Address a customer complaint with a specified degree of severity.
*
* This function calls the current complaint strategy's AddressComplaint function so that the function
* can be handled accordingly.
*
* @param complaint The description of the customer's complaint.
* @param degree The degree of severity of the complaint.
*/
void AddressComplaint(string complaint, int degree);
};
#endif