<?php

declare(strict_types=1);

/*
 * PaypalServerSDKLib
 *
 * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
 */

namespace PaypalServerSDKLib\Models\Builders;

use Core\Utils\CoreHelper;
use PaypalServerSDKLib\Models\VenmoWalletAdditionalAttributes;
use PaypalServerSDKLib\Models\VenmoWalletCustomerInformation;
use PaypalServerSDKLib\Models\VenmoWalletVaultAttributes;

/**
 * Builder for model VenmoWalletAdditionalAttributes
 *
 * @see VenmoWalletAdditionalAttributes
 */
class VenmoWalletAdditionalAttributesBuilder
{
    /**
     * @var VenmoWalletAdditionalAttributes
     */
    private $instance;

    private function __construct(VenmoWalletAdditionalAttributes $instance)
    {
        $this->instance = $instance;
    }

    /**
     * Initializes a new venmo wallet additional attributes Builder object.
     */
    public static function init(): self
    {
        return new self(new VenmoWalletAdditionalAttributes());
    }

    /**
     * Sets customer field.
     */
    public function customer(?VenmoWalletCustomerInformation $value): self
    {
        $this->instance->setCustomer($value);
        return $this;
    }

    /**
     * Sets vault field.
     */
    public function vault(?VenmoWalletVaultAttributes $value): self
    {
        $this->instance->setVault($value);
        return $this;
    }

    /**
     * Initializes a new venmo wallet additional attributes object.
     */
    public function build(): VenmoWalletAdditionalAttributes
    {
        return CoreHelper::clone($this->instance);
    }
}
