Exception Class

class UrlSyntaxException

public class UrlSyntaxException <: Exception {
    public init(reason: String)
    public init(input: String, reason: String)
}

Description: Specifies the URL parsing exception class.

Parent Type:

init(String)

public init(reason: String)

Description: Constructs a UrlSyntaxException instance according to the error cause.

Parameters:

  • reason: String: cause of the parsing error

init(String, String)

public init(input: String, reason: String)

Description: Constructs a UrlSyntaxException instance according to the URL and error cause.

Parameters:

  • input: String: native URL or its segments
  • reason: String: cause of the parsing error

init(String, String, String)

public init(input: String, reason: String, pos: String)

Description: Constructs a UrlSyntaxException instance according to the URL string, the error cause, and the part that fails to be parsed.

Parameters:

  • input: String: native URL or its segments
  • reason: String: cause of the parsing error
  • pos: String: the part that fails to be parsed in the given URL string