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.     /**
  8.      * @var CalculatedPrice
  9.      */
  10.     protected $amount;
  11.     /**
  12.      * @var string
  13.      */
  14.     protected $paymentMethodId;
  15.     public function __construct(CalculatedPrice $amountstring $paymentMethodId)
  16.     {
  17.         $this->amount $amount;
  18.         $this->paymentMethodId $paymentMethodId;
  19.     }
  20.     public function getAmount(): CalculatedPrice
  21.     {
  22.         return $this->amount;
  23.     }
  24.     public function setAmount(CalculatedPrice $amount): void
  25.     {
  26.         $this->amount $amount;
  27.     }
  28.     public function getPaymentMethodId(): string
  29.     {
  30.         return $this->paymentMethodId;
  31.     }
  32.     public function setPaymentMethodId(string $paymentMethodId): void
  33.     {
  34.         $this->paymentMethodId $paymentMethodId;
  35.     }
  36.     public function getApiAlias(): string
  37.     {
  38.         return 'cart_transaction';
  39.     }
  40. }