ZPartialServerEndpoint

case
class ZPartialServerEndpoint[R, A, U, I, E, O, -C](endpoint: Endpoint[A, I, E, O, C], securityLogic: A => ZIO[R, E, U]) extends EndpointInputsOps[A, I, E, O, C] with EndpointOutputsOps[A, I, E, O, C] with EndpointInfoOps[C] with EndpointMetaOps

An endpoint with the security logic provided, and the main logic yet unspecified. See RichZEndpoint.zServerLogic.

The provided security part of the server logic transforms inputs of type A, either to an error of type E, or value of type U.

The part of the server logic which is not provided, will have to transform a tuple: (U, I) either into an error, or a value of type O.

Inputs/outputs can be added to partial endpoints as to regular endpoints, however the shape of the error outputs is fixed and cannot be changed. Hence, it's possible to create a base, secured input, and then specialise it with inputs, outputs and logic as needed.

Type Params
A

Type of the security inputs, transformed into U

C

The capabilities that are required by this endpoint's inputs/outputs. Any, if no requirements.

E

Error output parameter types.

I

Input parameter types.

O

Output parameter types.

U

Type of transformed security input.

trait Serializable
trait Product
trait Equals
trait EndpointMetaOps
trait EndpointInfoOps[C]
trait EndpointOutputsOps[A, I, E, O, C]
trait EndpointOutputsMacros[A, I, E, O, C]
trait EndpointInputsOps[A, I, E, O, C]
trait EndpointInputsMacros[A, I, E, O, C]
class Object
trait Matchable
class Any
ZPartialServerEndpoint[R, A, U, I, E, O, C]

Type members

Types

override
type EndpointType[_A, _I, _E, _O, -_R] = ZPartialServerEndpoint[R, _A, U, _I, _E, _O, _R]
override
type ThisType[-_R] = ZPartialServerEndpoint[R, A, U, I, E, O, _R]

Value members

Concrete methods

def errorOutput: EndpointOutput[E]
override
def info: EndpointInfo
Definition Classes
EndpointMetaOps -> EndpointInfoOps
override
def input: EndpointInput[I]
Definition Classes
EndpointMetaOps -> EndpointInputsOps
override
def output: EndpointOutput[O]
Definition Classes
EndpointMetaOps -> EndpointOutputsOps
override
def securityInput: EndpointInput[A]
Definition Classes
EndpointMetaOps
def serverLogic[R0](logic: U => I => ZIO[R0, E, O]): ZServerEndpoint[R & R0, C]

Inherited methods

