SilverStripe\Omnipay\Service\ServiceFactory
Synopsis
class ServiceFactory
{
- // constants
- const INTENT_AUTHORIZE = "authorize";
- const INTENT_CREATECARD = "createcard";
- const INTENT_PURCHASE = "purchase";
- const INTENT_REFUND = "refund";
- const INTENT_VOID = "void";
- const INTENT_CAPTURE = "capture";
- const INTENT_PAYMENT = "payment";
- // members
- private static array $services = ;
- // methods
- public PaymentService getService()
- protected PaymentService createPaymentService()
Hierarchy
Uses
- SilverStripe\Core\Injector\Injectable
- SilverStripe\Core\Extensible
- SilverStripe\Core\Config\Configurable
Constants
Name | Value |
---|---|
INTENT_AUTHORIZE | "authorize" |
INTENT_CREATECARD | "createcard" |
INTENT_PURCHASE | "purchase" |
INTENT_REFUND | "refund" |
INTENT_VOID | "void" |
INTENT_CAPTURE | "capture" |
INTENT_PAYMENT | "payment" |
Members
private
- $services — array
Methods
protected
- createPaymentService() — Create a payment service. This will either return an AuthorizeService or PurchaseService, depending on the gateway config.
public
- getService() — Create a service for the given payment and intent.