defi.go 771 B

123456789101112131415161718192021222324252627282930313233
  1. // ================================================================================
  2. // Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
  3. // You can delete these comments if you wish manually maintain this interface file.
  4. // ================================================================================
  5. package service
  6. import (
  7. v1 "birdcall/api/defi/v1"
  8. "context"
  9. )
  10. type (
  11. IDefi interface {
  12. Support(ctx context.Context, req *v1.SupportReq) (*v1.CommonRes, error)
  13. Price(ctx context.Context, req *v1.PriceReq) (*v1.CommonRes, error)
  14. }
  15. )
  16. var (
  17. localDefi IDefi
  18. )
  19. func Defi() IDefi {
  20. if localDefi == nil {
  21. panic("implement not found for interface IDefi, forgot register?")
  22. }
  23. return localDefi
  24. }
  25. func RegisterDefi(i IDefi) {
  26. localDefi = i
  27. }