package com.ing.baker.tutorials.interactions

import com.ing.baker.recipe.annotations.FiresEvent
import com.ing.baker.recipe.annotations.RequiresIngredient
import com.ing.baker.recipe.javadsl.Interaction
import com.ing.baker.tutorials.events.SendInvoiceEvents
import com.ing.baker.tutorials.events.SendInvoiceEvents.InvoicingOutcome
import com.ing.baker.tutorials.model.CustomerInfo

interface SendInvoice : Interaction {

    @FiresEvent(oneOf = [SendInvoiceEvents.InvoiceSent::class])
    fun apply(@RequiresIngredient("customerInfo") customerInfo: CustomerInfo): InvoicingOutcome
}