<?php

declare (strict_types=1);
/*
 * PaypalServerSdkLib
 *
 * This file was automatically generated by APIMATIC v3.0 ( https://www.apimatic.io ).
 */
namespace FormGent\PaypalServerSdkLib\Models\Builders;

use FormGent\Core\Utils\CoreHelper;
use FormGent\PaypalServerSdkLib\Models\BinDetails;
use FormGent\PaypalServerSdkLib\Models\CardAuthenticationResponse;
use FormGent\PaypalServerSdkLib\Models\CardResponseAddress;
use FormGent\PaypalServerSdkLib\Models\CardVerificationDetails;
use FormGent\PaypalServerSdkLib\Models\NetworkTransactionReferenceEntity;
use FormGent\PaypalServerSdkLib\Models\SetupTokenResponseCard;
/**
 * Builder for model SetupTokenResponseCard
 *
 * @see SetupTokenResponseCard
 */
class SetupTokenResponseCardBuilder
{
    /**
     * @var SetupTokenResponseCard
     */
    private $instance;
    private function __construct(SetupTokenResponseCard $instance)
    {
        $this->instance = $instance;
    }
    /**
     * Initializes a new Setup Token Response Card Builder object.
     */
    public static function init() : self
    {
        return new self(new SetupTokenResponseCard());
    }
    /**
     * Sets name field.
     *
     * @param string|null $value
     */
    public function name(?string $value) : self
    {
        $this->instance->setName($value);
        return $this;
    }
    /**
     * Sets last digits field.
     *
     * @param string|null $value
     */
    public function lastDigits(?string $value) : self
    {
        $this->instance->setLastDigits($value);
        return $this;
    }
    /**
     * Sets brand field.
     *
     * @param string|null $value
     */
    public function brand(?string $value) : self
    {
        $this->instance->setBrand($value);
        return $this;
    }
    /**
     * Sets expiry field.
     *
     * @param string|null $value
     */
    public function expiry(?string $value) : self
    {
        $this->instance->setExpiry($value);
        return $this;
    }
    /**
     * Sets billing address field.
     *
     * @param CardResponseAddress|null $value
     */
    public function billingAddress(?CardResponseAddress $value) : self
    {
        $this->instance->setBillingAddress($value);
        return $this;
    }
    /**
     * Sets verification status field.
     *
     * @param string|null $value
     */
    public function verificationStatus(?string $value) : self
    {
        $this->instance->setVerificationStatus($value);
        return $this;
    }
    /**
     * Sets verification field.
     *
     * @param CardVerificationDetails|null $value
     */
    public function verification(?CardVerificationDetails $value) : self
    {
        $this->instance->setVerification($value);
        return $this;
    }
    /**
     * Sets network transaction reference field.
     *
     * @param NetworkTransactionReferenceEntity|null $value
     */
    public function networkTransactionReference(?NetworkTransactionReferenceEntity $value) : self
    {
        $this->instance->setNetworkTransactionReference($value);
        return $this;
    }
    /**
     * Sets authentication result field.
     *
     * @param CardAuthenticationResponse|null $value
     */
    public function authenticationResult(?CardAuthenticationResponse $value) : self
    {
        $this->instance->setAuthenticationResult($value);
        return $this;
    }
    /**
     * Sets bin details field.
     *
     * @param BinDetails|null $value
     */
    public function binDetails(?BinDetails $value) : self
    {
        $this->instance->setBinDetails($value);
        return $this;
    }
    /**
     * Sets type field.
     *
     * @param string|null $value
     */
    public function type(?string $value) : self
    {
        $this->instance->setType($value);
        return $this;
    }
    /**
     * Initializes a new Setup Token Response Card object.
     */
    public function build() : SetupTokenResponseCard
    {
        return CoreHelper::clone($this->instance);
    }
}
