Versions in this module Expand all Collapse all v1 v1.0.0 Feb 10, 2024 Changes in this version + const CookieSameSiteDefaultMode + const CookieSameSiteDisabled + const CookieSameSiteLaxMode + const CookieSameSiteNoneMode + const CookieSameSiteStrictMode + const HttpReturnCode200Ok + const HttpReturnCode404NotFound + const HttpReturnCode500ServerError + func RegisterServer(server HttpServer) + func SaveStreamToFile(reader io.Reader, outFilePath string) error + type CookieSameSite int + type HttpCookie interface + GetDomain func() string + GetExpireTime func() time.Time + GetKey func() string + GetMaxAge func() int + GetSameSiteType func() CookieSameSite + GetValue func() string + IsHTTPOnly func() bool + IsSecure func() bool + type HttpCookieOptions struct + Domaine string + ExpireTime int64 + IsHttpOnly bool + IsSecure bool + MaxAge int + SameSiteType CookieSameSite + type HttpHost struct + func NewHttpHost(hostName string, server HttpServer, impl HttpHostImpl) *HttpHost + func (m *HttpHost) CONNECT(path string, h HttpMiddleware) + func (m *HttpHost) DELETE(path string, h HttpMiddleware) + func (m *HttpHost) GET(path string, h HttpMiddleware) + func (m *HttpHost) GetHostName() string + func (m *HttpHost) GetServer() HttpServer + func (m *HttpHost) GetUrlResolver(methodCode HttpMethod) *UrlResolver + func (m *HttpHost) HEAD(path string, h HttpMiddleware) + func (m *HttpHost) Impl() HttpHostImpl + func (m *HttpHost) OPTIONS(path string, h HttpMiddleware) + func (m *HttpHost) OnError(req HttpRequest, err error) + func (m *HttpHost) OnNotFound(req HttpRequest) + func (m *HttpHost) PATCH(path string, h HttpMiddleware) + func (m *HttpHost) POST(path string, h HttpMiddleware) + func (m *HttpHost) PUT(path string, h HttpMiddleware) + func (m *HttpHost) Reset() + func (m *HttpHost) TRACE(path string, h HttpMiddleware) + func (m *HttpHost) VERB(verb string, path string, h HttpMiddleware) + type HttpHostImpl interface + Reset func(host *HttpHost) + type HttpHostInfos struct + HostName string + Port int + type HttpMethod int + const HttpMethodCONNECT + const HttpMethodDELETE + const HttpMethodGET + const HttpMethodHEAD + const HttpMethodOPTIONS + const HttpMethodPATCH + const HttpMethodPOST + const HttpMethodPUT + const HttpMethodTRACE + func MethodNameToMethodCode(method string) HttpMethod + type HttpMiddleware func(call HttpRequest) error + type HttpMultiPartForm struct + Files map[string][]*multipart.FileHeader + Values map[string][]string + type HttpRequest interface + GetContentLength func() int + GetContentType func() string + GetCookie func(name string) (map[string]any, error) + GetCookies func() (map[string]map[string]any, error) + GetHeaders func() map[string]string + GetHost func() *HttpHost + GetMethodCode func() HttpMethod + GetMethodName func() string + GetMultipartForm func() (*HttpMultiPartForm, error) + GetPostArgs func() ValueSet + GetQueryArgs func() ValueSet + GetRemainingSegment func() []string + GetWildcards func() []string + IsBodySend func() bool + IsMultipartForm func() bool + MustStop func() bool + Path func() string + RemoteIP func() string + Return404UnknownPage func() + Return500ErrorPage func(err error) + ReturnString func(status int, text string) + SetContentType func(contentType string) + SetCookie func(key string, value string, cookie HttpCookieOptions) error + SetHeader func(key, value string) + SetUnlockMutex func(mutex *sync.Mutex) + StopRequest func() + URI func() string + UnlockMutex func() + UserAgent func() string + type HttpServer interface + GetHost func(hostName string) *HttpHost + GetPort func() int + IsStarted func() bool + SetStartServerParams func(params HttpServerStartParams) + Shutdown func() + StartServer func() error + func GetHttpServer(port int) HttpServer + type HttpServerStartParams struct + type UrlResolver struct + func NewUrlResolver() *UrlResolver + func (m *UrlResolver) Add(path string, handler any, tag any) + func (m *UrlResolver) AppendMiddleware(path string, handler any, tag any) + func (m *UrlResolver) DumpTree() []UrlResolverTreeItem + func (m *UrlResolver) Find(path string) UrlResolverResult + func (m *UrlResolver) Print() + type UrlResolverResult struct + Middlewares []any + RemainingSegments []string + Segments []string + Target any + func (m *UrlResolverResult) GetWildcards() []string + type UrlResolverTreeItem struct + Handler any + Path string + Tag any + type ValueSet interface + GetBool func(key string) bool + GetUfloat func(key string) (float64, error) + GetUfloatOrZero func(key string) float64 + GetUint func(key string) (int, error) + GetUintOrZero func(key string) int + Has func(key string) bool + Len func() int + QueryString func() []byte + VisitAll func(f func(key, value []byte))