Module
Stetson.HandlerProxy
- Package
- erl-stetson
- Repository
- id3as/purescript-erl-stetson
#ElidedInitResult Source
data ElidedInitResult :: Type#restInitResult Source
restInitResult :: forall state msg. State msg state -> Req -> ElidedInitResult#wsInitResult Source
wsInitResult :: forall state msg. State msg state -> Req -> ElidedInitResult#loopInitResult Source
loopInitResult :: forall state msg. State msg state -> Req -> ElidedInitResult#State Source
type State msg state = { acceptHandlers :: List (Req -> state -> Effect (RestResult Boolean state)), handler :: StetsonHandlerCallbacks msg state, innerState :: state, provideHandlers :: List (Req -> state -> Effect (RestResult String state)) }#InitHandler Source
type InitHandler c s = EffectFn2 Req c (InitResult s)#init Source
init :: forall state msg. EffectFn2 Req (StetsonHandlerCallbacks msg state) ElidedInitResult#resource_exists Source
resource_exists :: forall state msg. ResourceExistsHandler (State msg state)#allowed_methods Source
allowed_methods :: forall state msg. AllowedMethodsHandler (State msg state)#malformed_request Source
malformed_request :: forall state msg. MalformedRequestHandler (State msg state)#previously_existed Source
previously_existed :: forall state msg. PreviouslyExistedHandler (State msg state)#allow_missing_post Source
allow_missing_post :: forall state msg. PreviouslyExistedHandler (State msg state)#moved_permanently Source
moved_permanently :: forall state msg. MovedPermanentlyHandler (State msg state)#moved_temporarily Source
moved_temporarily :: forall state msg. MovedTemporarilyHandler (State msg state)#service_available Source
service_available :: forall state msg. ServiceAvailableHandler (State msg state)#is_authorized Source
is_authorized :: forall state msg. IsAuthorizedHandler (State msg state)#is_conflict Source
is_conflict :: forall state msg. IsConflictHandler (State msg state)#forbidden Source
forbidden :: forall state msg. ForbiddenHandler (State msg state)#delete_resource Source
delete_resource :: forall state msg. DeleteResourceHandler (State msg state)#content_types_accepted Source
content_types_accepted :: forall state msg. ContentTypesAcceptedHandler (State msg state)#content_types_provided Source
content_types_provided :: forall state msg. ContentTypesProvidedHandler (State msg state)#callMap Source
callMap :: forall mappedReply reply state msg. (reply -> mappedReply) -> Maybe (Req -> state -> Effect (RestResult reply state)) -> Req -> (State msg state) -> Effect (RestResult mappedReply (State msg state))#call Source
call :: forall reply state msg. Maybe (Req -> state -> Effect (RestResult reply state)) -> Req -> State msg state -> Effect (RestResult reply (State msg state))#mapReply Source
mapReply :: forall mappedReply reply state. (reply -> mappedReply) -> Effect (RestResult reply state) -> Effect (RestResult mappedReply state)#restResult Source
restResult :: forall state msg reply. State msg state -> Maybe (Effect (RestResult reply state)) -> Effect (RestResult reply (State msg state))#noCall Source
noCall :: forall t4 t3. Applicative t3 => t3 t4#wsState Source
wsState :: forall msg. Effect (WebSocketInternalState msg)#websocket_init Source
websocket_init :: forall state msg. WSInitHandler (State msg state)#websocket_handle Source
websocket_handle :: forall state msg. FrameHandler (State msg state)#websocket_info Source
websocket_info :: forall state msg. InfoHandler msg (State msg state)#transformWsResult Source
transformWsResult :: forall state msg. State msg state -> WebSocketCallResult state -> Effect (CallResult (State msg state))#loopState Source
loopState :: forall msg. Effect (LoopInternalState msg)#info Source
info :: forall state msg. InfoHandler msg (State msg state)#transformLoopResult Source
transformLoopResult :: forall state msg. State msg state -> LoopCallResult state -> Effect (InfoResult (State msg state))#applyLoopInit Source
applyLoopInit :: forall state msg. StetsonHandlerCallbacks msg state -> Req -> state -> Effect state#switchHandler Source
switchHandler :: forall state msg reply. CowboyHandler -> Req -> State msg state -> Effect (RestResult reply (State msg state))