inline fun <reified I : Any> ComponentFactoryContainer.build(): I
(source)
Returns the component of type I using a corresponding factory or throws an IllegalStateException in case no factory was found which is able to build a component of the given type.
IllegalStateException
- in case ComponentFactoryContainer.buildOrNull returns null
because not suitable factory was found.
ClassCastException
- in case the factory returns an illegal type.