org.http4s.rho

Router

Related Doc: package rho

case class Router[T <: HList](method: Method, path: PathRule, query: QueryRule, headers: HeaderRule) extends RouteExecutable[T] with HeaderAppendable[T] with RoutingEntity[T] with Decodable[T, Nothing] with Product with Serializable

Provides the operations for generating a router

T

cumulative type of the required method for executing the router

method

request methods to match

path

path matching stack

headers

header validation stack

Linear Supertypes
Serializable, Serializable, Product, Equals, Decodable[T, Nothing], RoutingEntity[T], HeaderAppendable[T], RouteExecutable[T], TypedBuilder[T], UriConvertible, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Router
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. Decodable
  7. RoutingEntity
  8. HeaderAppendable
  9. RouteExecutable
  10. TypedBuilder
  11. UriConvertible
  12. AnyRef
  13. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Router(method: Method, path: PathRule, query: QueryRule, headers: HeaderRule)

    method

    request methods to match

    path

    path matching stack

    headers

    header validation stack

Type Members

  1. type HeaderAppendResult[T <: HList] = Router[T]

    Definition Classes
    RouterHeaderAppendable

Value Members

  1. final def !=(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  4. def >>>[T2 <: HList](v: TypedHeader[T2])(implicit prep1: Prepend[T2, T]): Router[Out]

    Append the header to the builder, generating a new typed representation of the route

    Append the header to the builder, generating a new typed representation of the route

    Definition Classes
    RouterHeaderAppendable
  5. final def ^[R2 >: Nothing](decoder: EntityDecoder[R2])(implicit t: scala.reflect.api.JavaUniverse.TypeTag[R2]): CodecRouter[T, R2]

    Alias for decoding

    Alias for decoding

    Definition Classes
    Decodable
  6. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  7. def asUri(request: Request): Try[Uri]

    Converts a route into an Uri.

    Converts a route into an Uri.

    If the conversion fails None is returned. In case your route has multiple paths only one way will be resolved as instance of Uri. If the route is a URI Template but not an URI None will be returned.

    Definition Classes
    UriConvertible
  8. def asUriTemplate(request: Request): Try[UriTemplate]

    Converts a route into an UriTemplate.

    Converts a route into an UriTemplate.

    If the conversion fails None is returned. In case your route has multiple paths only one way will be resolved as instance of UriTemplate.

    Definition Classes
    TypedBuilderUriConvertible
  9. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  10. def decoding[R](decoder: EntityDecoder[R])(implicit t: scala.reflect.api.JavaUniverse.TypeTag[R]): CodecRouter[T, R]

    Decode the body using the EntityDecoder

    Decode the body using the EntityDecoder

    Definition Classes
    RouterDecodable
  11. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  12. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. val headers: HeaderRule

    header validation stack

    header validation stack

    Definition Classes
    RouterRoutingEntityTypedBuilder
  15. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  16. def makeAction[F](f: F, hf: HListToFunc[T, F]): RhoAction[T, F]

    Create a RhoAction from this RouteExecutable with the provided converters

    Create a RhoAction from this RouteExecutable with the provided converters

    Definition Classes
    RouterRouteExecutable
  17. val method: Method

    request methods to match

    request methods to match

    Definition Classes
    RouterRoutingEntityRouteExecutable
  18. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  19. final def notify(): Unit

    Definition Classes
    AnyRef
  20. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  21. val path: PathRule

    path matching stack

    path matching stack

    Definition Classes
    RouterRoutingEntityTypedBuilder
  22. val query: QueryRule

    Untyped AST representation of the query to operate on

    Untyped AST representation of the query to operate on

    Definition Classes
    RouterRoutingEntityTypedBuilder
  23. final def runWith[F, O](f: F)(implicit hf: HListToFunc[T, F]): (Request) ⇒ Task[Option[Response]]

    Provide an action from which to generate a complete route

    Provide an action from which to generate a complete route

    F

    the type of f

    O

    the type of the result generated by f

    f

    "function" used to in compiling the route

    hf

    converter used to join the HList generated by the route to the function f

    returns

    a function Request => Option[Task[Response]] which can be used as a complete route

    Definition Classes
    RouteExecutable
  24. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  25. final def validate[T2 <: HList](header: TypedHeader[T2])(implicit prep: Prepend[T2, T]): HeaderAppendResult[Out]

    Definition Classes
    HeaderAppendable
  26. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  27. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  28. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  29. final def |>>[F, R](f: F)(implicit hf: HListToFunc[T, F], srvc: CompileService[F, R]): R

    Compiles a HTTP request definition into an action

    Compiles a HTTP request definition into an action

    Definition Classes
    RouteExecutable

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from Decodable[T, Nothing]

Inherited from RoutingEntity[T]

Inherited from HeaderAppendable[T]

Inherited from RouteExecutable[T]

Inherited from TypedBuilder[T]

Inherited from UriConvertible

Inherited from AnyRef

Inherited from Any

Ungrouped