Class

spray.routing

RequestContext

Related Doc: package routing

Permalink

case class RequestContext(request: HttpRequest, responder: ActorRef, unmatchedPath: Path) extends Product with Serializable

Immutable object encapsulating the context of an spray.http.HttpRequest as it flows through a spray Route structure.

Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. RequestContext
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new RequestContext(request: HttpRequest, responder: ActorRef, unmatchedPath: Path)

    Permalink

Value Members

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

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

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

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. def complete[T](obj: T)(implicit marshaller: ToResponseMarshaller[T]): Unit

    Permalink

    Completes the request with status "200 Ok" and the response entity created by marshalling the given object using the in-scope marshaller for the type.

  7. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  8. def failWith(error: Throwable): Unit

    Permalink

    Bubbles the given error up the response chain where it is dealt with by the closest handleExceptions directive and its ExceptionHandler, unless the error is a RejectionError.

    Bubbles the given error up the response chain where it is dealt with by the closest handleExceptions directive and its ExceptionHandler, unless the error is a RejectionError. In this case the wrapped rejection is unpacked and "executed".

  9. def finalize(): Unit

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

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

    Permalink
    Definition Classes
    Any
  12. final def ne(arg0: AnyRef): Boolean

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

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

    Permalink
    Definition Classes
    AnyRef
  15. def redirect(uri: Uri, redirectionType: Redirection): Unit

    Permalink

    Completes the request with redirection response of the given type to the given URI.

  16. def reject(rejections: Rejection*): Unit

    Permalink

    Rejects the request with the given rejections.

  17. def reject(rejection: Rejection): Unit

    Permalink

    Rejects the request with the given rejections.

  18. val request: HttpRequest

    Permalink
  19. val responder: ActorRef

    Permalink
  20. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  21. val unmatchedPath: Path

    Permalink
  22. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  25. def withContentNegotiationDisabled: RequestContext

    Permalink

    Removes a potentially existing Accept header from the request headers.

  26. def withDefaultSender(defaultSender: ActorRef): RequestContext

    Permalink

    Returns a copy of this context that automatically sets the sender of all messages to its responder to the given one, if no explicit sender is passed along from upstream.

  27. def withHttpResponseEntityMapped(f: (HttpEntity) ⇒ HttpEntity): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  28. def withHttpResponseHeadersMapped(f: (List[HttpHeader]) ⇒ List[HttpHeader]): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  29. def withHttpResponseMapped(f: (HttpResponse) ⇒ HttpResponse): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  30. def withHttpResponsePartMapped(f: (HttpResponsePart) ⇒ HttpResponsePart): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  31. def withHttpResponsePartMultiplied(f: (HttpResponsePart) ⇒ Seq[HttpResponsePart]): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  32. def withRejectionHandling(f: (List[Rejection]) ⇒ Unit): RequestContext

    Permalink

    Returns a copy of this context with the given rejection handling function chained into the response chain.

  33. def withRejectionsMapped(f: (List[Rejection]) ⇒ List[Rejection]): RequestContext

    Permalink

    Returns a copy of this context with the given rejection transformation function chained into the response chain.

  34. def withRequestMapped(f: (HttpRequest) ⇒ HttpRequest): RequestContext

    Permalink

    Returns a copy of this context with the HttpRequest transformed by the given function.

  35. def withResponder(newResponder: ActorRef): RequestContext

    Permalink

    Returns a copy of this context with responder substituted for the given one.

  36. def withResponderMapped(f: (ActorRef) ⇒ ActorRef): RequestContext

    Permalink

    Returns a copy of this context with the responder transformed by the given function.

  37. def withRouteResponseHandling(f: PartialFunction[Any, Unit]): RequestContext

    Permalink

    Returns a copy of this context with the given function handling a part of the response space.

  38. def withRouteResponseMapped(f: (Any) ⇒ Any): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  39. def withRouteResponseMappedPF(f: PartialFunction[Any, Any]): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  40. def withRouteResponseMultiplied(f: PartialFunction[Any, Seq[Any]]): RequestContext

    Permalink

    Returns a copy of this context with the given response transformation function chained into the response chain.

  41. def withRouteResponseRouting(f: PartialFunction[Any, Route]): RequestContext

    Permalink

    Returns a copy of this context with the given response handling function chained into the response chain.

  42. def withUnmatchedPathMapped(f: (Path) ⇒ Path): RequestContext

    Permalink

    Returns a copy of this context with the unmatchedPath transformed by the given function.

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped