modules.go 615 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. package modules
  2. import (
  3. "golang-fave/engine/wrapper"
  4. )
  5. type Modules struct {
  6. //
  7. }
  8. func New() *Modules {
  9. m := Modules{}
  10. return &m
  11. }
  12. func (this *Modules) Load() {
  13. // Called before server starts
  14. }
  15. // All actions here...
  16. // MySQL install
  17. // MySQL first user
  18. // User login
  19. // User logout
  20. // Called inside goroutine
  21. func (this *Modules) Action(wrap *wrapper.Wrapper) bool {
  22. //
  23. return false
  24. }
  25. // Called inside goroutine
  26. func (this *Modules) FrontEnd(wrap *wrapper.Wrapper) bool {
  27. //
  28. return false
  29. }
  30. // Called inside goroutine
  31. func (this *Modules) BackEnd(wrap *wrapper.Wrapper) bool {
  32. //
  33. return false
  34. }