| 248 | self_type operator=(int port); |
| 249 | |
| 250 | self_type |
| 251 | operator=(cripts::string_view str) |
| 252 | { |
| 253 | uint32_t port = 80; |
| 254 | auto result = std::from_chars(str.data(), str.data() + str.size(), port); |
| 255 | |
| 256 | if (result.ec != std::errc::invalid_argument) { |
| 257 | return *this; |
| 258 | } else { |
| 259 | return operator=(port); |
| 260 | } |
| 261 | } |
| 262 | |
| 263 | private: |
| 264 | Url *_owner = nullptr; |