如何注入瞬间依赖工厂与Kodein?

我想使用ViewModelProvider工厂从意图(即:俱乐部)注入自定义parcelable数据。

val teamModule = Kodein.Module { bind<ViewModelProvider.Factory>("team-factory") with factory { club: Club -> TeamListViewModelFactory(club, instance()) } bind<GetTeams>() with provider { GetTeams(instance()) } bind<TeamRepository>() with provider { TeamDataRepository(instance()) } bind<TeamListViewModel>() with factory { context: FragmentActivity -> ViewModelProviders.of(context, instance("team-factory")).get(TeamListViewModel::class.java) } } 

在我的活动中,我想从内置的意图数据获取一个viewModel。在这里我的活动:

 class TeamActivity : AppCompatActivity(), KodeinInjected { override val injector = KodeinInjector() private val viewModel: TeamListViewModel by injector.with(this).instance() // and intent.getParcelable<Club>(CLUB) but no idea how } 

任何想法?