5#ifndef WPINET_URLPARSER_H_
6#define WPINET_URLPARSER_H_
Parses a URL into its constiuent components.
Definition: UrlParser.h:20
std::string_view GetQuery() const
Definition: UrlParser.h:73
bool IsValid() const
Determine if the URL is valid (e.g.
Definition: UrlParser.h:36
std::string_view GetFragment() const
Definition: UrlParser.h:78
bool HasQuery() const
Definition: UrlParser.h:46
bool HasSchema() const
Definition: UrlParser.h:38
UrlParser(std::string_view in, bool isConnect)
Parse a URL.
Definition: UrlParser.h:27
std::string_view GetUserInfo() const
Definition: UrlParser.h:83
bool HasFragment() const
Definition: UrlParser.h:48
bool HasHost() const
Definition: UrlParser.h:40
bool HasUserInfo() const
Definition: UrlParser.h:52
std::string_view GetHost() const
Definition: UrlParser.h:61
std::string_view GetPath() const
Definition: UrlParser.h:68
bool HasPort() const
Definition: UrlParser.h:42
std::string_view GetSchema() const
Definition: UrlParser.h:56
bool HasPath() const
Definition: UrlParser.h:44
unsigned int GetPort() const
Definition: UrlParser.h:66
basic_string_view< char > string_view
Definition: core.h:520
/file This file defines the SmallVector class.
Definition: AprilTagFieldLayout.h:18
void http_parser_url_init(struct http_parser_url *u)
constexpr std::string_view substr(std::string_view str, std::string_view::size_type start, std::string_view::size_type n=std::string_view::npos) noexcept
Returns the substring of str from [start, start + n).
Definition: StringExtras.h:221
int http_parser_parse_url(const char *buf, size_t buflen, int is_connect, struct http_parser_url *u)
@ UF_QUERY
Definition: http_parser.h:332
@ UF_SCHEMA
Definition: http_parser.h:328
@ UF_PATH
Definition: http_parser.h:331
@ UF_FRAGMENT
Definition: http_parser.h:333
@ UF_USERINFO
Definition: http_parser.h:334
@ UF_HOST
Definition: http_parser.h:329
@ UF_PORT
Definition: http_parser.h:330
Definition: http_parser.h:346
uint16_t off
Definition: http_parser.h:351
uint16_t field_set
Definition: http_parser.h:347
uint16_t port
Definition: http_parser.h:348
uint16_t len
Definition: http_parser.h:352
struct wpi::http_parser_url::@759 field_data[UF_MAX]