Imported from hako
This commit is contained in:
parent
f8377df327
commit
8b8447213f
10 changed files with 315 additions and 0 deletions
9
model/server.go
Normal file
9
model/server.go
Normal file
|
@ -0,0 +1,9 @@
|
|||
package model
|
||||
|
||||
import "context"
|
||||
|
||||
type Server interface {
|
||||
IsEnabled() bool
|
||||
Start(context.Context) error
|
||||
Stop(context.Context) error
|
||||
}
|
9
model/service.go
Normal file
9
model/service.go
Normal file
|
@ -0,0 +1,9 @@
|
|||
package model
|
||||
|
||||
import "context"
|
||||
|
||||
type Service interface {
|
||||
Start(context.Context) error
|
||||
Stop(context.Context) error
|
||||
WaitStop(context.Context) error
|
||||
}
|
5
model/template.go
Normal file
5
model/template.go
Normal file
|
@ -0,0 +1,5 @@
|
|||
package model
|
||||
|
||||
type TemplateEngine interface {
|
||||
Render(name string, data any) ([]byte, error)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue