klyn.net.URL.URL
constructor
public URL(spec as String) throws MalformedURLException:
Description

Parses a URL string.

Parameters
ParameterDescription
specAbsolute URL.
Throws
  • MalformedURLException when the input is invalid.
Example
import klyn.net

url = URL("https://example.com/index.html")
print(url.path)