Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CORS ¶
type CORS struct {
// contains filtered or unexported fields
}
CORS implements the ICORS interface and provides the CORS middleware handler.
func (*CORS) Handler ¶
func (c *CORS) Handler() mux.MiddlewareFunc
Handler returns the CORS middleware function.
type CORSFactory ¶
type CORSFactory struct{}
CORSFactory implements the ICORSFactory interface to create CORS middleware.
func (*CORSFactory) NewCORS ¶
func (c *CORSFactory) NewCORS(config subrouter_config.CORSConfig) ICORS
NewCORS creates a new CORS middleware based on the provided configuration.
type ICORS ¶
type ICORS interface {
Handler() mux.MiddlewareFunc
}
ICORS interface defines the method to get the CORS middleware handler.
type ICORSFactory ¶
type ICORSFactory interface {
NewCORS(config subrouter_config.CORSConfig) ICORS
}
Factory interface for creating CORS middleware for subrouters.
func NewCORSFactory ¶
func NewCORSFactory() ICORSFactory
NewCORS creates a new CORS middleware based on the provided configuration.
Click to show internal directories.
Click to hide internal directories.