Class

io.chrisdavenport.ember.client

EmberClient

Related Doc: package client

Permalink

final class EmberClient[F[_]] extends Client[F]

Linear Supertypes
Client[F], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. EmberClient
  2. Client
  3. AnyRef
  4. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

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. final def eq(arg0: AnyRef): Boolean

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

    Permalink
    Definition Classes
    AnyRef → Any
  8. def expect[A](s: String)(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a GET request to the URI specified by the String and decodes the response on success.

    Submits a GET request to the URI specified by the String and decodes the response on success. On failure, the status code is returned. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  9. def expect[A](uri: Uri)(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a GET request to the specified URI and decodes the response on success.

    Submits a GET request to the specified URI and decodes the response on success. On failure, the status code is returned. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  10. def expect[A](req: F[Request[F]])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
  11. def expect[A](req: Request[F])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a request and decodes the response on success.

    Submits a request and decodes the response on success. On failure, the status code is returned. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  12. def expectOption[A](req: Request[F])(implicit d: EntityDecoder[F, A]): F[Option[A]]

    Permalink
    Definition Classes
    EmberClient → Client
  13. def expectOptionOr[A](req: Request[F])(onError: (Response[F]) ⇒ F[Throwable])(implicit d: EntityDecoder[F, A]): F[Option[A]]

    Permalink
    Definition Classes
    EmberClient → Client
  14. def expectOr[A](s: String)(onError: (Response[F]) ⇒ F[Throwable])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
  15. def expectOr[A](uri: Uri)(onError: (Response[F]) ⇒ F[Throwable])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
  16. def expectOr[A](req: F[Request[F]])(onError: (Response[F]) ⇒ F[Throwable])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
  17. def expectOr[A](req: Request[F])(onError: (Response[F]) ⇒ F[Throwable])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
  18. def fetch[A](req: F[Request[F]])(f: (Response[F]) ⇒ F[A]): F[A]

    Permalink

    Submits a request, and provides a callback to process the response.

    Submits a request, and provides a callback to process the response.

    req

    An effect of the request to submit

    f

    A callback for the response to req. The underlying HTTP connection is disposed when the returned task completes. Attempts to read the response body afterward will result in an error.

    returns

    The result of applying f to the response to req

    Definition Classes
    EmberClient → Client
  19. def fetch[A](req: Request[F])(f: (Response[F]) ⇒ F[A]): F[A]

    Permalink

    Submits a request, and provides a callback to process the response.

    Submits a request, and provides a callback to process the response.

    req

    The request to submit

    f

    A callback for the response to req. The underlying HTTP connection is disposed when the returned task completes. Attempts to read the response body afterward will result in an error.

    returns

    The result of applying f to the response to req

    Definition Classes
    EmberClient → Client
  20. def fetchAs[A](req: F[Request[F]])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a request and decodes the response, regardless of the status code.

    Submits a request and decodes the response, regardless of the status code. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  21. def fetchAs[A](req: Request[F])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a request and decodes the response, regardless of the status code.

    Submits a request and decodes the response, regardless of the status code. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  22. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  23. def get[A](s: String)(f: (Response[F]) ⇒ F[A]): F[A]

    Permalink

    Submits a request and decodes the response on success.

    Submits a request and decodes the response on success. On failure, the status code is returned. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
  24. def get[A](uri: Uri)(f: (Response[F]) ⇒ F[A]): F[A]

    Permalink

    Submits a GET request, and provides a callback to process the response.

    Submits a GET request, and provides a callback to process the response.

    uri

    The URI to GET

    f

    A callback for the response to a GET on uri. The underlying HTTP connection is disposed when the returned task completes. Attempts to read the response body afterward will result in an error.

    returns

    The result of applying f to the response to req

    Definition Classes
    EmberClient → Client
  25. final def getClass(): Class[_]

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

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

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

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

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

    Permalink
    Definition Classes
    AnyRef
  31. def run(req: Request[F]): Resource[F, Response[F]]

    Permalink
    Definition Classes
    EmberClient → Client
  32. def state: F[(Int, Map[RequestKey, Int])]

    Permalink

    The reason for this extra class.

    The reason for this extra class. This allows you to see the present state of the underlying Pool, without having access to the pool itself.

    The first element represents total connections in the pool, the second is a mappying between the number of connections in the pool for each requestKey.

  33. def status(req: F[Request[F]]): F[Status]

    Permalink

    Submits a request and returns the response status

    Submits a request and returns the response status

    Definition Classes
    EmberClient → Client
  34. def status(req: Request[F]): F[Status]

    Permalink

    Submits a request and returns the response status

    Submits a request and returns the response status

    Definition Classes
    EmberClient → Client
  35. def stream(req: Request[F]): Stream[F, Response[F]]

    Permalink
    Definition Classes
    EmberClient → Client
  36. def streaming[A](req: F[Request[F]])(f: (Response[F]) ⇒ Stream[F, A]): Stream[F, A]

    Permalink
    Definition Classes
    EmberClient → Client
  37. def streaming[A](req: Request[F])(f: (Response[F]) ⇒ Stream[F, A]): Stream[F, A]

    Permalink
    Definition Classes
    EmberClient → Client
  38. def successful(req: F[Request[F]]): F[Boolean]

    Permalink

    Submits a request and returns true if and only if the response status is successful

    Submits a request and returns true if and only if the response status is successful

    Definition Classes
    EmberClient → Client
  39. def successful(req: Request[F]): F[Boolean]

    Permalink

    Submits a request and returns true if and only if the response status is successful

    Submits a request and returns true if and only if the response status is successful

    Definition Classes
    EmberClient → Client
  40. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  41. def toHttpApp: HttpApp[F]

    Permalink

    Returns this client as an HttpApp.

    Returns this client as an HttpApp. It is the responsibility of callers of this service to run the response body to dispose of the underlying HTTP connection.

    This is intended for use in proxy servers. fetch, fetchAs, toKleisli, and streaming are safer alternatives, as their signatures guarantee disposal of the HTTP connection.

    Definition Classes
    EmberClient → Client
  42. def toKleisli[A](f: (Response[F]) ⇒ F[A]): Kleisli[F, Request[F], A]

    Permalink

    Returns this client as a Kleisli.

    Returns this client as a Kleisli. All connections created by this service are disposed on completion of callback task f.

    This method effectively reverses the arguments to fetch, and is preferred when an HTTP client is composed into a larger Kleisli function, or when a common response callback is used by many call sites.

    Definition Classes
    EmberClient → Client
  43. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  44. final def wait(): Unit

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

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

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

Deprecated Value Members

  1. def getAs[A](s: String)(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.14) Use expect

  2. def getAs[A](uri: Uri)(implicit d: EntityDecoder[F, A]): F[A]

    Permalink

    Submits a GET request and decodes the response.

    Submits a GET request and decodes the response. The underlying HTTP connection is closed at the completion of the decoding.

    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.14) Use expect

  3. def prepAs[T](req: F[Request[F]])(implicit d: EntityDecoder[F, T]): F[T]

    Permalink
    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.14) Use expect

  4. def prepAs[A](req: Request[F])(implicit d: EntityDecoder[F, A]): F[A]

    Permalink
    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.14) Use expect

  5. def toHttpService: HttpService[F]

    Permalink

    Returns this client as an HttpService.

    Returns this client as an HttpService. It is the responsibility of callers of this service to run the response body to dispose of the underlying HTTP connection.

    This is intended for use in proxy servers. fetch, fetchAs, toKleisli, and streaming are safer alternatives, as their signatures guarantee disposal of the HTTP connection.

    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.19) Use toHttpApp. Call .mapF(OptionT.liftF) if OptionT is really desired.

  6. def toService[A](f: (Response[F]) ⇒ F[A]): Service[F, Request[F], A]

    Permalink
    Definition Classes
    EmberClient → Client
    Annotations
    @deprecated
    Deprecated

    (Since version 0.18) Use toKleisli

Inherited from Client[F]

Inherited from AnyRef

Inherited from Any

Ungrouped