com.sksamuel.scruffy

Request

Related Doc: package scruffy

case class Request(uri: Uri, method: HttpMethod, entity: Array[Byte], ipAddress: String, headers: List[Header], properties: Map[PropertyKey[Any], Any], session: Option[Session] = None, principal: Option[Principal] = None, response: Response = Response.ok, marshallers: Iterable[Marshaller] = Nil) extends Product with Serializable

Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Request
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Request(uri: Uri, method: HttpMethod, entity: Array[Byte], ipAddress: String, headers: List[Header], properties: Map[PropertyKey[Any], Any], session: Option[Session] = None, principal: Option[Principal] = None, response: Response = Response.ok, marshallers: Iterable[Marshaller] = Nil)

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. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  5. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. def contentType: Option[String]

  7. def cookie(name: String): Option[Cookie]

  8. def cookieValue(name: String): Option[String]

  9. lazy val cookies: List[Cookie]

  10. val entity: Array[Byte]

  11. def entityAs[F](implicit arg0: Manifest[F]): F

    Returns the entity/payload of the request, marshalled into an instance of the given type parameter.

    Returns the entity/payload of the request, marshalled into an instance of the given type parameter. For example, given a case class Customer then request.entityAs[Customer] would attempt to marshall the entity into an instance of Customer.

    The marshaller is chosen by the registered marshallers.

    returns

    the entity as the marshalled type.

  12. def entityStream: InputStream

  13. def entityString: String

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

    Definition Classes
    AnyRef
  15. def etag: Option[String]

  16. def finalize(): Unit

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

    Definition Classes
    AnyRef → Any
  18. def hasCookie(name: String): Boolean

  19. def hasHeader(name: String): Boolean

  20. def hasHeader(name: HeaderName): Boolean

  21. def hasProperty(key: PropertyKey[_]): Boolean

    Returns true if the request has a property value set for the given property key

    Returns true if the request has a property value set for the given property key

    key

    the property to test for

  22. def header(name: String): Option[String]

  23. def header(name: HeaderName): Option[String]

    Returns the optional header for the given HeaderName

    Returns the optional header for the given HeaderName

    returns

    the matching header of None

  24. val headers: List[Header]

  25. val ipAddress: String

  26. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  27. def isSecure: Boolean

  28. val marshallers: Iterable[Marshaller]

  29. def mediaType: Option[MediaType]

  30. val method: HttpMethod

  31. final def ne(arg0: AnyRef): Boolean

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

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

    Definition Classes
    AnyRef
  34. def pathParam(name: String): String

  35. def pathParams: Map[String, String]

  36. val principal: Option[Principal]

  37. val properties: Map[PropertyKey[Any], Any]

  38. def property[T](key: PropertyKey[T]): Option[T]

    Returns the property value for the given property key.

    Returns the property value for the given property key.

    key

    the property to test for

  39. def queryParam(name: String): Option[String]

  40. def queryParams: Seq[Parameter]

  41. def queryParams(name: String): Seq[String]

  42. def queryParamsAs[P <: Product](implicit arg0: Manifest[P]): P

  43. def referer: Option[String]

  44. val response: Response

  45. val session: Option[Session]

  46. def skipped: Request

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

    Definition Classes
    AnyRef
  48. val uri: Uri

  49. def userAgent: Option[String]

  50. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  53. def withHeader(name: HeaderName, value: String): Request

    Adds a header to the request.

    Adds a header to the request. Will replace any existing value for that header.

    returns

    returns the new request with the added header

  54. def withProperty[T](key: PropertyKey[T], value: T): Request

    Adds a property to the request.

    Adds a property to the request. Will replace any existing value for that property.

    returns

    returns the new request with the added property

  55. def withResponse(response: Response): Request

  56. def withSession(session: Session): Request

  57. def withoutHeader(name: HeaderName): Request

  58. def withoutHeader(name: String): Request

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped