39 lines
966 B
Go
39 lines
966 B
Go
//go:build wireinject
|
|
// +build wireinject
|
|
|
|
// The build tag makes sure the stub is not built in the final build.
|
|
|
|
package main
|
|
|
|
import (
|
|
"github.com/go-kratos/kratos/v2"
|
|
"github.com/go-kratos/kratos/v2/log"
|
|
"github.com/google/wire"
|
|
"voucher/internal/biz"
|
|
"voucher/internal/biz/cmb"
|
|
"voucher/internal/conf"
|
|
"voucher/internal/data"
|
|
"voucher/internal/data/mixrepoimpl"
|
|
"voucher/internal/data/repoimpl"
|
|
"voucher/internal/data/wechatrepoimpl"
|
|
log2 "voucher/internal/pkg/log"
|
|
"voucher/internal/server"
|
|
"voucher/internal/service"
|
|
)
|
|
|
|
// wireApp init kratos application.
|
|
func wireApp(*conf.Bootstrap, log.Logger, *log2.AccessLogger) (*kratos.App, func(), error) {
|
|
panic(wire.Build(
|
|
server.ProviderSetServer,
|
|
service.ProviderSetService,
|
|
cmb.ProviderSetCmb,
|
|
biz.ProviderSetBiz,
|
|
data.ProviderDataSet,
|
|
repoimpl.ProviderRepoImplSet,
|
|
wechatrepoimpl.ProviderWechatReposImplSet,
|
|
mixrepoimpl.ProviderMixRepoImplSet,
|
|
log2.NewLogHelper,
|
|
newApp,
|
|
))
|
|
}
|