mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 20:27:45 +00:00
AK+Everywhere: Replace "protocol" with "scheme" url helpers
URL had properly named replacements for protocol(), set_protocol() and create_with_file_protocol() already. This patch removes these function and updates all call sites to use the functions named according to the specification. See https://url.spec.whatwg.org/#concept-url-scheme
This commit is contained in:
parent
454bf1fde0
commit
4230dbbb21
61 changed files with 113 additions and 116 deletions
3
AK/URL.h
3
AK/URL.h
|
@ -46,7 +46,6 @@ public:
|
|||
bool is_valid() const { return m_valid; }
|
||||
|
||||
String const& scheme() const { return m_scheme; }
|
||||
String const& protocol() const { return m_scheme; }
|
||||
String const& username() const { return m_username; }
|
||||
String const& password() const { return m_password; }
|
||||
String const& host() const { return m_host; }
|
||||
|
@ -62,7 +61,6 @@ public:
|
|||
bool is_special() const { return is_special_scheme(m_scheme); }
|
||||
|
||||
void set_scheme(String);
|
||||
void set_protocol(String protocol) { set_scheme(move(protocol)); }
|
||||
void set_username(String);
|
||||
void set_password(String);
|
||||
void set_host(String);
|
||||
|
@ -93,7 +91,6 @@ public:
|
|||
|
||||
static URL create_with_url_or_path(String const&);
|
||||
static URL create_with_file_scheme(String const& path, String const& fragment = {}, String const& hostname = {});
|
||||
static URL create_with_file_protocol(String const& path, String const& fragment = {}) { return create_with_file_scheme(path, fragment); }
|
||||
static URL create_with_help_scheme(String const& path, String const& fragment = {}, String const& hostname = {});
|
||||
static URL create_with_data(String mime_type, String payload, bool is_base64 = false) { return URL(move(mime_type), move(payload), is_base64); };
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue