abstract class Directive[L] extends AnyRef
A directive that provides a tuple of values of type L
to create an inner route.
- Source
- Directive.scala
- Alphabetic
- By Inheritance
- Directive
- AnyRef
- Any
- by addByNameNullaryApply
- by addDirectiveApply
- by SingleValueModifiers
- by any2stringadd
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- All
Abstract Value Members
-
abstract
def
tapply(f: (L) ⇒ Route): Route
Calls the inner route with a tuple of extracted values of type
L
.Calls the inner route with a tuple of extracted values of type
L
.tapply
is short for "tuple-apply". Usually, you will use the regularapply
method instead, which is added by an implicit conversion (seeDirective.addDirectiveApply
).
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
def
&(magnet: ConjunctionMagnet[L]): Out
Joins two directives into one which extracts the concatenation of its base directive extractions.
Joins two directives into one which extracts the concatenation of its base directive extractions. NOTE: Extraction joining is an O(N) operation with N being the number of extractions on the right-side.
- def +(other: String): String
-
def
->[B](y: B): (Directive[L], B)
- Implicit
- This member is added by an implicit conversion from Directive[L] to ArrowAssoc[Directive[L]] performed by method ArrowAssoc in scala.Predef. This conversion will take place only if L is a superclass of Any and a subclass of Unit with (Nothing) (L >: Any <: Unit with (Nothing)).
- Definition Classes
- ArrowAssoc
- Annotations
- @inline()
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
apply(v1: ⇒ Route): Route
- Implicit
- This member is added by an implicit conversion from Directive[L] to (⇒ Route) ⇒ Route performed by method addByNameNullaryApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is Unit (L =:= Unit).
- Definition Classes
- Function1
-
def
apply(v1: In): Route
- Implicit
- This member is added by an implicit conversion from Directive[L] to (In) ⇒ Route performed by method addDirectiveApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is context-bounded by akka.http.scaladsl.server.util.ApplyConverter (L: ApplyConverter).
- Definition Classes
- Function1
-
def
as[A](constructor: ConstructFromTuple[L, A]): Directive1[A]
Converts this directive into one which, instead of a tuple of type
L
, creates an instance of typeA
(which is usually a case class). -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
compose[A](g: (A) ⇒ ⇒ Route): (A) ⇒ Route
- Implicit
- This member is added by an implicit conversion from Directive[L] to (⇒ Route) ⇒ Route performed by method addByNameNullaryApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is Unit (L =:= Unit).
- Definition Classes
- Function1
- Annotations
- @unspecialized()
-
def
compose[A](g: (A) ⇒ In): (A) ⇒ Route
- Implicit
- This member is added by an implicit conversion from Directive[L] to (In) ⇒ Route performed by method addDirectiveApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is context-bounded by akka.http.scaladsl.server.util.ApplyConverter (L: ApplyConverter).
- Definition Classes
- Function1
- Annotations
- @unspecialized()
- def ensuring(cond: (Directive[L]) ⇒ Boolean, msg: ⇒ Any): Directive[L]
- def ensuring(cond: (Directive[L]) ⇒ Boolean): Directive[L]
- def ensuring(cond: Boolean, msg: ⇒ Any): Directive[L]
- def ensuring(cond: Boolean): Directive[L]
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- implicit val ev: Tuple[L]
-
def
filter(predicate: (T) ⇒ Boolean, rejections: Rejection*): Directive1[T]
- Implicit
- This member is added by an implicit conversion from Directive[L] to SingleValueModifiers[T] performed by method SingleValueModifiers in akka.http.scaladsl.server.Directive. This conversion will take place only if L is (T) (L =:= (T)).
- Definition Classes
- SingleValueModifiers
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
flatMap[R](f: (T) ⇒ Directive[R])(implicit arg0: Tuple[R]): Directive[R]
- Implicit
- This member is added by an implicit conversion from Directive[L] to SingleValueModifiers[T] performed by method SingleValueModifiers in akka.http.scaladsl.server.Directive. This conversion will take place only if L is (T) (L =:= (T)).
- Definition Classes
- SingleValueModifiers
- def formatted(fmtstr: String): String
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
map[R](f: (T) ⇒ R)(implicit tupler: Tupler[R]): Directive[Out]
- Implicit
- This member is added by an implicit conversion from Directive[L] to SingleValueModifiers[T] performed by method SingleValueModifiers in akka.http.scaladsl.server.Directive. This conversion will take place only if L is (T) (L =:= (T)).
- Definition Classes
- SingleValueModifiers
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
recover[R >: L](recovery: (Seq[Rejection]) ⇒ Directive[R])(implicit arg0: Tuple[R]): Directive[R]
Creates a new directive that is able to recover from rejections that were produced by
this
Directive **before the inner route was applied**. -
def
recoverPF[R >: L](recovery: PartialFunction[Seq[Rejection], Directive[R]])(implicit arg0: Tuple[R]): Directive[R]
Variant of
recover
that only recovers from rejections handled by the given PartialFunction. -
def
require(predicate: (T) ⇒ Boolean, rejections: Rejection*): Directive0
- Implicit
- This member is added by an implicit conversion from Directive[L] to SingleValueModifiers[T] performed by method SingleValueModifiers in akka.http.scaladsl.server.Directive. This conversion will take place only if L is (T) (L =:= (T)).
- Definition Classes
- SingleValueModifiers
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
tfilter(predicate: (L) ⇒ Boolean, rejections: Rejection*): Directive[L]
Creates a new directive of the same type, which passes if the given predicate matches the current extractions or rejects with the given rejections.
-
def
tflatMap[R](f: (L) ⇒ Directive[R])(implicit arg0: Tuple[R]): Directive[R]
Flatmaps this directive using the given function.
-
def
tmap[R](f: (L) ⇒ R)(implicit tupler: Tupler[R]): Directive[Out]
Maps over this directive using the given function, which can produce either a tuple or any other value (which will then we wrapped into a scala.Tuple1).
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
trequire(predicate: (L) ⇒ Boolean, rejections: Rejection*): Directive0
Creates a new akka.http.scaladsl.server.Directive0, which passes if the given predicate matches the current extractions or rejects with the given rejections.
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
def
|[R >: L](that: Directive[R]): Directive[R]
Joins two directives into one which runs the second directive if the first one rejects.
-
def
→[B](y: B): (Directive[L], B)
- Implicit
- This member is added by an implicit conversion from Directive[L] to ArrowAssoc[Directive[L]] performed by method ArrowAssoc in scala.Predef. This conversion will take place only if L is a superclass of Any and a subclass of Unit with (Nothing) (L >: Any <: Unit with (Nothing)).
- Definition Classes
- ArrowAssoc
Shadowed Implicit Value Members
-
def
andThen[A](g: (Route) ⇒ A): (⇒ Route) ⇒ A
- Implicit
- This member is added by an implicit conversion from Directive[L] to (⇒ Route) ⇒ Route performed by method addByNameNullaryApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is Unit (L =:= Unit).
- Shadowing
- This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
To access this member you can use a type ascription:(directive: (⇒ Route) ⇒ Route).andThen(g)
- Definition Classes
- Function1
- Annotations
- @unspecialized()
-
def
andThen[A](g: (Route) ⇒ A): (In) ⇒ A
- Implicit
- This member is added by an implicit conversion from Directive[L] to (In) ⇒ Route performed by method addDirectiveApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is context-bounded by akka.http.scaladsl.server.util.ApplyConverter (L: ApplyConverter).
- Shadowing
- This implicitly inherited member is ambiguous. One or more implicitly inherited members have similar signatures, so calling this member may produce an ambiguous implicit conversion compiler error.
To access this member you can use a type ascription:(directive: (In) ⇒ Route).andThen(g)
- Definition Classes
- Function1
- Annotations
- @unspecialized()
-
def
toString(): String
- Implicit
- This member is added by an implicit conversion from Directive[L] to (⇒ Route) ⇒ Route performed by method addByNameNullaryApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is Unit (L =:= Unit).
- Shadowing
- This implicitly inherited member is shadowed by one or more members in this class.
To access this member you can use a type ascription:(directive: (⇒ Route) ⇒ Route).toString()
- Definition Classes
- Function1 → AnyRef → Any
-
def
toString(): String
- Implicit
- This member is added by an implicit conversion from Directive[L] to (In) ⇒ Route performed by method addDirectiveApply in akka.http.scaladsl.server.Directive. This conversion will take place only if L is context-bounded by akka.http.scaladsl.server.util.ApplyConverter (L: ApplyConverter).
- Shadowing
- This implicitly inherited member is shadowed by one or more members in this class.
To access this member you can use a type ascription:(directive: (In) ⇒ Route).toString()
- Definition Classes
- Function1 → AnyRef → Any