URLBuilder
class URLBuilder(protocol: URLProtocol, host: String, port: Int, user: String?, password: String?, pathSegments: List<String>, parameters: Parameters, fragment: String, trailingQuery: Boolean)
Content copied to clipboard
A URL builder with all mutable components
Constructors
Link copied to clipboard
fun URLBuilder(protocol: URLProtocol = URLProtocol.HTTP, host: String = "", port: Int = DEFAULT_PORT, user: String? = null, password: String? = null, pathSegments: List<String> = emptyList(), parameters: Parameters = Parameters.Empty, fragment: String = "", trailingQuery: Boolean = false)
Content copied to clipboard
Types
Functions
Properties
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Extensions
Link copied to clipboard
fun URLBuilder.appendEncodedPathSegments(segments: List<String>): URLBuilder
Content copied to clipboard
Adds components to current encodedPath
fun URLBuilder.appendEncodedPathSegments(vararg components: String): URLBuilder
Content copied to clipboard
Adds components to current encodedPath
Link copied to clipboard
Adds components to current encodedPath
Adds components to current encodedPath
Link copied to clipboard
URLBuilder authority.
Link copied to clipboard
Create a copy of this builder. Modifications in a copy is not reflected in the original instance and vise-versa.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun URLBuilder.set(scheme: String? = null, host: String? = null, port: Int? = null, path: String? = null, block: URLBuilder.() -> Unit = {})
Content copied to clipboard
Sets the url parts using the specified scheme, host, port and path. Pass null
to keep existing value in the URLBuilder.