//workflow/com.squareup.workflow1.ui/toViewFactory
toViewFactory¶
[androidJvm]
Content
@WorkflowUiExperimentalApi()
fun <ScreenT : Screen> ScreenT.toViewFactory(environment: ViewEnvironment): ScreenViewFactory<ScreenT>
More info
It is rare to call this method directly. Instead the most common path is to pass Screen instances to WorkflowViewStub.show, which will apply the ScreenViewFactory machinery for you.
Use the ScreenViewFactoryFinder in environment to return the ScreenViewFactory bound to the type of the receiving Screen. Call ScreenViewFactory.startShowing to create and initialize a new View.