Parameterized

class Parameterized(val authScheme: String, val parameters: List<HeaderValueParam>, val encoding: HeaderValueEncoding = HeaderValueEncoding.QUOTED_WHEN_REQUIRED) : HttpAuthHeader

Describes a parameterized authentication header that is represented by a set of parameters encoded with encoding.

Constructors

Link copied to clipboard
fun Parameterized(authScheme: String, parameters: Map<String, String>, encoding: HeaderValueEncoding = HeaderValueEncoding.QUOTED_WHEN_REQUIRED)
Link copied to clipboard
fun Parameterized(authScheme: String, parameters: List<HeaderValueParam>, encoding: HeaderValueEncoding = HeaderValueEncoding.QUOTED_WHEN_REQUIRED)

Functions

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
fun parameter(name: String): String?

Tries to extract the first value of a parameter name. Returns null when not found.

Link copied to clipboard
open override fun render(): String

Encodes the header with the default HeaderValueEncoding for this header.

open override fun render(encoding: HeaderValueEncoding): String

Encodes the header with a specified encoding.

Link copied to clipboard
open override fun toString(): String

Encodes the header with the default HeaderValueEncoding for this header.

Link copied to clipboard

Copies this Parameterized appending a new parameter name.

Link copied to clipboard

Copies this Parameterized replacing parameters with name assigning new value or appending if no such parameters found. If there were several pairs they will be reduced into a single pair at position of first occurrence discarding following pairs with this name.

Properties

Link copied to clipboard

auth scheme, usually one of AuthScheme

Link copied to clipboard

parameters encoding method, one of HeaderValueEncoding

Link copied to clipboard

a list of auth parameters