package response import ( "io" "net/http" "ruben/inventory2/server/redirect" ) type ( Response interface { Status(int) Response HXPushURL(string) Response HXLocation(string) Response HXPushUrl(string) Response HXRedirect(string) Response HXRefresh(string) Response HXReplaceUrl(string) Response HXReswap(string) Response HXRetarget(string) Response HXReselect(string) Response HXTrigger(string) Response HXTriggerAfterSettle(string) Response HXTriggerAfterSwap(string) Response Redirect(code redirect.Code, to string) Response Body(io.ReadCloser) Response HTML([]byte) Response HTMLReader(io.Reader) Response JSON(any) Response Cookie(http.Cookie) Response GetStatus() (code int, ok bool) getBody() (body io.ReadCloser, ok bool, err error) GetRedirect() (code redirect.Code, to string, ok bool) getCookies() []http.Cookie getContentType() (contentType string, ok bool) getHeaders() [][2]string wrap(Response) Response } )