Class

org.http4s.rho

Router

Related Doc: package rho

Permalink

case class Router[T <: HList](method: Method, path: PathRule, rules: RequestRule) extends RouteExecutable[T] with HeaderAppendable[T] with RoutingEntity[T] with Decodable[T, Nothing] with RoutePrependable[Router[T]] 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

rules

header validation stack

Linear Supertypes
Serializable, Serializable, Product, Equals, RoutePrependable[Router[T]], 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. RoutePrependable
  7. Decodable
  8. RoutingEntity
  9. HeaderAppendable
  10. RouteExecutable
  11. TypedBuilder
  12. UriConvertible
  13. AnyRef
  14. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Router(method: Method, path: PathRule, rules: RequestRule)

    Permalink

    method

    request methods to match

    path

    path matching stack

    rules

    header validation stack

Type Members

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

    Permalink
    Definition Classes
    RouterHeaderAppendable

Value Members

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

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

    Permalink
    Definition Classes
    AnyRef → Any
  3. def /:(prefix: TypedPath[HNil]): Router[T]

    Permalink

    Prepend the prefix to the path rules

    Prepend the prefix to the path rules

    prefix

    non-capturing prefix to prepend

    returns

    builder with the prefix prepended to the path rules

    Definition Classes
    RouterRoutePrependableRoutingEntity
  4. final def ==(arg0: Any): Boolean

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

    Permalink

    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
  6. final def ^[R2 >: Nothing](decoder: EntityDecoder[R2])(implicit t: scala.reflect.api.JavaUniverse.TypeTag[R2]): CodecRouter[T, R2]

    Permalink

    Decode the body using the EntityDecoder

    Decode the body using the EntityDecoder

    Alias for decoding

    R2

    type of the result.

    decoder

    EntityDecoder to utilize for decoding the body.

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

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

    Permalink

    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
  9. final def asUriTemplate(request: Request): Try[UriTemplate]

    Permalink

    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
  10. def clone(): AnyRef

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

    Permalink

    Decode the body using the EntityDecoder

    Decode the body using the EntityDecoder

    Alias for the ^ operator.

    decoder

    EntityDecoder to utilize for decoding the body.

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

    Permalink
    Definition Classes
    AnyRef
  13. def finalize(): Unit

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

    Permalink
    Definition Classes
    AnyRef → Any
  15. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  16. def makeRoute(action: Action[T]): RhoRoute[T]

    Permalink
    Definition Classes
    RouterRouteExecutable
  17. val method: Method

    Permalink

    request methods to match

    request methods to match

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

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

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

    Permalink
    Definition Classes
    AnyRef
  21. val path: PathRule

    Permalink

    path matching stack

    path matching stack

    Definition Classes
    RouterRoutingEntityTypedBuilder
  22. val rules: RequestRule

    Permalink

    header validation stack

    header validation stack

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

    Permalink

    Provide an action from which to generate a complete route

    Provide an action from which to generate a complete route

    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

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

    Permalink

    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
    HeaderAppendable
  26. final def wait(): Unit

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

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

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

    Permalink

    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 RoutePrependable[Router[T]]

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