<?php
use \WsdlToPhp\PackageBase\AbstractStructBase;

/**
 * This class stands for GetTestoNotifica_Result StructType
 * Meta information extracted from the WSDL
 * - nillable: true
 * - type: tns:GetTestoNotifica_Result
 * @subpackage Structs
 */
class GetTestoNotifica_Result extends WebService_GenericResult
{
    /**
     * The Testo
     * Meta information extracted from the WSDL
     * - minOccurs: 0
     * - nillable: true
     * @var string
     */
    public $Testo;
    /**
     * Constructor method for GetTestoNotifica_Result
     * @uses GetTestoNotifica_Result::setTesto()
     * @param string $testo
     */
    public function __construct($testo = null)
    {
        $this
            ->setTesto($testo);
    }
    /**
     * Get Testo 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 string|null
     */
    public function getTesto()
    {
        return isset($this->Testo) ? $this->Testo : null;
    }
    /**
     * Set Testo 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 string $testo
     * @return GetTestoNotifica_Result
     */
    public function setTesto($testo = null)
    {
        // validation for constraint: string
        if (!is_null($testo) && !is_string($testo)) {
            throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($testo, true), gettype($testo)), __LINE__);
        }
        if (is_null($testo) || (is_array($testo) && empty($testo))) {
            unset($this->Testo);
        } else {
            $this->Testo = $testo;
        }
        return $this;
    }
}
