1 /**************************************************************************** 2 ** 3 ** DQt - D bindings for the Qt Toolkit 4 ** 5 ** GNU Lesser General Public License Usage 6 ** This file may be used under the terms of the GNU Lesser 7 ** General Public License version 3 as published by the Free Software 8 ** Foundation and appearing in the file LICENSE.LGPL3 included in the 9 ** packaging of this file. Please review the following information to 10 ** ensure the GNU Lesser General Public License version 3 requirements 11 ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. 12 ** 13 ****************************************************************************/ 14 module qt.core.url; 15 extern(C++): 16 17 import qt.config; 18 import qt.core.bytearray; 19 import qt.core.flags; 20 import qt.core.list; 21 import qt.core.metatype; 22 import qt.core.string; 23 import qt.core.stringlist; 24 import qt.core.typeinfo; 25 import qt.helpers; 26 27 /+ #if defined(Q_OS_DARWIN) || defined(Q_QDOC) 28 Q_FORWARD_DECLARE_CF_TYPE(CFURL); 29 Q_FORWARD_DECLARE_OBJC_CLASS(NSURL); 30 #endif +/ 31 32 33 34 extern(C++, class) struct QUrlQuery; 35 extern(C++, class) struct QUrlPrivate; 36 /+ class QDataStream; +/ 37 38 extern(C++, class) struct QUrlTwoFlags(E1, E2) 39 { 40 private: 41 int i; 42 alias Zero = int/+ QUrlTwoFlags:: * +/*; 43 public: 44 pragma(inline, true) this(E1 f) 45 { 46 this.i = f; 47 } 48 pragma(inline, true) this(E2 f) 49 { 50 this.i = f; 51 } 52 pragma(inline, true) this(QFlag f) 53 { 54 this.i = f; 55 } 56 /+pragma(inline, true) this(QFlags!(E1) f) 57 { 58 this.i = f.operatortypenameQFlags<E1E1>::Int (); 59 } 60 pragma(inline, true) this(QFlags!(E2) f) 61 { 62 this.i = f.operatortypenameQFlags<E2E2>::Int (); 63 }+/ 64 @disable this(); 65 pragma(inline, true) this(Zero /+ = 0 +/) 66 { 67 this.i = 0; 68 } 69 70 pragma(inline, true) ref QUrlTwoFlags opOpAssign(string op)(int mask) if(op == "&") { i &= mask; return this; } 71 pragma(inline, true) ref QUrlTwoFlags opOpAssign(string op)(uint mask) if(op == "&") { i &= mask; return this; } 72 pragma(inline, true) ref QUrlTwoFlags opOpAssign(string op)(QUrlTwoFlags f) if(op == "|") { i |= f.i; return this; } 73 pragma(inline, true) ref QUrlTwoFlags opOpAssign(string op)(E1 f) if(op == "|") { i |= f; return this; } 74 pragma(inline, true) ref QUrlTwoFlags opOpAssign(string op)(E2 f) if(op == "|") { i |= f; return this; } 75 /+pragma(inline, true) ref QUrlTwoFlags operator ^=(QUrlTwoFlags f) { i ^= f.i; return this; }+/ 76 /+pragma(inline, true) ref QUrlTwoFlags operator ^=(E1 f) { i ^= f; return this; }+/ 77 /+pragma(inline, true) ref QUrlTwoFlags operator ^=(E2 f) { i ^= f; return this; }+/ 78 79 /+pragma(inline, true) auto opCast(T : QFlags!(E1))() const { return QFlag(i); }+/ 80 /+pragma(inline, true) auto opCast(T : QFlags!(E2))() const { return QFlag(i); }+/ 81 /+pragma(inline, true) auto opCast(T : int)() const { return i; }+/ 82 /+pragma(inline, true) bool operator !() const { return !i; }+/ 83 84 pragma(inline, true) QUrlTwoFlags opBinary(string op)(QUrlTwoFlags f) const if(op == "|") 85 { return QUrlTwoFlags(QFlag(i | f.i)); } 86 pragma(inline, true) QUrlTwoFlags opBinary(string op)(E1 f) const if(op == "|") 87 { return QUrlTwoFlags(QFlag(i | f)); } 88 pragma(inline, true) QUrlTwoFlags opBinary(string op)(E2 f) const if(op == "|") 89 { return QUrlTwoFlags(QFlag(i | f)); } 90 /+pragma(inline, true) QUrlTwoFlags operator ^(QUrlTwoFlags f) const 91 { return QUrlTwoFlags(QFlag(i ^ f.i)); }+/ 92 /+pragma(inline, true) QUrlTwoFlags operator ^(E1 f) const 93 { return QUrlTwoFlags(QFlag(i ^ f)); }+/ 94 /+pragma(inline, true) QUrlTwoFlags operator ^(E2 f) const 95 { return QUrlTwoFlags(QFlag(i ^ f)); }+/ 96 pragma(inline, true) QUrlTwoFlags opBinary(string op)(int mask) const if(op == "&") 97 { return QUrlTwoFlags(QFlag(i & mask)); } 98 pragma(inline, true) QUrlTwoFlags opBinary(string op)(uint mask) const if(op == "&") 99 { return QUrlTwoFlags(QFlag(i & mask)); } 100 pragma(inline, true) QUrlTwoFlags opBinary(string op)(E1 f) const if(op == "&") 101 { return QUrlTwoFlags(QFlag(i & f)); } 102 pragma(inline, true) QUrlTwoFlags opBinary(string op)(E2 f) const if(op == "&") 103 { return QUrlTwoFlags(QFlag(i & f)); } 104 /+pragma(inline, true) QUrlTwoFlags operator ~() const 105 { return QUrlTwoFlags(QFlag(~i)); }+/ 106 107 pragma(inline, true) bool testFlag(E1 f) const { return (i & f) == f && (f != 0 || i == int(f)); } 108 pragma(inline, true) bool testFlag(E2 f) const { return (i & f) == f && (f != 0 || i == int(f)); } 109 } 110 111 /+ template<typename E1, typename E2> 112 class QTypeInfo<QUrlTwoFlags<E1, E2> > : public QTypeInfoMerger<QUrlTwoFlags<E1, E2>, E1, E2> {}; 113 114 class QUrl; 115 // qHash is a friend, but we can't use default arguments for friends (§8.3.6.4) 116 Q_CORE_EXPORT uint qHash(const QUrl &url, uint seed = 0) noexcept; +/ 117 118 @Q_MOVABLE_TYPE @(QMetaType.Type.QUrl) extern(C++, class) struct /+ Q_CORE_EXPORT +/ QUrl 119 { 120 public: 121 enum ParsingMode { 122 TolerantMode, 123 StrictMode, 124 DecodedMode 125 } 126 127 // encoding / toString values 128 enum UrlFormattingOption { 129 None = 0x0, 130 RemoveScheme = 0x1, 131 RemovePassword = 0x2, 132 RemoveUserInfo = UrlFormattingOption.RemovePassword | 0x4, 133 RemovePort = 0x8, 134 RemoveAuthority = UrlFormattingOption.RemoveUserInfo | UrlFormattingOption.RemovePort | 0x10, 135 RemovePath = 0x20, 136 RemoveQuery = 0x40, 137 RemoveFragment = 0x80, 138 // 0x100 was a private code in Qt 4, keep unused for a while 139 PreferLocalFile = 0x200, 140 StripTrailingSlash = 0x400, 141 RemoveFilename = 0x800, 142 NormalizePathSegments = 0x1000 143 } 144 145 enum ComponentFormattingOption { 146 PrettyDecoded = 0x000000, 147 EncodeSpaces = 0x100000, 148 EncodeUnicode = 0x200000, 149 EncodeDelimiters = 0x400000 | 0x800000, 150 EncodeReserved = 0x1000000, 151 DecodeReserved = 0x2000000, 152 // 0x4000000 used to indicate full-decode mode 153 154 FullyEncoded = ComponentFormattingOption.EncodeSpaces | ComponentFormattingOption.EncodeUnicode | ComponentFormattingOption.EncodeDelimiters | ComponentFormattingOption.EncodeReserved, 155 FullyDecoded = ComponentFormattingOption.FullyEncoded | ComponentFormattingOption.DecodeReserved | 0x4000000 156 } 157 /+ Q_DECLARE_FLAGS(ComponentFormattingOptions, ComponentFormattingOption) +/ 158 alias ComponentFormattingOptions = QFlags!(ComponentFormattingOption);/+ #ifdef Q_QDOC 159 private: 160 // We need to let qdoc think that FormattingOptions is a normal QFlags, but 161 // it needs to be a QUrlTwoFlags for compiling default arguments of somme functions. 162 template<typename T> struct QFlags : QUrlTwoFlags<T, ComponentFormattingOption> 163 { using QUrlTwoFlags<T, ComponentFormattingOption>::QUrlTwoFlags; }; 164 public: 165 Q_DECLARE_FLAGS(FormattingOptions, UrlFormattingOption) 166 #else +/ 167 alias FormattingOptions = QUrlTwoFlags!(UrlFormattingOption, ComponentFormattingOption); 168 /+ #endif +/ 169 170 /+this();+/ 171 172 @disable this(this); 173 this(ref const(QUrl) copy); 174 /+ref QUrl operator =(ref const(QUrl) copy);+/ 175 version(QT_NO_URL_CAST_FROM_STRING) 176 { 177 /+ explicit +/this(ref const(QString) url, ParsingMode mode = ParsingMode.TolerantMode); 178 } 179 else 180 { 181 this(ref const(QString) url, ParsingMode mode = ParsingMode.TolerantMode); 182 /+ref QUrl operator =(ref const(QString) url);+/ 183 } 184 /+ QUrl(QUrl &&other) noexcept : d(other.d) 185 { other.d = nullptr; } +/ 186 /+ inline QUrl &operator=(QUrl &&other) noexcept 187 { qSwap(d, other.d); return *this; } +/ 188 ~this(); 189 190 /+ inline void swap(QUrl &other) noexcept { qSwap(d, other.d); } +/ 191 192 void setUrl(ref const(QString) url, ParsingMode mode = ParsingMode.TolerantMode); 193 // QString url(FormattingOptions options = FormattingOptions(cast(QUrlTwoFlags.Zero)(ComponentFormattingOption.PrettyDecoded))) const; 194 // QString toString(FormattingOptions options = FormattingOptions(cast(QUrlTwoFlags.Zero)(ComponentFormattingOption.PrettyDecoded))) const; 195 // QString toDisplayString(FormattingOptions options = FormattingOptions(cast(QUrlTwoFlags.Zero)(ComponentFormattingOption.PrettyDecoded))) const; 196 /+ Q_REQUIRED_RESULT +/ QUrl adjusted(FormattingOptions options) const; 197 198 // QByteArray toEncoded(FormattingOptions options = ComponentFormattingOption.FullyEncoded) const; 199 static QUrl fromEncoded(ref const(QByteArray) url, ParsingMode mode = ParsingMode.TolerantMode); 200 201 enum UserInputResolutionOption { 202 DefaultResolution, 203 AssumeLocalFile 204 } 205 /+ Q_DECLARE_FLAGS(UserInputResolutionOptions, UserInputResolutionOption) +/ 206 alias UserInputResolutionOptions = QFlags!(UserInputResolutionOption); 207 static QUrl fromUserInput(ref const(QString) userInput); 208 // ### Qt6 merge with fromUserInput(QString), by adding = QString() 209 static QUrl fromUserInput(ref const(QString) userInput, ref const(QString) workingDirectory, 210 UserInputResolutionOptions options = UserInputResolutionOption.DefaultResolution); 211 212 bool isValid() const; 213 QString errorString() const; 214 215 bool isEmpty() const; 216 void clear(); 217 218 void setScheme(ref const(QString) scheme); 219 QString scheme() const; 220 221 void setAuthority(ref const(QString) authority, ParsingMode mode = ParsingMode.TolerantMode); 222 QString authority(ComponentFormattingOptions options = ComponentFormattingOption.PrettyDecoded) const; 223 224 void setUserInfo(ref const(QString) userInfo, ParsingMode mode = ParsingMode.TolerantMode); 225 QString userInfo(ComponentFormattingOptions options = ComponentFormattingOption.PrettyDecoded) const; 226 227 void setUserName(ref const(QString) userName, ParsingMode mode = ParsingMode.DecodedMode); 228 QString userName(ComponentFormattingOptions options = ComponentFormattingOption.FullyDecoded) const; 229 230 void setPassword(ref const(QString) password, ParsingMode mode = ParsingMode.DecodedMode); 231 QString password(ComponentFormattingOptions /+ = FullyDecoded +/) const; 232 233 void setHost(ref const(QString) host, ParsingMode mode = ParsingMode.DecodedMode); 234 QString host(ComponentFormattingOptions /+ = FullyDecoded +/) const; 235 /+ #if QT_DEPRECATED_SINCE(5, 15) 236 #if QT_CONFIG(topleveldomain) +/ 237 /+ QT_DEPRECATED +/ QString topLevelDomain(ComponentFormattingOptions options = ComponentFormattingOption.FullyDecoded) const; 238 /+ #endif 239 #endif +/ // QT_DEPRECATED_SINCE(5, 15) 240 241 void setPort(int port); 242 int port(int defaultPort = -1) const; 243 244 void setPath(ref const(QString) path, ParsingMode mode = ParsingMode.DecodedMode); 245 QString path(ComponentFormattingOptions options = ComponentFormattingOption.FullyDecoded) const; 246 QString fileName(ComponentFormattingOptions options = ComponentFormattingOption.FullyDecoded) const; 247 248 bool hasQuery() const; 249 void setQuery(ref const(QString) query, ParsingMode mode = ParsingMode.TolerantMode); 250 void setQuery(ref const(QUrlQuery) query); 251 QString query(ComponentFormattingOptions /+ = PrettyDecoded +/) const; 252 253 bool hasFragment() const; 254 QString fragment(ComponentFormattingOptions options = ComponentFormattingOption.PrettyDecoded) const; 255 void setFragment(ref const(QString) fragment, ParsingMode mode = ParsingMode.TolerantMode); 256 257 /+ Q_REQUIRED_RESULT +/ QUrl resolved(ref const(QUrl) relative) const; 258 259 bool isRelative() const; 260 bool isParentOf(ref const(QUrl) url) const; 261 262 bool isLocalFile() const; 263 static QUrl fromLocalFile(ref const(QString) localfile); 264 QString toLocalFile() const; 265 266 void detach(); 267 bool isDetached() const; 268 269 /+bool operator <(ref const(QUrl) url) const;+/ 270 /+bool operator ==(ref const(QUrl) url) const;+/ 271 /+bool operator !=(ref const(QUrl) url) const;+/ 272 273 bool matches(ref const(QUrl) url, FormattingOptions options) const; 274 275 static QString fromPercentEncoding(ref const(QByteArray) ); 276 static QByteArray toPercentEncoding(ref const(QString) , 277 ref const(QByteArray) exclude = globalInitVar!QByteArray, 278 ref const(QByteArray) include = globalInitVar!QByteArray); 279 /+ #if defined(Q_OS_DARWIN) || defined(Q_QDOC) +/ 280 static if((versionIsSet!("OSX") || versionIsSet!("iOS") || versionIsSet!("TVOS") || versionIsSet!("WatchOS"))) 281 { 282 /+ static QUrl fromCFURL(CFURLRef url); +/ 283 /+ CFURLRef toCFURL() const Q_DECL_CF_RETURNS_RETAINED; +/ 284 /+ static QUrl fromNSURL(const NSURL *url); +/ 285 /+ NSURL *toNSURL() const Q_DECL_NS_RETURNS_AUTORELEASED; +/ 286 } 287 /+ #endif 288 289 #if QT_DEPRECATED_SINCE(5,0) 290 QT_DEPRECATED static QString fromPunycode(const QByteArray &punycode) 291 { return fromAce(punycode); } 292 QT_DEPRECATED static QByteArray toPunycode(const QString &string) 293 { return toAce(string); } 294 295 QT_DEPRECATED inline void setQueryItems(const QList<QPair<QString, QString> > &qry); 296 QT_DEPRECATED inline void addQueryItem(const QString &key, const QString &value); 297 QT_DEPRECATED inline QList<QPair<QString, QString> > queryItems() const; 298 QT_DEPRECATED inline bool hasQueryItem(const QString &key) const; 299 QT_DEPRECATED inline QString queryItemValue(const QString &key) const; 300 QT_DEPRECATED inline QStringList allQueryItemValues(const QString &key) const; 301 QT_DEPRECATED inline void removeQueryItem(const QString &key); 302 QT_DEPRECATED inline void removeAllQueryItems(const QString &key); 303 304 QT_DEPRECATED inline void setEncodedQueryItems(const QList<QPair<QByteArray, QByteArray> > &query); 305 QT_DEPRECATED inline void addEncodedQueryItem(const QByteArray &key, const QByteArray &value); 306 QT_DEPRECATED inline QList<QPair<QByteArray, QByteArray> > encodedQueryItems() const; 307 QT_DEPRECATED inline bool hasEncodedQueryItem(const QByteArray &key) const; 308 QT_DEPRECATED inline QByteArray encodedQueryItemValue(const QByteArray &key) const; 309 QT_DEPRECATED inline QList<QByteArray> allEncodedQueryItemValues(const QByteArray &key) const; 310 QT_DEPRECATED inline void removeEncodedQueryItem(const QByteArray &key); 311 QT_DEPRECATED inline void removeAllEncodedQueryItems(const QByteArray &key); 312 313 QT_DEPRECATED void setEncodedUrl(const QByteArray &u, ParsingMode mode = TolerantMode) 314 { setUrl(fromEncodedComponent_helper(u), mode); } 315 316 QT_DEPRECATED QByteArray encodedUserName() const 317 { return userName(FullyEncoded).toLatin1(); } 318 QT_DEPRECATED void setEncodedUserName(const QByteArray &value) 319 { setUserName(fromEncodedComponent_helper(value)); } 320 321 QT_DEPRECATED QByteArray encodedPassword() const 322 { return password(FullyEncoded).toLatin1(); } 323 QT_DEPRECATED void setEncodedPassword(const QByteArray &value) 324 { setPassword(fromEncodedComponent_helper(value)); } 325 326 QT_DEPRECATED QByteArray encodedHost() const 327 { return host(FullyEncoded).toLatin1(); } 328 QT_DEPRECATED void setEncodedHost(const QByteArray &value) 329 { setHost(fromEncodedComponent_helper(value)); } 330 331 QT_DEPRECATED QByteArray encodedPath() const 332 { return path(FullyEncoded).toLatin1(); } 333 QT_DEPRECATED void setEncodedPath(const QByteArray &value) 334 { setPath(fromEncodedComponent_helper(value)); } 335 336 QT_DEPRECATED QByteArray encodedQuery() const 337 { return toLatin1_helper(query(FullyEncoded)); } 338 QT_DEPRECATED void setEncodedQuery(const QByteArray &value) 339 { setQuery(fromEncodedComponent_helper(value)); } 340 341 QT_DEPRECATED QByteArray encodedFragment() const 342 { return toLatin1_helper(fragment(FullyEncoded)); } 343 QT_DEPRECATED void setEncodedFragment(const QByteArray &value) 344 { setFragment(fromEncodedComponent_helper(value)); } 345 346 private: 347 // helper function for the encodedQuery and encodedFragment functions 348 static QByteArray toLatin1_helper(const QString &string) 349 { 350 if (string.isEmpty()) 351 return string.isNull() ? QByteArray() : QByteArray(""); 352 return string.toLatin1(); 353 } 354 #endif +/ 355 private: 356 static QString fromEncodedComponent_helper(ref const(QByteArray) ba); 357 358 public: 359 static QString fromAce(ref const(QByteArray) ); 360 static QByteArray toAce(ref const(QString) ); 361 static QStringList idnWhitelist(); 362 static QStringList toStringList(ref const(QList!(QUrl)) uris, FormattingOptions options = FormattingOptions(ComponentFormattingOption.PrettyDecoded)); 363 static QList!(QUrl) fromStringList(ref const(QStringList) uris, ParsingMode mode = ParsingMode.TolerantMode); 364 365 static void setIdnWhitelist(ref const(QStringList) ); 366 /+ friend Q_CORE_EXPORT uint qHash(const QUrl &url, uint seed) noexcept; +/ 367 368 private: 369 QUrlPrivate* d; 370 /+ friend class QUrlQuery; +/ 371 372 public: 373 alias DataPtr = QUrlPrivate*; 374 pragma(inline, true) ref DataPtr data_ptr() return { return d; } 375 } 376 /+pragma(inline, true) QFlags!(QUrl.ComponentFormattingOptions.enum_type) operator |(QUrl.ComponentFormattingOptions.enum_type f1, QUrl.ComponentFormattingOptions.enum_type f2)/+noexcept+/{return QFlags!(QUrl.ComponentFormattingOptions.enum_type)(f1)|f2;}+/ 377 /+pragma(inline, true) QFlags!(QUrl.ComponentFormattingOptions.enum_type) operator |(QUrl.ComponentFormattingOptions.enum_type f1, QFlags!(QUrl.ComponentFormattingOptions.enum_type) f2)/+noexcept+/{return f2|f1;}+/ 378 /+pragma(inline, true) QIncompatibleFlag operator |(QUrl.ComponentFormattingOptions.enum_type f1, int f2)/+noexcept+/{return QIncompatibleFlag(int(f1)|f2);}+/ 379 380 /+ Q_DECLARE_SHARED(QUrl) 381 Q_DECLARE_OPERATORS_FOR_FLAGS(QUrl::ComponentFormattingOptions)//Q_DECLARE_OPERATORS_FOR_FLAGS(QUrl::FormattingOptions) 382 383 #ifndef Q_QDOC +/ 384 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.UrlFormattingOption f1, QUrl.UrlFormattingOption f2) 385 { return QUrl.FormattingOptions(cast(QUrlTwoFlags.Zero)(f1)) | f2; }+/ 386 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.UrlFormattingOption f1, QUrl.FormattingOptions f2) 387 { return f2 | f1; }+/ 388 /+pragma(inline, true) QIncompatibleFlag operator |(QUrl.UrlFormattingOption f1, int f2) 389 { return QIncompatibleFlag(int(f1) | f2); }+/ 390 391 // add operators for OR'ing the two types of flags 392 /+pragma(inline, true) ref QUrl.FormattingOptions operator |=(ref QUrl.FormattingOptions i, QUrl.ComponentFormattingOptions f) 393 { i |= QUrl.UrlFormattingOption(cast(int)(f)); return i; }+/ 394 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.UrlFormattingOption i, QUrl.ComponentFormattingOption f) 395 { return i | QUrl.UrlFormattingOption(int(f)); }+/ 396 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.UrlFormattingOption i, QUrl.ComponentFormattingOptions f) 397 { return i | QUrl.UrlFormattingOption(cast(int)(f)); }+/ 398 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.ComponentFormattingOption f, QUrl.UrlFormattingOption i) 399 { return i | QUrl.UrlFormattingOption(int(f)); }+/ 400 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.ComponentFormattingOptions f, QUrl.UrlFormattingOption i) 401 { return i | QUrl.UrlFormattingOption(cast(int)(f)); }+/ 402 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.FormattingOptions i, QUrl.ComponentFormattingOptions f) 403 { return i | QUrl.UrlFormattingOption(cast(int)(f)); }+/ 404 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.ComponentFormattingOption f, QUrl.FormattingOptions i) 405 { return i | QUrl.UrlFormattingOption(int(f)); }+/ 406 /+pragma(inline, true) QUrl.FormattingOptions operator |(QUrl.ComponentFormattingOptions f, QUrl.FormattingOptions i) 407 { return i | QUrl.UrlFormattingOption(cast(int)(f)); }+/ 408 409 //inline QUrl::UrlFormattingOption &operator=(const QUrl::UrlFormattingOption &i, QUrl::ComponentFormattingOptions f) 410 //{ i = int(f); f; } 411 /+ #endif // Q_QDOC 412 413 #ifndef QT_NO_DATASTREAM 414 Q_CORE_EXPORT QDataStream &operator<<(QDataStream &, const QUrl &); 415 Q_CORE_EXPORT QDataStream &operator>>(QDataStream &, QUrl &); 416 #endif 417 418 #ifndef QT_NO_DEBUG_STREAM 419 Q_CORE_EXPORT QDebug operator<<(QDebug, const QUrl &); 420 #endif 421 422 423 #if QT_DEPRECATED_SINCE(5,0) 424 #endif +/ 425