mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 07:30:19 +00:00
URL: Add some convenience constructors
This commit is contained in:
parent
ed43770b2f
commit
fb636389d6
Notes:
sideshowbarker
2024-07-19 12:46:08 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/fb636389d64
1 changed files with 8 additions and 0 deletions
8
AK/URL.h
8
AK/URL.h
|
@ -9,6 +9,14 @@ class URL {
|
|||
public:
|
||||
URL() {}
|
||||
URL(const StringView&);
|
||||
URL(const char* string)
|
||||
: URL(StringView(string))
|
||||
{
|
||||
}
|
||||
URL(const String& string)
|
||||
: URL(string.view())
|
||||
{
|
||||
}
|
||||
|
||||
bool is_valid() const { return m_valid; }
|
||||
String protocol() const { return m_protocol; }
|
||||
|
|
Loading…
Reference in a new issue