-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathResponse.hpp
More file actions
43 lines (37 loc) · 1.61 KB
/
Response.hpp
File metadata and controls
43 lines (37 loc) · 1.61 KB
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
40
41
42
43
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* Response.hpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: fpalumbo <fpalumbo@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/07/18 16:27:50 by jfazi #+# #+# */
/* Updated: 2024/09/05 15:29:37 by fpalumbo ### ########.fr */
/* */
/* ************************************************************************** */
#pragma once
#include "webserv.h"
#include "Parsconfig.hpp"
class Response
{
private:
string httpVersion;
string languages;
string contentLength;
string contentType;
string content;
string statusCode;
string filePath;
Parsconfig config;
SOCKET sock;
public:
Response(string statusCode, SOCKET sock, Parsconfig config, string content);
Response(string statusCode, string filePath, SOCKET sock, Parsconfig config);
~Response();
void setContent();
void setContentType();
void setContentLength();
void setAutoIndex();
void SendFile(const char *filePath);
void send();
};