io

finch

package finch

This is a root package of the Finch library, which provides an immutable layer of functions and types atop of Finagle for writing lightweight HTTP services.

Linear Supertypes
Outputs, Endpoints, AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. finch
  2. Outputs
  3. Endpoints
  4. AnyRef
  5. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. implicit final class AnyOps[A] extends AnyVal

    Alters any object within a toFuture method.

  2. case class BasicAuth(user: String, password: String, err: Map[String, String] = ...) extends Product with Serializable

    Maintains Basic HTTP Auth for an arbitrary Endpoint.

  3. trait Endpoint[A] extends AnyRef

    An Endpoint represents the HTTP endpoint.

  4. type Endpoint0 = Endpoint[HNil]

    Definition Classes
    Endpoints
  5. type Endpoint2[A, B] = Endpoint[::[A, ::[B, HNil]]]

    Definition Classes
    Endpoints
  6. type Endpoint3[A, B, C] = Endpoint[::[A, ::[B, ::[C, HNil]]]]

    Definition Classes
    Endpoints
  7. trait Endpoints extends AnyRef

    A collection of Endpoint combinators.

  8. case class Extractor[A](name: String, f: (String) ⇒ Option[A]) extends Endpoint[A] with Product with Serializable

    An universal extractor that extracts some value of type A if it's possible to fetch the value from the string.

  9. trait HighPriorityMapperConversions extends MidPriorityMapperConversions

  10. final case class Input(request: Request, path: Seq[String]) extends Product with Serializable

    An input for Endpoint.

  11. trait LowPriorityMapperConversions extends AnyRef

  12. trait LowPriorityPairAdjoin extends AnyRef

  13. trait LowPriorityToServiceInstances extends AnyRef

  14. trait Mapper[A] extends AnyRef

    A type class that allows the Endpoint to be mapped to either A => B or A => Future[B].

  15. trait MidPriorityMapperConversions extends LowPriorityMapperConversions

  16. sealed trait Output[+A] extends AnyRef

    An output of Endpoint.

  17. trait Outputs extends AnyRef

  18. trait PairAdjoin[A, B] extends DepFn2[A, B]

    We need a version of shapeless.ops.adjoin.Adjoin that provides slightly different behavior in the case of singleton results (we simply return the value, not a singleton HList).

  19. case class TailExtractor[A](name: String, f: (String) ⇒ Option[A]) extends Endpoint[Seq[A]] with Product with Serializable

    An extractor that extracts a value of type Seq[A] from the tail of the route.

  20. implicit final class ThrowableOps extends AnyVal

    Alters any throwable with a toFutureException method.

  21. trait ToService[A] extends AnyRef

    Represents a conversion from an Endpoint returning a result type A to a Finagle service from a request-like type R to a Response.

