Definition at line 121 of file url.h.
121 {
123 return;
124 }
125
126 fl::string_view src(
mUrl.c_str(),
mUrl.size());
128
129
130 fl::size sep = src.find("://");
132
133 mUrl = fl::string(
"https://") +
mUrl;
135 src = fl::string_view(
mUrl.c_str(),
mUrl.size());
136 sep = src.find("://");
137 }
140
141
142 fl::size authStart =
pos;
143 fl::size authEnd = src.size();
144 for (fl::size i =
pos; i < src.size(); ++i) {
145 char c = src[i];
146 if (c == '/' || c == '?' || c == '#') {
147 authEnd = i;
148 break;
149 }
150 }
152
153
154 parseAuthority(src.substr(authStart, authEnd - authStart), authStart);
155
157
158
159 if (
pos < src.size() && src[
pos] ==
'/') {
160 fl::size pathStart =
pos;
161 fl::size pathEnd = src.size();
162 for (fl::size i =
pos; i < src.size(); ++i) {
163 if (src[i] == '?' || src[i] == '#') {
164 pathEnd = i;
165 break;
166 }
167 }
170 }
171
172
173 if (
pos < src.size() && src[
pos] ==
'?') {
175 fl::size qStart =
pos;
176 fl::size qEnd = src.size();
177 fl::size hashPos = src.find(
'#',
pos);
179 qEnd = hashPos;
180 }
183 }
184
185
186 if (
pos < src.size() && src[
pos] ==
'#') {
189 }
190
192 }
static constexpr fl::size npos
static Span makeSpan(fl::size off, fl::size len) FL_NOEXCEPT
void parseAuthority(fl::string_view auth, fl::size baseOff) FL_NOEXCEPT
References fl::string_view::find(), FL_NOEXCEPT, makeSpan(), mAuthority, mFragment, mPath, mQuery, mRepaired, mScheme, mUrl, mValid, fl::string_view::npos, parseAuthority(), pos, fl::string_view::size(), and fl::string_view::substr().
Referenced by url(), url(), and url().