<?php
/*
 * PagarmeCoreApiLib
 *
 * This file was automatically generated by APIMATIC v2.0 ( https://apimatic.io ).
 */

namespace PagarmeCoreApiLib\Models;

use JsonSerializable;

/**
 *Pix payer data.
 */
class GetPixPayerResponse implements JsonSerializable
{
    /**
     * @todo Write general description for this property
     * @var string|null $name public property
     */
    public $name;

    /**
     * @todo Write general description for this property
     * @var string|null $document public property
     */
    public $document;

    /**
     * @todo Write general description for this property
     * @maps document_type
     * @var string|null $documentType public property
     */
    public $documentType;

    /**
     * @todo Write general description for this property
     * @maps bank_account
     * @var \PagarmeCoreApiLib\Models\GetPixBankAccountResponse|null $bankAccount public property
     */
    public $bankAccount;

    /**
     * Constructor to set initial or default values of member properties
     * @param string                    $name         Initialization value for $this->name
     * @param string                    $document     Initialization value for $this->document
     * @param string                    $documentType Initialization value for $this->documentType
     * @param GetPixBankAccountResponse $bankAccount  Initialization value for $this->bankAccount
     */
    public function __construct()
    {
        if (4 == func_num_args()) {
            $this->name         = func_get_arg(0);
            $this->document     = func_get_arg(1);
            $this->documentType = func_get_arg(2);
            $this->bankAccount  = func_get_arg(3);
        }
    }


    /**
     * Encode this object to JSON
     */
    #[\ReturnTypeWillChange]
    public function jsonSerialize()
    {
        $json = array();
        $json['name']          = $this->name;
        $json['document']      = $this->document;
        $json['document_type'] = $this->documentType;
        $json['bank_account']  = $this->bankAccount;

        return $json;
    }
}
