|
Sming Framework API
Sming - Open Source framework for high efficiency WiFi SoC ESP8266 native development with C++ language.
|
Class to manage URL instance. More...
#include <Url.h>
Public Member Functions | |
| Url (const Url &url)=default | |
| Url (const String &urlString) | |
| Construct a URL object from a regular escaped string Escaped URL. More... | |
| Url (const char *urlString) | |
| Construct a URL object from a regular null-terminated escaped string Escaped URL. More... | |
| Url (const String &scheme, const String &user, const String &password, const String &host, int port=0, const String &path=nullptr, const String &query=nullptr, const String &fragment=nullptr) | |
| Url & | operator= (String urlString) |
| Copy assignment operator. More... | |
| Url & | operator= (const char *urlString) |
| Copy assignment operator, for C-style strings. More... | |
| String | toString () const |
| Get escaped URL. More... | |
| operator String () const | |
| int | getPort () const |
| Obtain the actual port number to be used. More... | |
| String | getHostWithPort () const |
| Get hostname+port part of URL string. More... | |
| String | getRelativePath () const |
| Get path without leading separator. More... | |
| String | getPathWithQuery () const |
| Get path with any query parameters attached. More... | |
| String | getFileName () const |
| Obtain the filename part of the URL path. More... | |
| void | debugPrintTo (Print &p) const |
| Printable output for debugging. More... | |
Static Public Member Functions | |
| static int | getDefaultPort (const String &scheme) |
| Obtain the default port for a given scheme. More... | |
Public Attributes | |
| String | Scheme |
| without ":" and "//" More... | |
| String | User |
| String | Password |
| String | Host |
| hostname or IP address More... | |
| int | Port = 0 |
| Undefined by default. More... | |
| String | Path |
| with leading "/" More... | |
| HttpParams | Query |
| String | Fragment |
| Without '#'. More... | |
Class to manage URL instance.
|
inline |
Construct a URL object from a regular escaped string Escaped URL.
|
inline |
Construct a URL object from a regular null-terminated escaped string Escaped URL.
|
static |
Obtain the default port for a given scheme.
| int | 0 if scheme is not recognised or has no standard port defined |
| String Url::getHostWithPort | ( | ) | const |
Get hostname+port part of URL string.
| String |
| String Url::getPathWithQuery | ( | ) | const |
Get path with any query parameters attached.
| String |
|
inline |
Obtain the actual port number to be used.
| int |
|
inline |
Get path without leading separator.
| String |
Copy assignment operator.
| urlString | Escaped URL |
|
inline |
Copy assignment operator, for C-style strings.
| urlString | Escaped URL |
| String Url::Fragment |
Without '#'.
| String Url::Host |
hostname or IP address
| String Url::Path |
with leading "/"
| int Url::Port = 0 |
Undefined by default.
| String Url::Scheme |
without ":" and "//"