-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathHttpResource.hpp
More file actions
41 lines (29 loc) · 791 Bytes
/
Copy pathHttpResource.hpp
File metadata and controls
41 lines (29 loc) · 791 Bytes
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
//
//! \file
// WifiESP8266SmartSwitch
//
// Created by Sander van Woensel on 24-02-15.
// Copyright (c) 2016 Sander van Woensel. All rights reserved.
//
#ifndef __ArduinoHttpServer__HttpResource__
#define __ArduinoHttpServer__HttpResource__
#include <WString.h>
namespace ArduinoHttpServer
{
//! The resource requested by a client.
class HttpResource
{
public:
HttpResource(const String& resource);
HttpResource();
HttpResource& operator=(const HttpResource& other);
bool isValid();
String operator[](const unsigned int index) const;
String getArgument(const char *key) const;
const String& toString() const;
private:
static const char RESOURCE_SEPERATOR = '/';
String m_resource;
};
}
#endif // defined(__ArduinoHttpServer__HttpResource__)