def connect: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def delete: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
Inherited from
EndpointInfoOps
def description(d: String): ThisType[C]
Inherited from
EndpointInfoOps
def docsExtension[D : JsonCodec](key: String, value: D): ThisType[C]
Inherited from
EndpointInfoOps
def get: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def head: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def in[BS, J, IJ, R2](i: StreamBodyIO[BS, J, R2])(implicit concat: Aux[I, J, IJ]): EndpointType[A, IJ, E, O, C & R2]
Inherited from
EndpointInputsOps
def in[J, IJ](i: EndpointInput[J])(implicit concat: Aux[I, J, IJ]): EndpointType[A, IJ, E, O, C]
Inherited from
EndpointInputsOps
def info(i: EndpointInfo): ThisType[C]
Inherited from
EndpointInfoOps
def mapIn[II](f: I => II)(g: II => I): EndpointType[A, II, E, O, C]
Inherited from
EndpointInputsOps
def mapIn[II](m: Mapping[I, II]): EndpointType[A, II, E, O, C]
Inherited from
EndpointInputsOps
def mapInDecode[II](f: I => DecodeResult[II])(g: II => I): EndpointType[A, II, E, O, C]
Inherited from
EndpointInputsOps
inline
def mapInTo[CASE_CLASS <: Product](using mc: ProductOf[CASE_CLASS]): EndpointType[A, CASE_CLASS, E, O, C]
Inherited from
EndpointInputsMacros
def mapOut[OO](f: O => OO)(g: OO => O): EndpointType[A, I, E, OO, C]
Inherited from
EndpointOutputsOps
def mapOut[OO](m: Mapping[O, OO]): EndpointType[A, I, E, OO, C]
Inherited from
EndpointOutputsOps
def mapOutDecode[OO](f: O => DecodeResult[OO])(g: OO => O): EndpointType[A, I, E, OO, C]
Inherited from
EndpointOutputsOps
inline
def mapOutTo[CASE_CLASS <: Product](using mc: ProductOf[CASE_CLASS]): EndpointType[A, I, E, CASE_CLASS, C]
Inherited from
EndpointOutputsMacros
def method(m: Method): EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def name(n: String): ThisType[C]
Inherited from
EndpointInfoOps
def options: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def out[PIPE_REQ_RESP, P, OP, R2](i: WebSocketBodyOutput[PIPE_REQ_RESP, _, _, P, R2])(implicit ts: Aux[O, P, OP]): EndpointType[A, I, E, OP, C & R2 & WebSockets]
Inherited from
EndpointOutputsOps
def out[BS, P, OP, R2](i: StreamBodyIO[BS, P, R2])(implicit ts: Aux[O, P, OP]): EndpointType[A, I, E, OP, C & R2]
Inherited from
EndpointOutputsOps
def out[P, OP](i: EndpointOutput[P])(implicit ts: Aux[O, P, OP]): EndpointType[A, I, E, OP, C]
Inherited from
EndpointOutputsOps
def patch: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def post: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def prependIn[BS, J, JI, R2](i: StreamBodyIO[BS, J, R2])(implicit concat: Aux[J, I, JI]): EndpointType[A, JI, E, O, C & R2]
Inherited from
EndpointInputsOps
def prependIn[J, JI](i: EndpointInput[J])(implicit concat: Aux[J, I, JI]): EndpointType[A, JI, E, O, C]
Inherited from
EndpointInputsOps
def prependOut[PIPE_REQ_RESP, P, PO, R2](i: WebSocketBodyOutput[PIPE_REQ_RESP, _, _, P, R2])(implicit ts: Aux[P, O, PO]): EndpointType[A, I, E, PO, C & R2 & WebSockets]
Inherited from
EndpointOutputsOps
def prependOut[BS, P, PO, R2](i: StreamBodyIO[BS, P, R2])(implicit ts: Aux[P, O, PO]): EndpointType[A, I, E, PO, C]
Inherited from
EndpointOutputsOps
def prependOut[P, PO](i: EndpointOutput[P])(implicit ts: Aux[P, O, PO]): EndpointType[A, I, E, PO, C]
Inherited from
EndpointOutputsOps
def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product
def put: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps
def renderPathTemplate(renderPathParam: RenderPathParam, renderQueryParam: Option[RenderQueryParam], includeAuth: Boolean): String

Renders endpoint path, by default all parametrised path and query components are replaced by {param_name} or {paramN}, e.g. for

Renders endpoint path, by default all parametrised path and query components are replaced by {param_name} or {paramN}, e.g. for

endpoint.in("p1" / path[String] / query[String]("par2"))

returns /p1/{param1}?par2={par2}

Value Params
includeAuth

Should authentication inputs be included in the result.

Inherited from
EndpointMetaOps
def show: String

Basic information about the endpoint, excluding mapping information, with inputs sorted (first the method, then path, etc.)

Basic information about the endpoint, excluding mapping information, with inputs sorted (first the method, then path, etc.)

Inherited from
EndpointMetaOps
def showDetail: String

Detailed description of the endpoint, with inputs/outputs represented in the same order as originally defined, including mapping information.

Detailed description of the endpoint, with inputs/outputs represented in the same order as originally defined, including mapping information.

Inherited from
EndpointMetaOps
def showRaw: String

Equivalent to .toString, shows the whole case class structure.

Equivalent to .toString, shows the whole case class structure.

Inherited from
EndpointMetaOps
def summary(s: String): ThisType[C]
Inherited from
EndpointInfoOps
def tag(t: String): ThisType[C]
Inherited from
EndpointInfoOps
def tags(ts: List[String]): ThisType[C]
Inherited from
EndpointInfoOps
def trace: EndpointType[A, I, E, O, C]
Inherited from
EndpointInputsOps