Authorization

scamper.http.auth.Authorization
final class Authorization(request: HttpRequest) extends AnyVal

Adds standardized access to Authorization header.

Attributes

Graph
Supertypes
class AnyVal
trait Matchable
class Any

Members list

Value members

Concrete methods

Gets Authorization header value.

Gets Authorization header value.

Attributes

Throws
HeaderNotFound

if Authorization is not present

Gets Authorization header value if present.

Gets Authorization header value if present.

Attributes

Creates new request with Authorization header removed.

Creates new request with Authorization header removed.

Attributes

Gets basic authorization.

Gets basic authorization.

Attributes

Throws
HttpException

if basic authorization is not present

Gets basic authorization if present.

Gets basic authorization if present.

Attributes

Gets bearer authorization.

Gets bearer authorization.

Attributes

Throws
HttpException

if bearer authorization is not present

Gets bearer authorization if present.

Gets bearer authorization if present.

Attributes

def hasAuthorization: Boolean

Tests for Authorization header.

Tests for Authorization header.

Attributes

def hasBasic: Boolean

Tests for basic authorization.

Tests for basic authorization.

Attributes

def hasBearer: Boolean

Tests for bearer authorization.

Tests for bearer authorization.

Attributes

Creates new request with Authorization header set to supplied value.

Creates new request with Authorization header set to supplied value.

Attributes

def setBasic(token: String): HttpRequest

Creates new request with basic authorization.

Creates new request with basic authorization.

Attributes

def setBasic(user: String, password: String): HttpRequest

Creates new request with basic authorization.

Creates new request with basic authorization.

Attributes

Creates new request with basic authorization.

Creates new request with basic authorization.

Attributes

def setBearer(token: String): HttpRequest

Creates new request with bearer authorization.

Creates new request with bearer authorization.

Attributes

Creates new request with bearer authorization.

Creates new request with bearer authorization.

Attributes