Trait/Object

com.nrinaudo.fetch

Request

Related Docs: object Request | package fetch

Permalink

trait Request[A] extends AnyRef

Represents an HTTP request.

Instances are created through the companion object. Once an instance is obtained, the request can be configured through "raw" modification methods (

method

,

headers

...) as well as specialised helpers such as

GET

,

acceptGzip

or

/

.

/ }}}

acceptGzip }}}

GET }}}

headers }}} as

GET

,

acceptGzip

or

/

.

/ }}}

acceptGzip }}}

GET }}}

method }}} as

GET

,

acceptGzip

or

/

.

/ }}}

acceptGzip }}}

GET }}}

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Request
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def apply(body: Option[RequestEntity]): A

    Permalink
  2. abstract def copy(url: Url, method: Method, headers: Headers): Request[A]

    Permalink
    Attributes
    protected
  3. abstract val headers: Headers

    Permalink

    List of HTTP headers of the request.

  4. abstract def map[B](f: (A) ⇒ B): Request[B]

    Permalink

    Applies the specified transformation to the request's eventual response.

    Applies the specified transformation to the request's eventual response.

    Application developers should be wary of a common pitfall: when working with responses that contain instances of ResponseEntity, they should always clean these up, either by reading their content (transforming it to something else or calling ResponseEntity.empty) or explicitly ignoring them (by calling ResponseEntity.ignore).

    This is a common source of issues when mapping error statuses to exceptions: each connection will be kept alive until the remote host decides it has timed out.

  5. abstract val method: Method

    Permalink

    HTTP method of the request.

  6. abstract val url: Url

    Permalink

    URL on which the request will be performed.

Concrete Value Members

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

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

    Permalink
    Definition Classes
    AnyRef → Any
  3. def &[T](param: (String, T))(implicit arg0: ValueWriter[T]): Request[A]

    Permalink
  4. def /(segment: String): Request[A]

    Permalink
  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  6. def ?(value: QueryString): Request[A]

    Permalink
  7. def CONNECT: Request[A]

    Permalink
  8. def DELETE: Request[A]

    Permalink
  9. def GET: Request[A]

    Permalink
  10. def HEAD: Request[A]

    Permalink
  11. def LINK: Request[A]

    Permalink
  12. def OPTIONS: Request[A]

    Permalink
  13. def PATCH: Request[A]

    Permalink
  14. def POST: Request[A]

    Permalink
  15. def PUT: Request[A]

    Permalink
  16. def TRACE: Request[A]

    Permalink
  17. def UNLINK: Request[A]

    Permalink
  18. def accept: Option[Seq[Conneg[MediaType]]]

    Permalink

    Returns the value of this instance's content type preferences.

  19. def accept(types: Conneg[MediaType]*): Request[A]

    Permalink

    Notifies the remote server about response content type preferences.

    Notifies the remote server about response content type preferences.

    This maps to the Accept header.

    types

    list of media types to declare.

  20. def acceptCharset: Option[Seq[Conneg[Charset]]]

    Permalink

    Returns the value of this instance's charset preferences.

  21. def acceptCharset(charsets: Conneg[Charset]*): Request[A]

    Permalink

    Notifies the remote server about response charset preferences.

    Notifies the remote server about response charset preferences.

    This maps to the Accept-Charset header.

    charsets

    list of charsets to declare.

  22. def acceptDeflate: Request[A]

    Permalink

    Notifies the remote server that we accept deflated responses.

  23. def acceptEncoding: Option[Seq[Conneg[Encoding]]]

    Permalink

    Returns the value of this instance's encoding header.

  24. def acceptEncoding(encodings: Conneg[Encoding]*): Request[A]

    Permalink

    Notifies the remote server about transfer encoding preferences.

    Notifies the remote server about transfer encoding preferences.

    This maps to the Accept-Encoding header.

    encodings

    list of encodings to declare.

  25. def acceptGzip: Request[A]

    Permalink

    Notifies the remote server that we accept GZIPed responses.

  26. def acceptLanguage: Option[Seq[Conneg[Language]]]

    Permalink

    Returns the value of this instance's language preferences.

  27. def acceptLanguage(languages: Conneg[Language]*): Request[A]

    Permalink

    Notifies the remote server about response language preferences.

    Notifies the remote server about response language preferences.

    This maps to the Accept-Language header.

    languages

    list of languages to declare.

  28. def apply(body: RequestEntity): A

    Permalink
  29. def apply(): A

    Permalink
  30. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  31. def auth(user: String, pwd: String): Request[A]

    Permalink
  32. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. def date: Option[Date]

    Permalink
  34. def date(date: Date = new Date()): Request[A]

    Permalink
  35. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  36. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  37. def finalize(): Unit

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

    Permalink
    Definition Classes
    AnyRef → Any
  39. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  40. def header[T](name: String)(implicit arg0: ValueReader[T]): Option[T]

    Permalink

    Returns the value of the specified header.

  41. def header[T](name: String, value: T)(implicit arg0: ValueWriter[T]): Request[A]

    Permalink

    Sets the value of the specified header.

    Sets the value of the specified header.

    This method expects an appropriate implicit ValueWriter to be in scope. Standard formats are declared in Headers.

  42. def headers(value: Headers): Request[A]

    Permalink
  43. def ifMatch: Option[Seq[ETag]]

    Permalink
  44. def ifMatch(tags: ETag*): Request[A]

    Permalink
  45. def ifModifiedSince: Option[Date]

    Permalink
  46. def ifModifiedSince(date: Date): Request[A]

    Permalink
  47. def ifNoneMatch: Option[Seq[ETag]]

    Permalink
  48. def ifNoneMatch(tags: ETag*): Request[A]

    Permalink
  49. def ifRange(date: Date): Request[A]

    Permalink
  50. def ifRange(tag: ETag): Request[A]

    Permalink
  51. def ifUnmodifiedSince: Option[Date]

    Permalink
  52. def ifUnmodifiedSince(date: Date): Request[A]

    Permalink
  53. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  54. def maxForwards: Option[Int]

    Permalink
  55. def maxForwards(value: Int): Request[A]

    Permalink
  56. def method(value: Method): Request[A]

    Permalink
  57. final def ne(arg0: AnyRef): Boolean

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

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

    Permalink
    Definition Classes
    AnyRef
  60. def range: Option[Seq[ByteRange]]

    Permalink
  61. def range(ranges: ByteRange*): Request[A]

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

    Permalink
    Definition Classes
    AnyRef
  63. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  64. def url(value: Url): Request[A]

    Permalink
  65. def userAgent: Option[String]

    Permalink
  66. def userAgent(name: String): Request[A]

    Permalink
  67. final def wait(): Unit

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

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

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped