Api\StructType\ApiNewsArticle::setDate PHP Method

setDate() public method

Set Date value
public setDate ( string $date = null ) : ApiNewsArticle
$date string
return ApiNewsArticle
    public function setDate($date = null)
    {
        // validation for constraint: string
        if (!is_null($date) && !is_string($date)) {
            throw new \InvalidArgumentException(sprintf('Invalid value, please provide a string, "%s" given', gettype($date)), __LINE__);
        }
        $this->Date = $date;
        return $this;
    }