abstract class DSL[F[_]] extends Http4sClientDsl[F]
- Alphabetic
- By Inheritance
- DSL
- Http4sClientDsl
- AnyRef
- Any
- by StringFormat
- by Ensuring
- by ArrowAssoc
- Hide All
- Show All
- Public
- Protected
Type Members
- type /=>[-T, +R] = PartialFunction[T, R]
- type EntityDecoderF[T] = EntityDecoder[F, T]
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- def ->[B](y: B): (DSL[F], B)
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- val LIST: Method
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def defaultErrorHandler[A](request: Request[F])(onErrorsPF: /=>[List[String], F[A]]): (Response[F]) => F[A]
If a
BadRequest
is returned its body will be decoded to aList[String]
and theonErrorPF
will be invoked.If a
BadRequest
is returned its body will be decoded to aList[String]
and theonErrorPF
will be invoked. Allowing to recover for some errors. Otherwise an error will be raised withUnexpectedStatus
.- onErrorsPF
the
PartialFunction
to apply to the BadRequest errors.
- def defaultOnError[R](request: Request[F], response: Response[F]): F[R]
- Attributes
- protected
- def ensuring(cond: (DSL[F]) => Boolean, msg: => Any): DSL[F]
- def ensuring(cond: (DSL[F]) => Boolean): DSL[F]
- def ensuring(cond: Boolean, msg: => Any): DSL[F]
- def ensuring(cond: Boolean): DSL[F]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def execute[A](request: Request[F])(implicit d: EntityDecoderF[A]): F[A]
Executes a request, and on a successful response decodes the body to an
A
.Executes a request, and on a successful response decodes the body to an
A
. On any other responsedefaultErrorHandler
will be called.- A
the type to which the response will be decoded to.
- request
the request to execute.
- def executeOption[A](request: Request[F])(implicit d: EntityDecoderF[A]): F[Option[A]]
Executes a request, and on a successful response decodes the body to an
A
inside a Some.Executes a request, and on a successful response decodes the body to an
A
inside a Some. On a NotFound or Gone response returns a None. On any other responsedefaultErrorHandler
will be called.- A
the type to which the response will be decoded to.
- request
the request to execute.
- def executeOptionWithContextData[Data](request: Request[F])(implicit decoder: EntityDecoder[F, Context[Data]]): F[Option[Data]]
Executes a request for an endpoint which returns
Option[Context[Data]]
but we are only interested in the Context data.Executes a request for an endpoint which returns
Option[Context[Data]]
but we are only interested in the Context data.- Data
the type we are interested in.
- request
the request for the endpoint
- def executeWithContextAuth(request: Request[F]): F[Auth]
Executes a request for an endpoint which returns
Context[_]
but we are only interested in theAuth
.Executes a request for an endpoint which returns
Context[_]
but we are only interested in theAuth
.- request
the request for the endpoint
- def executeWithContextData[Data](request: Request[F])(implicit decoder: EntityDecoder[F, Context[Data]]): F[Data]
Executes a request for an endpoint which returns
Context[Data]
but we are only interested in its data.Executes a request for an endpoint which returns
Context[Data]
but we are only interested in its data.- Data
the type we are interested in.
- request
the request for the endpoint
- def executeWithContextKeys(request: Request[F])(implicit decoder: EntityDecoder[F, Context[Keys]]): F[List[String]]
Executes a request for an endpoint which returns
Context[Keys]
but we are only interested in the keys.Executes a request for an endpoint which returns
Context[Keys]
but we are only interested in the keys.- request
the request for the endpoint
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def formatted(fmtstr: String): String
- def genericExecute[A](request: Request[F])(f: /=>[Response[F], F[A]], onErrorsPF: /=>[List[String], F[A]] = PartialFunction.empty): F[A]
Execute the given
request
, and apply the partial functionf
to the response.Execute the given
request
, and apply the partial functionf
to the response. Iff
is not defined for some response thedefaultErrorHandler
will be called withonErrorsPF
- request
the request to execute.
- onErrorsPF
the
PartialFunction
to apply on the BadRequest errors.
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- implicit def http4sClientSyntaxMethod(method: Method): MethodOps[F]
- Definition Classes
- Http4sClientDsl
- implicit def http4sHeadersDecoder[T](implicit F: Applicative[F], decoder: EntityDecoder[F, T]): EntityDecoder[F, (Headers, T)]
- Definition Classes
- Http4sClientDsl
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- implicit def jsonDecoder[A](implicit arg0: Decoder[A]): EntityDecoder[F, A]
- implicit def jsonEncoder[A](implicit arg0: Encoder[A]): EntityEncoder[F, A]
- val jsonPrinter: Printer
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- implicit def void: EntityDecoder[F, Unit]
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- 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()
Deprecated Value Members
- def →[B](y: B): (DSL[F], B)
- Implicit
- This member is added by an implicit conversion from DSL[F] toArrowAssoc[DSL[F]] performed by method ArrowAssoc in scala.Predef.
- Definition Classes
- ArrowAssoc
- Annotations
- @deprecated
- Deprecated
(Since version 2.13.0) Use
->
instead. If you still wish to display it as one character, consider using a font with programming ligatures such as Fira Code.