vendor/shopware/core/Checkout/Cart/Transaction/Struct/Transaction.php line 8

Open in your IDE?
  1. <?php declare(strict_types=1);
  2. namespace Shopware\Core\Checkout\Cart\Transaction\Struct;
  3. use Shopware\Core\Checkout\Cart\Price\Struct\CalculatedPrice;
  4. use Shopware\Core\Framework\Struct\Struct;
  5. class Transaction extends Struct
  6. {
  7.     /** @var CalculatedPrice */
  8.     protected $amount;
  9.     /** @var string */
  10.     protected $paymentMethodId;
  11.     public function __construct(CalculatedPrice $amountstring $paymentMethodId)
  12.     {
  13.         $this->amount $amount;
  14.         $this->paymentMethodId $paymentMethodId;
  15.     }
  16.     public function getAmount(): CalculatedPrice
  17.     {
  18.         return $this->amount;
  19.     }
  20.     public function setAmount(CalculatedPrice $amount): void
  21.     {
  22.         $this->amount $amount;
  23.     }
  24.     public function getPaymentMethodId(): string
  25.     {
  26.         return $this->paymentMethodId;
  27.     }
  28.     public function setPaymentMethodId(string $paymentMethodId): void
  29.     {
  30.         $this->paymentMethodId $paymentMethodId;
  31.     }
  32.     public function getApiAlias(): string
  33.     {
  34.         return 'cart_transaction';
  35.     }
  36. }