This commit is contained in:
2025-07-03 23:46:08 +03:00
parent 7fe2402ff3
commit ab4499a305
39 changed files with 453 additions and 56 deletions

View File

@@ -18,4 +18,4 @@ class CashPayment implements PaymentInterface
/** @noinspection ForgottenDebugOutputInspection */
dump("Cash payment success, amount: {$order->getSum()}");
}
}
}

View File

@@ -18,4 +18,4 @@ class IngPayment implements PaymentInterface
/** @noinspection ForgottenDebugOutputInspection */
dump("ING Bank payment success, amount: {$order->getSum()}");
}
}
}

View File

@@ -17,4 +17,4 @@ class IngPaymentFactory implements PaymentFactoryInterface
{
return new IngPayment();
}
}
}

View File

@@ -18,4 +18,4 @@ class OtpPayment implements PaymentInterface
/** @noinspection ForgottenDebugOutputInspection */
dump("Otp Bank payment success, amount: {$order->getSum()}");
}
}
}

View File

@@ -17,4 +17,4 @@ class OtpPaymentFactory implements PaymentFactoryInterface
{
return new OtpPayment();
}
}
}

View File

@@ -14,4 +14,4 @@ namespace Pattern\Creational\FactoryMethod;
interface PaymentInterface
{
public function pay(Order $order): void;
}
}

View File

@@ -18,4 +18,4 @@ class PrivatPayment implements PaymentInterface
/** @noinspection ForgottenDebugOutputInspection */
dump("Privatbank payment success, amount: {$order->getSum()}");
}
}
}

View File

@@ -18,4 +18,4 @@ class RaiffeisenPayment implements PaymentInterface
/** @noinspection ForgottenDebugOutputInspection */
dump("Raiffeisen Bank payment success, amount: {$order->getSum()}");
}
}
}

View File

@@ -17,4 +17,4 @@ class RaiffeisenPaymentFactory implements PaymentFactoryInterface
{
return new RaiffeisenPayment();
}
}
}