package
0.2.0
Repository: https://github.com/suyash/kit-pcp-examples.git
Documentation: pkg.go.dev

# Functions

BufferedStream sets whether the Response.Body is left open, allowing it to be read from later.
ClientAfter sets the ClientResponseFuncs applied to the incoming HTTP request prior to it being decoded.
ClientBefore sets the RequestFuncs that are applied to the outgoing HTTP request before it's invoked.
NewClient constructs a usable Client for a single remote method.
NewServer constructs a new server, which implements http.Server and wraps the provided endpoint.
ServerAfter functions are executed on the HTTP response writer after the endpoint is invoked, but before anything is written to the client.
ServerBefore functions are executed on the HTTP request object before the request is decoded.
ServerErrorEncoder is used to encode errors to the http.ResponseWriter whenever they're encountered in the processing of a request.
ServerErrorLogger is used to log non-terminal errors.
SetClient sets the underlying HTTP client used for requests.
SetContentType returns a ResponseFunc that sets the Content-Type header to the provided value.
SetRequestHeader returns a RequestFunc that sets the specified header.
SetResponseHeader returns a ResponseFunc that sets the specified header.

# Constants

DomainDecode is an error during request or response decoding.
DomainDo is an error during the execution phase of the request.
DomainEncode is an error during request or response encoding.
DomainNewRequest is an error during request generation.

# Structs

Client wraps a URL and provides a method that implements endpoint.Endpoint.
Error is an error that occurred at some phase within the transport.
Server wraps an endpoint and implements http.Handler.

# Type aliases

ClientOption sets an optional parameter for clients.
ClientResponseFunc may take information from an HTTP request and make the response available for consumption.
DecodeRequestFunc extracts a user-domain request object from an HTTP request object.
DecodeResponseFunc extracts a user-domain response object from an HTTP response object.
EncodeRequestFunc encodes the passed request object into the HTTP request object.
EncodeResponseFunc encodes the passed response object to the HTTP response writer.
ErrorEncoder is responsible for encoding an error to the ResponseWriter.
RequestFunc may take information from an HTTP request and put it into a request context.
ServerOption sets an optional parameter for servers.
ServerResponseFunc may take information from a request context and use it to manipulate a ResponseWriter.