File tree Expand file tree Collapse file tree 10 files changed +16
-16
lines changed
core/src/main/java/com/adyen/checkout/core Expand file tree Collapse file tree 10 files changed +16
-16
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ import com.adyen.checkout.core.components.CheckoutCallback
12
12
import com.adyen.checkout.core.components.CheckoutResult
13
13
import kotlinx.coroutines.CoroutineScope
14
14
15
- internal class AdvancedComponentEventHandler <T : BaseComponentState >(
15
+ internal class AdvancedComponentEventHandler <T : BasePaymentComponentState >(
16
16
private val checkoutCallback : CheckoutCallback
17
17
) :
18
18
ComponentEventHandler <T > {
Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ internal class AdvancedPaymentFacilitatorFactory(
38
38
)
39
39
40
40
val componentEventHandler =
41
- AdvancedComponentEventHandler <BaseComponentState >(
41
+ AdvancedComponentEventHandler <BasePaymentComponentState >(
42
42
checkoutCallback,
43
43
)
44
44
Original file line number Diff line number Diff line change @@ -11,4 +11,4 @@ package com.adyen.checkout.core.components.internal
11
11
import com.adyen.checkout.core.components.paymentmethod.PaymentComponentState
12
12
import com.adyen.checkout.core.components.paymentmethod.PaymentMethodDetails
13
13
14
- internal typealias BaseComponentState = PaymentComponentState <out PaymentMethodDetails >
14
+ internal typealias BasePaymentComponentState = PaymentComponentState <out PaymentMethodDetails >
Original file line number Diff line number Diff line change @@ -11,10 +11,10 @@ package com.adyen.checkout.core.components.internal
11
11
import androidx.annotation.RestrictTo
12
12
13
13
@RestrictTo(RestrictTo .Scope .LIBRARY_GROUP )
14
- sealed class PaymentComponentEvent <ComponentStateT : BaseComponentState > {
14
+ sealed class PaymentComponentEvent <ComponentStateT : BasePaymentComponentState > {
15
15
16
16
@RestrictTo(RestrictTo .Scope .LIBRARY_GROUP )
17
- class Submit <ComponentStateT : BaseComponentState >(
17
+ class Submit <ComponentStateT : BasePaymentComponentState >(
18
18
val state : ComponentStateT
19
19
) : PaymentComponentEvent<ComponentStateT>()
20
20
}
Original file line number Diff line number Diff line change @@ -28,9 +28,9 @@ import kotlinx.coroutines.flow.launchIn
28
28
import kotlinx.coroutines.flow.onEach
29
29
30
30
internal class PaymentFacilitator (
31
- private val paymentComponent : PaymentComponent <BaseComponentState >,
31
+ private val paymentComponent : PaymentComponent <BasePaymentComponentState >,
32
32
private val coroutineScope : CoroutineScope ,
33
- private val componentEventHandler : ComponentEventHandler <BaseComponentState >,
33
+ private val componentEventHandler : ComponentEventHandler <BasePaymentComponentState >,
34
34
private val actionProvider : ActionProvider ,
35
35
private val checkoutController : CheckoutController ,
36
36
) {
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import com.adyen.checkout.core.sessions.internal.model.SessionParams
15
15
import kotlinx.coroutines.CoroutineScope
16
16
17
17
@RestrictTo(RestrictTo .Scope .LIBRARY_GROUP )
18
- interface PaymentMethodFactory <CS : BaseComponentState , T : PaymentComponent <CS >> {
18
+ interface PaymentMethodFactory <CS : BasePaymentComponentState , T : PaymentComponent <CS >> {
19
19
20
20
/* *
21
21
* Creates a [PaymentComponent].
Original file line number Diff line number Diff line change @@ -41,13 +41,13 @@ object PaymentMethodProvider {
41
41
coroutineScope : CoroutineScope ,
42
42
checkoutConfiguration : CheckoutConfiguration ,
43
43
componentSessionParams : SessionParams ? ,
44
- ): PaymentComponent <BaseComponentState > {
44
+ ): PaymentComponent <BasePaymentComponentState > {
45
45
@Suppress(" UNCHECKED_CAST" )
46
46
return factories[txVariant]?.create(
47
47
coroutineScope = coroutineScope,
48
48
checkoutConfiguration = checkoutConfiguration,
49
49
componentSessionParams = componentSessionParams,
50
- ) as ? PaymentComponent <BaseComponentState > ? : run {
50
+ ) as ? PaymentComponent <BasePaymentComponentState > ? : run {
51
51
// TODO - Errors Propagation [COSDK-85]. Propagate an initialization error via onError()
52
52
error(" Factory for payment method type: $txVariant is not registered." )
53
53
}
Original file line number Diff line number Diff line change 9
9
package com.adyen.checkout.core.components.internal.ui
10
10
11
11
import androidx.annotation.RestrictTo
12
- import com.adyen.checkout.core.components.internal.BaseComponentState
12
+ import com.adyen.checkout.core.components.internal.BasePaymentComponentState
13
13
import com.adyen.checkout.core.components.internal.PaymentComponentEvent
14
14
import kotlinx.coroutines.flow.Flow
15
15
16
16
@RestrictTo(RestrictTo .Scope .LIBRARY_GROUP )
17
- interface EventComponent <T : BaseComponentState > {
17
+ interface EventComponent <T : BasePaymentComponentState > {
18
18
19
19
val eventFlow: Flow <PaymentComponentEvent <T >>
20
20
}
Original file line number Diff line number Diff line change 9
9
package com.adyen.checkout.core.components.internal.ui
10
10
11
11
import androidx.annotation.RestrictTo
12
- import com.adyen.checkout.core.components.internal.BaseComponentState
12
+ import com.adyen.checkout.core.components.internal.BasePaymentComponentState
13
13
14
14
// TODO - Some components might not be composable,
15
15
// Move ComposableComponent to PaymentMethod specific component later
16
16
@RestrictTo(RestrictTo .Scope .LIBRARY_GROUP )
17
- interface PaymentComponent <T : BaseComponentState > :
17
+ interface PaymentComponent <T : BasePaymentComponentState > :
18
18
ComposableComponent ,
19
19
EventComponent <T > {
20
20
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ import com.adyen.checkout.core.common.internal.api.HttpClientFactory
14
14
import com.adyen.checkout.core.components.CheckoutCallback
15
15
import com.adyen.checkout.core.components.CheckoutConfiguration
16
16
import com.adyen.checkout.core.components.CheckoutController
17
- import com.adyen.checkout.core.components.internal.BaseComponentState
17
+ import com.adyen.checkout.core.components.internal.BasePaymentComponentState
18
18
import com.adyen.checkout.core.components.internal.PaymentFacilitator
19
19
import com.adyen.checkout.core.components.internal.PaymentFacilitatorFactory
20
20
import com.adyen.checkout.core.components.internal.PaymentMethodProvider
@@ -54,7 +54,7 @@ internal class SessionsPaymentFacilitatorFactory(
54
54
55
55
// TODO - Based on txVariant, needs to be abstracted away
56
56
val componentEventHandler =
57
- SessionsComponentEventHandler <BaseComponentState >(
57
+ SessionsComponentEventHandler <BasePaymentComponentState >(
58
58
sessionInteractor = sessionInteractor,
59
59
checkoutCallback = checkoutCallback,
60
60
)
You can’t perform that action at this time.
0 commit comments