selectLogic
Selects a module's logic instance by its type.
Use this to access another module's logic for cross-module operations.
Example:
class OrderLogic(private val storeAccessor: StoreAccessor) : ModuleLogic() {
suspend fun processOrder() {
val paymentLogic = storeAccessor.selectLogic<PaymentLogic>()
paymentLogic.processPayment(amount)
}
}Content copied to clipboard
Return
The logic instance of the requested type
Throws
if no module with the specified logic type is registered