Value Members

  1. object * extends Endpoint[HNil]

    An Endpoint that skips all path parts.

  2. object / extends Endpoint[HNil]

    An identity Endpoint.

  3. def Accepted[A](a: A): Payload[A]

    Definition Classes
    Outputs
  4. def Accepted(): Payload[Unit]

    Definition Classes
    Outputs
  5. def BadRequest(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  6. def Conflict(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  7. def Continue[A](message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  8. def Created[A](a: A): Payload[A]

    Definition Classes
    Outputs
  9. def Created(): Payload[Unit]

    Definition Classes
    Outputs
  10. object Endpoint

    Provides extension methods for Endpoint to support coproduct and path syntax.

  11. def ExpectationFailed(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  12. def FailedDependency(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  13. def Forbidden(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  14. def Found(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  15. def Gone(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  16. def HttpVersionNotSupported(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  17. object Input extends Serializable

    Creates an input for Endpoint from Request.

  18. def InternalServerError(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  19. def LengthRequired(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  20. def Locked(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  21. object Mapper extends HighPriorityMapperConversions

  22. def MethodNotAllowed(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  23. def MovedPermanently(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  24. def MultiStatus[A](a: A): Payload[A]

    Definition Classes
    Outputs
  25. def MultiStatus(): Payload[Unit]

    Definition Classes
    Outputs
  26. def MultipleChoices(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  27. def NoContent[A](a: A): Payload[A]

    Definition Classes
    Outputs
  28. def NoContent(): Payload[Unit]

    Definition Classes
    Outputs
  29. def NonAuthoritativeInformation[A](a: A): Payload[A]

    Definition Classes
    Outputs
  30. def NonAuthoritativeInformation(): Payload[Unit]

    Definition Classes
    Outputs
  31. def NotAcceptable(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  32. def NotFound(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  33. def NotImplemented(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  34. def NotModified(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  35. def Ok[A](a: A): Payload[A]

    Definition Classes
    Outputs
  36. def Ok(): Payload[Unit]

    Definition Classes
    Outputs
  37. object Output

  38. object PairAdjoin extends LowPriorityPairAdjoin

  39. def PartialContent[A](a: A): Payload[A]

    Definition Classes
    Outputs
  40. def PartialContent(): Payload[Unit]

    Definition Classes
    Outputs
  41. def PaymentRequired(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  42. def PreconditionFailed(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  43. def PreconditionRequired(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  44. def Processing(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  45. def ProxyAuthenticationRequired(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  46. def RequestEntityTooLarge(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  47. def RequestTimeout(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  48. def RequestUriTooLong(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  49. def RequestedRangeNotSatisfiable(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  50. def ResetContent[A](a: A): Payload[A]

    Definition Classes
    Outputs
  51. def ResetContent(): Payload[Unit]

    Definition Classes
    Outputs
  52. def SeeOther(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  53. def ServiceUnavailable(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  54. def TemporaryRedirect(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  55. object ToService extends LowPriorityToServiceInstances

  56. def TooManyRequests(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  57. def Unauthorized(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  58. def UnorderedCollection(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  59. def UnprocessableEntity(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  60. def UnsupportedMediaType(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  61. def UpgradeRequired(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  62. def UseProxy(message: (String, String)*)(implicit e: EncodeResponse[Map[String, String]]): Failure

    Definition Classes
    Outputs
  63. object boolean extends Extractor[Boolean]

    An Endpoint that extract a boolean value from the route.

  64. implicit def booleanToMatcher(b: Boolean): Endpoint0

    Definition Classes
    Endpoints
  65. object booleans extends TailExtractor[Boolean]

    An Endpoint that extract a boolean tail from the route.

  66. def connect[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is CONNECT and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  67. def delete[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is DELETE and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  68. def get[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is GET and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  69. def head[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is HEAD and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  70. object int extends Extractor[Int]

    An Endpoint that extract an integer value from the route.

  71. implicit def intToMatcher(i: Int): Endpoint0

    Definition Classes
    Endpoints
  72. object ints extends TailExtractor[Int]

    An Endpoint that extract an integer tail from the route.

  73. object long extends Extractor[Long]

    An Endpoint that extract a long value from the route.

  74. object longs extends TailExtractor[Long]

    An Endpoint that extract a long tail from the route.

  75. def options[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is OPTIONS and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  76. def patch[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is PATCH and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  77. def post[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is POST and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  78. def put[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is PUT and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  79. package request

    This package introduces types and functions that enable _request processing_ in Finch.

  80. package response

    This package enables a reasonable approach of building HTTP responses using the ResponseBuilder abstraction.

  81. package route

    This package contains various of functions and types that enable _router combinators_ in Finch.

  82. object string extends Extractor[String]

    An Endpoint that extract a string value from the route.

  83. implicit def stringToMatcher(s: String): Endpoint0

    Definition Classes
    Endpoints
  84. object strings extends TailExtractor[String]

    An Endpoint that extract a string tail from the route.

  85. def trace[A]: (Endpoint[A]) ⇒ Endpoint[A]

    A combinator that wraps the given Endpoint with additional check of the HTTP method.

    A combinator that wraps the given Endpoint with additional check of the HTTP method. The resulting Endpoint succeeds on the request only if its method is TRACE and the underlying router succeeds on it.

    Definition Classes
    Endpoints
  86. object uuid extends Extractor[UUID]

    An Endpoint that extract an UUID value from the route.

  87. object uuids extends TailExtractor[UUID]

    An Endpoint that extract an UUID tail from the route.

Deprecated Value Members

  1. object Connect extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method connect: Endpoint[A] => Endpoint[A] instead

  2. object Delete extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method delete: Endpoint[A] => Endpoint[A] instead

  3. object Get extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method get: Endpoint[A] => Endpoint[A] instead

  4. object Head extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method head: Endpoint[A] => Endpoint[A] instead

  5. object Options extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method options: Endpoint[A] => Endpoint[A] instead

  6. object Patch extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method patch: Endpoint[A] => Endpoint[A] instead

  7. object Post extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method post: Endpoint[A] => Endpoint[A] instead

  8. object Put extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method put: Endpoint[A] => Endpoint[A] instead

  9. object Trace extends MethodMatcher

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use method trace: Endpoint[A] => Endpoint[A] instead

  10. def basicAuth[A](user: String, password: String)(e: Endpoint[A]): Endpoint[A]

    A combinator that wraps the given Endpoint with Basic HTTP Auth, configured with credentials user and password.

    A combinator that wraps the given Endpoint with Basic HTTP Auth, configured with credentials user and password.

    Definition Classes
    Endpoints
    Annotations
    @deprecated
    Deprecated

    (Since version 0.9.1) Use BasicAuth instead

Inherited from Outputs

Inherited from Endpoints

Inherited from AnyRef

Inherited from Any

Ungrouped