final case class Request(version: Version = Version.Default, method: Method = Method.ANY, url: URL = URL.empty, headers: Headers = Headers.empty, body: Body = Body.empty, remoteAddress: Option[InetAddress] = None) extends HeaderOps[Request] with Product with Serializable
- Self Type
- Request
- Alphabetic
- By Inheritance
- Request
- Serializable
- Product
- Equals
- HeaderOps
- HeaderChecks
- HeaderGetters
- HeaderModifier
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new Request(version: Version = Version.Default, method: Method = Method.ANY, url: URL = URL.empty, headers: Headers = Headers.empty, body: Body = Body.empty, remoteAddress: Option[InetAddress] = None)
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- def ++(that: Request): Request
A right-biased way of combining two requests.
A right-biased way of combining two requests. Most information will be merged, but in cases where this does not make sense (e.g. two non-empty bodies), the information from the right request will be used.
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def addHeader(name: CharSequence, value: CharSequence): Request
- Definition Classes
- HeaderModifier
- final def addHeader(header: Header): Request
- Definition Classes
- HeaderModifier
- final def addHeaders(headers: Headers): Request
- Definition Classes
- HeaderModifier
- def addLeadingSlash: Request
- def addTrailingSlash: Request
Add trailing slash to the path.
- lazy val allHeaders: Headers
Custom headers and headers required by the used Body
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- val body: Body
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @IntrinsicCandidate()
- def collect(implicit trace: Trace): ZIO[Any, Throwable, Request]
Collects the potentially streaming body of the request into a single chunk.
- def cookie(name: String): Option[Cookie]
Returns the cookie with the given name if it exists.
- def cookieWithOrFail[R, E, A](name: String)(missingCookieError: E)(f: (Cookie) => ZIO[R, E, A])(implicit trace: Trace): ZIO[R, E, A]
Uses the cookie with the given name if it exists and runs
fwith the cookie afterwards.Uses the cookie with the given name if it exists and runs
fwith the cookie afterwards.Also, you can set a custom failure value from a missing cookie with
E. - def cookieWithZIO[R, A](name: String)(f: (Cookie) => ZIO[R, Throwable, A])(implicit trace: Trace): ZIO[R, Throwable, A]
Uses the cookie with the given name if it exists and runs
fwith the cookie afterwards. - def cookies: Chunk[Cookie]
Returns all cookies from the request.
- def dropLeadingSlash: Request
- def dropTrailingSlash: Request
Drops trailing slash from the path.
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def flashMessage: Option[String]
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- final def hasContentType(value: CharSequence): Boolean
- Definition Classes
- HeaderChecks
- final def hasFormMultipartContentType: Boolean
- Definition Classes
- HeaderChecks
- final def hasFormUrlencodedContentType: Boolean
- Definition Classes
- HeaderChecks
- final def hasHeader(header: Header): Boolean
- Definition Classes
- HeaderChecks
- final def hasHeader(headerType: HeaderType): Boolean
- Definition Classes
- HeaderChecks
- final def hasHeader(name: CharSequence): Boolean
- Definition Classes
- HeaderChecks
- final def hasJsonContentType: Boolean
- Definition Classes
- HeaderChecks
- final def hasMediaType(mediaType: MediaType): Boolean
- Definition Classes
- HeaderChecks
- final def hasTextPlainContentType: Boolean
- Definition Classes
- HeaderChecks
- final def hasXhtmlXmlContentType: Boolean
- Definition Classes
- HeaderChecks
- final def hasXmlContentType: Boolean
- Definition Classes
- HeaderChecks
- final def header(headerType: HeaderType): Option[HeaderValue]
Gets a header or returns None if the header was not present or it could not be parsed
Gets a header or returns None if the header was not present or it could not be parsed
- Definition Classes
- HeaderGetters
- final def headerOrFail(headerType: HeaderType): Option[Either[String, HeaderValue]]
Gets a header.
Gets a header. If the header is not present, returns None. If the header could not be parsed it returns the parsing error
- Definition Classes
- HeaderGetters
- final def headers(headerType: HeaderType): Chunk[HeaderValue]
- Definition Classes
- HeaderGetters
- val headers: Headers
Returns the headers
Returns the headers
- Definition Classes
- Request → HeaderGetters
- def ignoreBody(implicit trace: Trace): ZIO[Any, Throwable, Request]
Consumes the streaming body fully and then drops it
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val method: Method
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
- def patch(p: Patch): Request
- def path(path: Path): Request
- def path: Path
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- final def rawHeader(headerType: HeaderType): Option[String]
Gets the raw unparsed header value
Gets the raw unparsed header value
- Definition Classes
- HeaderGetters
- final def rawHeader(name: CharSequence): Option[String]
Gets the raw unparsed header value
Gets the raw unparsed header value
- Definition Classes
- HeaderGetters
- val remoteAddress: Option[InetAddress]
- final def removeHeader(name: String): Request
- Definition Classes
- HeaderModifier
- final def removeHeader(headerType: HeaderType): Request
- Definition Classes
- HeaderModifier
- final def removeHeaders(headers: Set[String]): Request
- Definition Classes
- HeaderModifier
- final def setHeaders(headers: Headers): Request
- Definition Classes
- HeaderModifier
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def unnest(prefix: Path): Request
Unnests the request by the specified prefix.
Unnests the request by the specified prefix. If the request URL is not nested at the specified path, then this has no effect on the URL.
- def updateHeaders(update: (Headers) => Headers)(implicit trace: Trace): Request
Updates the headers using the provided function
Updates the headers using the provided function
- Definition Classes
- Request → HeaderModifier
- def updateURL(f: (URL) => URL): Request
- val url: URL
- val version: Version
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])