#### PyKDE - Python Bindings for KDE

# class KURL |
Table of contents
Modules
tdecore Classes
All Classes

Module | tdecore
Class | KURL
Inherits |

### enums

- AdjustementFlags = {NoAdjustements, StripFileProtocol }
- QueryItemsOptions = {CaseInsensitiveKeys }
- URIMode = {Auto, Invalid, RawURI, URL, Mailto }

### methods

- KURL ()

  returns a KURL instance

- KURL (url, encoding_hint = 0)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  url | TQString |
  encoding_hint | int | 0

- KURL (url, encoding_hint = 0)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  url | char |
  encoding_hint | int | 0

- KURL (url, encoding_hint = 0)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  url | TQCString |
  encoding_hint | int | 0

- KURL (u)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  u | KURL |

- KURL (u)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  u | TQUrl |

- KURL (_baseurl, _rel_url, encoding_hint = 0)

  returns a KURL instance
  Argument | Type | Default
  --- | --- | ---
  _baseurl | KURL |
  _rel_url | TQString |
  encoding_hint | int | 0

- addPath (txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  txt | TQString |

- addQueryItem (_item, _value, encoding_hint = 0)

  returns nothing
  In versions KDE 3.1.0 and above only
  Argument | Type | Default
  --- | --- | ---
  _item | TQString |
  _value | TQString |
  encoding_hint | int | 0

- adjustPath (_trailing)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _trailing | int |

- cd (_dir)

  returns (bool)
  Argument | Type | Default
  --- | --- | ---
  _dir | TQString |

- cleanPath (cleanDirSeparator = 0)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  cleanDirSeparator | bool | 0

- cmp (u, ignore_trailing = 0)

  returns (bool)
  Argument | Type | Default
  --- | --- | ---
  u | KURL |
  ignore_trailing | bool | 0

- decode_string (str, encoding_hint = 0)

  returns (TQString)
  static
  Argument | Type | Default
  --- | --- | ---
  str | TQString |
  encoding_hint | int | 0

- directory (_strip_trailing_slash_from_result = 1, _ignore_trailing_slash_in_path = 1)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _strip_trailing_slash_from_result | bool | 1
  _ignore_trailing_slash_in_path | bool | 1

- encode_string (str, encoding_hint = 0)

  returns (TQString)
  static
  Argument | Type | Default
  --- | --- | ---
  str | TQString |
  encoding_hint | int | 0

- encode_string_no_slash (str, encoding_hint = 0)

  returns (TQString)
  static
  Argument | Type | Default
  --- | --- | ---
  str | TQString |
  encoding_hint | int | 0

- encodedHtmlRef ()

  returns (TQString)

- encodedPathAndQuery (_trailing = 0, _no_empty_path = 0, encoding_hint = 0)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _trailing | int | 0
  _no_empty_path | bool | 0
  encoding_hint | int | 0

- equals (u, ignore_trailing = 0)

  returns (bool)
  In versions KDE 3.1.0 and above only
  Argument | Type | Default
  --- | --- | ---
  u | KURL |
  ignore_trailing | bool | 0

- fileEncoding ()

  returns (TQString)

- fileName (_ignore_trailing_slash_in_path = 1)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _ignore_trailing_slash_in_path | bool | 1

- filename (_ignore_trailing_slash_in_path = 1)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _ignore_trailing_slash_in_path | bool | 1

- fromPathOrURL (text)

  returns (KURL)
  In versions KDE 3.1.0 and above only
  static
  Argument | Type | Default
  --- | --- | ---
  text | TQString |

- hasHTMLRef ()

  returns (bool)

- hasHost ()

  returns (bool)

- hasPass ()

  returns (bool)

- hasPath ()

  returns (bool)

- hasRef ()

  returns (bool)

- hasSubURL ()

  returns (bool)

- hasUser ()

  returns (bool)

- host ()

  returns (TQString)

- htmlRef ()

  returns (TQString)

- htmlURL ()

  returns (TQString)
  In versions KDE 3.0.1 and above only

- isEmpty ()

  returns (bool)

- isLocalFile ()

  returns (bool)

- isMalformed ()

  returns (bool)

- isParentOf (u)

  returns (bool)
  Argument | Type | Default
  --- | --- | ---
  u | KURL |

- isRelativeURL (_url)

  returns (bool)
  static
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |

- isValid ()

  returns (bool)

- join (_list)

  returns (KURL)
  static
  Argument | Type | Default
  --- | --- | ---
  _list | KURL.List |

- parse (_url, encoding_hint = 0)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |
  encoding_hint | int | 0

- parseMailto (_url, encoding_hint = 0)

  returns nothing
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |
  encoding_hint | int | 0

- parseRawURI (_url, encoding_hint = 0)

  returns nothing
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |
  encoding_hint | int | 0

- parseURL (_url, encoding_hint = 0)

  returns nothing
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |
  encoding_hint | int | 0

- pass_ ()

  returns (TQString)
  Renamed: was ' pass ' in C++

- path ()

  returns (TQString)

- path (_trailing)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _trailing | int |

- pathOrURL ()

  returns (TQString)
  In versions KDE 3.4.0 and above only

- port ()

  returns (ushort)

- prettyURL (_trailing = 0)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _trailing | int | 0

- prettyURL (_trailing, _flags)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _trailing | int |
  _flags | KURL.AdjustementFlags |

- protocol ()

  returns (TQString)

- query ()

  returns (TQString)

- queryItem (item)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  item | TQString |

- queryItem (item, encoding_hint)

  returns (TQString)
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  item | TQString |
  encoding_hint | int |

- queryItems (options = 0)

  returns (TQMap)
  In versions KDE 3.1.0 and above only
  Argument | Type | Default
  --- | --- | ---
  options | int | 0

- queryItems (options, encoding_hint)

  returns (TQMap)
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  options | int |
  encoding_hint | int |

- ref ()

  returns (TQString)

- relativePath (base_dir, path)

  returns (TQString) isParent (bool)
  In versions KDE 3.2.0 and above only
  static
  Argument | Type | Default
  --- | --- | ---
  base_dir | TQString |
  path | TQString |

- relativeURL (base_url, url, encoding_hint = 0)

  returns (TQString)
  In versions KDE 3.2.0 and above only
  static
  Argument | Type | Default
  --- | --- | ---
  base_url | KURL |
  url | KURL |
  encoding_hint | int | 0

- removeQueryItem (_item)

  returns nothing
  In versions KDE 3.1.0 and above only
  Argument | Type | Default
  --- | --- | ---
  _item | TQString |

- reset ()

  returns nothing

- setDirectory (dir)

  returns nothing
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  dir | TQString |

- setEncodedPath (_txt, encoding_hint = 0)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |
  encoding_hint | int | 0

- setEncodedPathAndQuery (_txt, encoding_hint = 0)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |
  encoding_hint | int | 0

- setFileEncoding (encoding)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  encoding | TQString |

- setFileName (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- setHTMLRef (_ref)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _ref | TQString |

- setHost (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- setPass (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- setPath (path)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  path | TQString |

- setPort (_p)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _p | ushort |

- setProtocol (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- setQuery (_txt, encoding_hint = 0)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |
  encoding_hint | int | 0

- setRef (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- setUser (_txt)

  returns nothing
  Argument | Type | Default
  --- | --- | ---
  _txt | TQString |

- split (_url)

  returns (KURL.List)
  static
  Argument | Type | Default
  --- | --- | ---
  _url | TQString |

- split (_url)

  returns (KURL.List)
  static
  Argument | Type | Default
  --- | --- | ---
  _url | KURL |

- upURL ()

  returns (KURL)

- uriMode ()

  returns (int)
  In versions KDE 3.2.0 and above only

- uriModeForProtocol (protocol)

  returns (KURL.URIMode)
  In versions KDE 3.2.0 and above only
  static
  Argument | Type | Default
  --- | --- | ---
  protocol | TQString |

- url (_trailing = 0, encoding_hint = 0)

  returns (TQString)
  Argument | Type | Default
  --- | --- | ---
  _trailing | int | 0
  encoding_hint | int | 0

- user ()

  returns (TQString)

## operators

- operator != (a0)

  returns (bool)
  In versions KDE 3.1.4 and above only
  Argument | Type | Default
  --- | --- | ---
  a0 | KURL |

- operator != (a0)

  returns (bool)
  In versions KDE 3.1.4 and above only
  Argument | Type | Default
  --- | --- | ---
  a0 | TQString |

- operator < (a0)

  returns (bool)
  In versions KDE 3.2.0 and above only
  Argument | Type | Default
  --- | --- | ---
  a0 | KURL |

- operator == (a0)

  returns (bool)
  In versions KDE 3.1.4 and above only
  Argument | Type | Default
  --- | --- | ---
  a0 | KURL |

- operator == (a0)

  returns (bool)
  In versions KDE 3.1.4 and above only
  Argument | Type | Default
  --- | --- | ---
  a0 | TQString |