package server
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- server
- ApiTransformer
- WitnessToStringLowPrio
- TypeLevelFoldLeftListLowPrio
- TypeLevelFoldLeftLowPrio
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- All
Type Members
- final case class BadRouteRequest(msg: String) extends ExtractionError with Product with Serializable
- final case class BodyType[Bd]() extends Product with Serializable
-
abstract
class
Endpoint[El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, ROut, F[_], Out] extends AnyRef
Represents a server endpoint and is basically a function which gets the expected input
VIn
and returns the expected output. -
trait
EndpointConstructor[F[_], Fn, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, ROut, Out] extends AnyRef
Fuses RouteExtractor and the endpoint function into an Endpoint.
-
sealed
trait
EndpointExecutor[El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, ROut, F[_], FOut] extends AnyRef
- Annotations
- @implicitNotFound( ... )
-
final
case class
EndpointRequest(method: String, uri: List[String], queries: Map[String, List[String]], headers: Map[String, String]) extends Product with Serializable
Request representation which every server implementation has to provide.
- final case class ErrorCode(statusCode: Int) extends AnyVal with Product with Serializable
- final class ExecutableCompositionDerivation[F[_]] extends AnyRef
- final class ExecutableDerivation[F[_]] extends AnyRef
- sealed trait ExtractionError extends AnyRef
- sealed trait FilterClientElements[H <: HList] extends AnyRef
- sealed trait FilterClientElementsList[H <: HList] extends AnyRef
- sealed trait FilterClientElementsLowPrio extends AnyRef
- final case class HttpError(code: ErrorCode, message: String) extends Product with Serializable
-
sealed
trait
MergeToEndpoint[F[_], Consts <: HList, Fns <: HList] extends AnyRef
- Annotations
- @implicitNotFound( ... )
- trait MergeToEndpointLowPrio extends AnyRef
- trait MountEndpoints[S, Req, Resp] extends AnyRef
- trait NoReqBodyExecutor[El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, F[_], FOut] extends EndpointExecutor[El, KIn, VIn, M, VIn, F, FOut]
-
sealed
trait
PrecompileEndpoint[F[_], H <: HList] extends AnyRef
Compiles RouteExtractor and FunApply for every API endpoint and generates expected list of endpoint functions.
Compiles RouteExtractor and FunApply for every API endpoint and generates expected list of endpoint functions.
- Annotations
- @implicitNotFound( ... )
- trait PrecompileEndpointLowPrio extends AnyRef
- trait ReqBodyExecutor[El <: HList, KIn <: HList, VIn <: HList, Bd, M <: MethodType, ROut <: HList, POut <: HList, F[_], FOut] extends EndpointExecutor[El, KIn, VIn, M, (BodyType[Bd], ROut), F, FOut]
- type Result[A] = Either[HttpError, (SuccessCode, A)]
-
trait
RouteExtractor[El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, EIn <: HList] extends AnyRef
Builds a function which extracts inputs from a given requests based on the API.
Builds a function which extracts inputs from a given requests based on the API.
- if a request path does not fit the API definition
RouteNotFound
is returned - if a query, header, body, etc is missing
BadRouteRequest
is returned
- Annotations
- @implicitNotFound( ... )
- if a request path does not fit the API definition
- trait RouteExtractorLowPrio extends AnyRef
- trait RouteExtractorMediumPrio extends RouteExtractorLowPrio
-
trait
Serve[Req, Resp] extends AnyRef
Reduces an Endpoint and its EndpointExecutor to a simple Request => Response function.
-
sealed
trait
ServeToList[H <: HList, Req, Resp] extends AnyRef
- Annotations
- @implicitNotFound( ... )
- trait ServeToListLowPrio extends AnyRef
-
sealed
trait
ServerHeaderExtractor[El <: HList] extends AnyRef
- Annotations
- @implicitNotFound( ... )
- sealed trait ServerHeaderExtractorLowPrio extends AnyRef
- final case class ServerManager[S](server: S, host: String, port: Int) extends Product with Serializable
- final case class SuccessCode(statusCode: Int) extends AnyVal with Product with Serializable
- trait ValueExtractor[A] extends (String) ⇒ Option[A]
- trait ValueExtractorInstances extends AnyRef
Value Members
- val SC: StatusCodes.type
-
implicit
def
clientHeaderCollParamTransformer[V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[ClientHeaderCollParam[V], (El, KIn, VIn, M, Out), (::[ClientHeaderCollInput, El], KIn, ::[Map[String, V], VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
clientHeaderElementTransformer[K, V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[ClientHeaderElement[K, V], (El, KIn, VIn, M, Out), (::[ClientHeader[K, V], El], KIn, VIn, M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
clientHeaderParamTransformer[K, V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[ClientHeaderParam[K, V], (El, KIn, VIn, M, Out), (::[ClientHeaderInput, El], ::[K, KIn], ::[V, VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
deleteTransformer[MT <: MediaType, A]: Aux[DeleteElement[MT, A], Unit, (HNil, HNil, HNil, DeleteCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
- def derive[F[_]]: ExecutableDerivation[F]
- def deriveAll[F[_]]: ExecutableCompositionDerivation[F]
- def errorWith[A](code: ErrorCode, message: String): Result[A]
-
implicit
def
fixedHeaderElementTransformer[K, V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[FixedHeaderElement[K, V], (El, KIn, VIn, M, Out), (::[FixedHeader[K, V], El], KIn, VIn, M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
foldCase[H, T <: HList, Agg, FtOut, FOut](implicit f: Aux[H, Agg, FtOut], next: Lazy[Aux[T, FtOut, FOut]]): Aux[::[H, T], Agg, FOut]
- Definition Classes
- TypeLevelFoldLeftLowPrio
-
implicit
def
folderLeftList[H <: HList, Agg, T <: HList](implicit folder0: TypeLevelFoldLeft[H, Agg], list: TypeLevelFoldLeftList[T]): TypeLevelFoldLeftList[::[H, T]] { type Out = folder0.Out :: list.Out }
- Definition Classes
- TypeLevelFoldLeftListLowPrio
-
implicit
def
getTransformer[MT <: MediaType, A]: Aux[GetElement[MT, A], Unit, (HNil, HNil, HNil, GetCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
-
implicit
def
headerParamTransformer[S, A, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[HeaderParam[S, A], (El, KIn, VIn, M, Out), (::[HeaderInput, El], ::[S, KIn], ::[A, VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
hnilCase[Agg]: Aux[HNil, Agg, Agg]
- Definition Classes
- TypeLevelFoldLeftLowPrio
-
implicit
def
lastFoldLeftList[H <: HList, Agg](implicit folder0: TypeLevelFoldLeft[H, Agg]): TypeLevelFoldLeftList[::[H, HNil]] { type Out = folder0.Out :: shapeless.HNil }
- Definition Classes
- TypeLevelFoldLeftListLowPrio
- def mount[S, End <: HList, Serv <: HList, Req, Resp, Out](server: ServerManager[S], end: End)(implicit mapper: Aux[endpointToServe.type, End, Serv], toList: ServeToList[Serv, Req, Resp], mounting: Aux[S, Req, Resp, Out]): Out
- def mount[S, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, ROut, F[_], FOut, Req, Resp, Out](server: ServerManager[S], endpoint: Endpoint[El, KIn, VIn, M, ROut, F, FOut])(implicit executor: Aux[Req, El, KIn, VIn, M, ROut, F, FOut, Resp], mounting: Aux[S, Req, Resp, Out]): Out
-
implicit
def
pathElementTransformer[S, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[PathElement[S], (El, KIn, VIn, M, Out), (::[S, El], KIn, VIn, M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
postTransformer[MT <: MediaType, A]: Aux[PostElement[MT, A], Unit, (HNil, HNil, HNil, PostCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
-
implicit
def
postWithBodyTransformer[BMT <: MediaType, Bd, MT <: MediaType, A]: Aux[PostWithBodyElement[BMT, Bd, MT, A], Unit, (HNil, ::[FieldType[BMT, (BodyField)#T], HNil], ::[Bd, HNil], PostWithBodyCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
-
implicit
def
putTransformer[MT <: MediaType, A]: Aux[PutElement[MT, A], Unit, (HNil, HNil, HNil, PutCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
-
implicit
def
putWithBodyTransformer[BMT <: MediaType, Bd, MT <: MediaType, A]: Aux[PutWithBodyElement[BMT, Bd, MT, A], Unit, (HNil, ::[FieldType[BMT, (BodyField)#T], HNil], ::[Bd, HNil], PutWithBodyCall, FieldType[MT, A])]
- Definition Classes
- ApiTransformer
-
implicit
def
queryListParamTransformer[S, A, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[QueryParam[S, List[A]], (El, KIn, VIn, M, Out), (::[QueryInput, El], ::[S, KIn], ::[List[A], VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
queryParamTransformer[S, A, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[QueryParam[S, A], (El, KIn, VIn, M, Out), (::[QueryInput, El], ::[S, KIn], ::[A, VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
segmentParamTransformer[S, A, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[SegmentParam[S, A], (El, KIn, VIn, M, Out), (::[SegmentInput, El], ::[S, KIn], ::[A, VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
serverHeaderMatchParamTransformer[K, V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[ServerHeaderMatchParam[K, V], (El, KIn, VIn, M, Out), (::[ServerHeaderMatchInput, El], ::[K, KIn], ::[Map[String, V], VIn], M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
serverHeaderSendElementTransformer[K, V, El <: HList, KIn <: HList, VIn <: HList, M <: MethodType, Out]: Aux[ServerHeaderSendElement[K, V], (El, KIn, VIn, M, Out), (::[ServerHeaderSend[K, V], El], KIn, VIn, M, Out)]
- Definition Classes
- ApiTransformer
-
implicit
def
stringKey[K <: String]: WitnessToString[K]
- Definition Classes
- WitnessToStringLowPrio
- def success[A](a: A): Result[A]
- def successWith[A](code: SuccessCode)(a: A): Result[A]
-
implicit
def
symbolKey[K <: Symbol]: WitnessToString[K]
- Definition Classes
- WitnessToStringLowPrio
- object EndpointExecutor
- object FilterClientElements extends FilterClientElementsLowPrio
- object FilterClientElementsList
- object MergeToEndpoint extends MergeToEndpointLowPrio
- object MountEndpoints
- object PrecompileEndpoint extends PrecompileEndpointLowPrio
- object RouteExtractor extends RouteExtractorMediumPrio
- object RouteNotFound extends ExtractionError with Product with Serializable
- object ServeToList extends ServeToListLowPrio
- object ServerHeaderExtractor extends ServerHeaderExtractorLowPrio
- object ServerManager extends Serializable
- object StatusCodes
- object ValueExtractor extends ValueExtractorInstances
- object endpointToServe extends Poly1