//go:build !ignore_autogenerated
// +build !ignore_autogenerated

// Code generated by iocli, run 'iocli gen' to re-generate

package list

import (
	autowire "github.com/alibaba/ioc-golang/autowire"
	singleton "github.com/alibaba/ioc-golang/autowire/singleton"
	util "github.com/alibaba/ioc-golang/autowire/util"
)

func init() {
	listServiceImplStructDescriptor := &autowire.StructDescriptor{
		Factory: func() interface{} {
			return &listServiceImpl{}
		},
		ParamFactory: func() interface{} {
			var _ listServiceImplParamInterface = &listServiceImplParam{}
			return &listServiceImplParam{}
		},
		ConstructFunc: func(i interface{}, p interface{}) (interface{}, error) {
			param := p.(listServiceImplParamInterface)
			impl := i.(*listServiceImpl)
			return param.Init(impl)
		},
		Metadata: map[string]interface{}{
			"aop":      map[string]interface{}{},
			"autowire": map[string]interface{}{},
		},
		DisableProxy: true,
	}
	singleton.RegisterStructDescriptor(listServiceImplStructDescriptor)
}

type listServiceImplParamInterface interface {
	Init(impl *listServiceImpl) (*listServiceImpl, error)
}

var _listServiceImplSDID string

func GetlistServiceImplSingleton(p *listServiceImplParam) (*listServiceImpl, error) {
	if _listServiceImplSDID == "" {
		_listServiceImplSDID = util.GetSDIDByStructPtr(new(listServiceImpl))
	}
	i, err := singleton.GetImpl(_listServiceImplSDID, p)
	if err != nil {
		return nil, err
	}
	impl := i.(*listServiceImpl)
	return impl, nil
}
