Class PayPalRefundRequest
java.lang.Object
com.broadleafcommerce.paypal.micro.domain.api.AbstractPayPalRequest<Refund>
com.broadleafcommerce.paypal.micro.domain.api.PayPalRefundRequest
- All Implemented Interfaces:
PayPalRequest
Represents a refund request. To partially refund an order, specify
RefundRequest.setAmount(Money)
, otherwise the refund request may be empty (but not null).-
Constructor Summary
ConstructorsConstructorDescriptionPayPalRefundRequest
(PayPalApiProvider apiProvider, com.broadleafcommerce.paymentgateway.domain.PaymentRequest paymentRequest, RefundRequest refundRequest, String captureId) -
Method Summary
Modifier and TypeMethodDescriptionprotected AbstractPayPalResponse<Refund>
executeInternal
(String applicationId, String tenantId) Executes the configured request using thePayPalApiProvider
.protected String
protected RefundRequest
protected boolean
Implementation specific determination of whether the request can be executed.Methods inherited from class com.broadleafcommerce.paypal.micro.domain.api.AbstractPayPalRequest
buildIdempotencyKey, configureRequestHeaders, execute, getPaymentRequest, getPayPalApiProvider, isExecuted, isValid, preferMinimalHeader, preferRepresentationHeader
-
Constructor Details
-
PayPalRefundRequest
public PayPalRefundRequest(PayPalApiProvider apiProvider, com.broadleafcommerce.paymentgateway.domain.PaymentRequest paymentRequest, RefundRequest refundRequest, String captureId)
-
-
Method Details
-
executeInternal
protected AbstractPayPalResponse<Refund> executeInternal(@Nullable String applicationId, @Nullable String tenantId) throws PayPalProviderApiException Description copied from class:AbstractPayPalRequest
Executes the configured request using thePayPalApiProvider
.- Specified by:
executeInternal
in classAbstractPayPalRequest<Refund>
- Parameters:
applicationId
- the application IDtenantId
- the tenant ID- Returns:
- The response from PayPal
- Throws:
PayPalProviderApiException
- Thrown if the request execution fails.
-
isValidInternal
protected boolean isValidInternal()Description copied from class:AbstractPayPalRequest
Implementation specific determination of whether the request can be executed.- Specified by:
isValidInternal
in classAbstractPayPalRequest<Refund>
- Returns:
- Whether the request can be executed or is in an erroneous state.
-
getCaptureId
-
getRefundRequest
-