Dumplie\CustomerService\Domain\Payment::__construct PHP Method

__construct() public method

public __construct ( PaymentId $id, Order $order )
$id PaymentId
$order Order
    public function __construct(PaymentId $id, Order $order)
    {
        $this->id = $id;
        $this->createdAt = new \DateTimeImmutable();
        $this->orderId = $order->id();
        $this->state = new Unpaid();
    }