HostDirectives

pl.iterators.stir.server.directives.HostDirectives
See theHostDirectives companion trait

Attributes

Companion
trait
Source
HostDirectives.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Inherited methods

Extracts the hostname part of the Host request header value.

Extracts the hostname part of the Host request header value.

Attributes

Inherited from:
HostDirectives
Source
HostDirectives.scala
def host(regex: Regex): Directive1[String]

Rejects all requests with a host name that doesn't have a prefix matching the given regular expression. For all matching requests the prefix string matching the regex is extracted and passed to the inner route. If the regex contains a capturing group only the string matched by this group is extracted. If the regex contains more than one capturing group an IllegalArgumentException is thrown.

Rejects all requests with a host name that doesn't have a prefix matching the given regular expression. For all matching requests the prefix string matching the regex is extracted and passed to the inner route. If the regex contains a capturing group only the string matched by this group is extracted. If the regex contains more than one capturing group an IllegalArgumentException is thrown.

Attributes

Inherited from:
HostDirectives
Source
HostDirectives.scala
def host(predicate: String => Boolean): Directive0

Rejects all requests for whose host name the given predicate function returns false.

Rejects all requests for whose host name the given predicate function returns false.

Attributes

Inherited from:
HostDirectives
Source
HostDirectives.scala
def host(hostNames: String*): Directive0

Rejects all requests with a host name different from the given ones.

Rejects all requests with a host name different from the given ones.

Attributes

Inherited from:
HostDirectives
Source
HostDirectives.scala