<?php

namespace CfcalSasieSDK\Entity;

use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for SectionCompteBancaire Entity
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:SectionCompteBancaire
 * @subpackage Structs
 */
class SectionCompteBancaire extends ObjetPublicSaisieEnLigneBase
{
    /**
     * The IBAN
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var \CfcalSasieSDK\Entity\IBAN
     */
    public $IBAN;
    /**
     * Constructor method for SectionCompteBancaire
     * @uses SectionCompteBancaire::setIBAN()
     * @param \CfcalSasieSDK\Entity\IBAN $iBAN
     */
    public function __construct(\CfcalSasieSDK\Entity\IBAN $iBAN = null)
    {
        $this
            ->setIBAN($iBAN);
    }
    /**
     * Get IBAN value
     * An additional test has been added (isset) before returning the property value as
     * this property may have been unset before, due to the fact that this property is
     * removable from the request (nillable=true+minOccurs=0)
     * @return \CfcalSasieSDK\Entity\IBAN|null
     */
    public function getIBAN()
    {
        return isset($this->IBAN) ? $this->IBAN : null;
    }
    /**
     * Set IBAN value
     * This property is removable from request (nillable=true+minOccurs=0), therefore
     * if the value assigned to this property is null, it is removed from this object
     * @param \CfcalSasieSDK\Entity\IBAN $iBAN
     * @return \CfcalSasieSDK\Entity\SectionCompteBancaire
     */
    public function setIBAN(\CfcalSasieSDK\Entity\IBAN $iBAN = null)
    {
        if (is_null($iBAN) || (is_array($iBAN) && empty($iBAN))) {
            unset($this->IBAN);
        } else {
            $this->IBAN = $iBAN;
        }
        return $this;
    }
}
