public static function fromString($time, $tz = null): self
    {
        return new self(self::_createDateTime($time, $tz));
    }
public static function fromString($time, $tz = null): self
    {
        return new self(self::_createDateTime($time, $tz));
    }
public static function fromString ( $ time , $ tz = null ) : self { return new self ( self :: _createDateTime ( $ time , $ tz ) ) ; }
Initialize from date string.

@param string|null $time
@param string|null $tz
@return self
Initialize from date string .