egovernor

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 11, 2020 License: MIT Imports: 16 Imported by: 13

Documentation

Index

Constants

View Source
const PackageName = "server.egin"

Variables

View Source
var (
	// DefaultServeMux ...
	DefaultServeMux = http.NewServeMux()
)

Functions

func HandleFunc

func HandleFunc(pattern string, handler http.HandlerFunc)

HandleFunc ...

Types

type Component

type Component struct {
	*http.Server
	// contains filtered or unexported fields
}

Component ...

func (*Component) GracefulStop

func (s *Component) GracefulStop(ctx context.Context) error

GracefulStop ..

func (*Component) Info

func (s *Component) Info() *server.ServiceInfo

Info ..

func (*Component) Init

func (c *Component) Init() error

func (*Component) Name

func (c *Component) Name() string

func (*Component) PackageName

func (c *Component) PackageName() string

func (*Component) Start

func (s *Component) Start() error

Serve ..

func (*Component) Stop

func (s *Component) Stop() error

Stop ..

type Config

type Config struct {
	Host    string
	Port    int
	Network string
}

func DefaultConfig

func DefaultConfig() *Config

func (Config) Address

func (config Config) Address() string

type Container

type Container struct {
	// contains filtered or unexported fields
}

func DefaultContainer

func DefaultContainer() *Container

func Load

func Load(key string) *Container

func (*Container) Build

func (c *Container) Build() *Component

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL