<?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\Money;
use PaypalServerSDKLib\Models\RefundPlatformFee;

/**
 * Builder for model RefundPlatformFee
 *
 * @see RefundPlatformFee
 */
class RefundPlatformFeeBuilder
{
    /**
     * @var RefundPlatformFee
     */
    private $instance;

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

    /**
     * Initializes a new refund platform fee Builder object.
     */
    public static function init(Money $amount): self
    {
        return new self(new RefundPlatformFee($amount));
    }

    /**
     * Initializes a new refund platform fee object.
     */
    public function build(): RefundPlatformFee
    {
        return CoreHelper::clone($this->instance);
    }
}
