Set the name for the download file

@param   string                                 The name for the download file
@return  \Th\FileDownloader                     The instance of this to make chaining possible
356516
public function setName($name) {
        // get the path info of the given name
        $pathinfo = pathinfo($name);
        
        // get the base file name
        $filename = $pathinfo['filename'];
        
        // set the file name
        $this->name = $filename . '.' . $this->extension();

        // done, return the instance of this, to make chaining possible
        return $this;
    }
86601
final public function setDestinationFilename(string $filename)
    {
        $extension = pathinfo($filename, PATHINFO_EXTENSION);
        if (empty($extension) && !empty($this->uploadFile->getExtension())) {
            $filename .= '.' . $this->uploadFile->getExtension();
        }
        $this->destinationFilename = $filename;
    }
428855
public function setName($name)
    {
        $this->name = $name;
        $this->setChecked($this->form->getFieldValue($this->name) == $this->getValue());
        return $this;
    }
836441
public function setName($name)
    {
        $inflectMethod = $this->getInflectionMethod();
        $this->_name = Inflector::$inflectMethod($name);

        return $this;
    }
658692
public function setName($name)
    {
        if (null !== $name) {
            Assert::string($name, 'The application name must be a string. Got: %s');
            Assert::notEmpty($name, 'The application name must not be empty.');
            Assert::regex($name, '~^[a-zA-Z0-9\-]+$~', 'The application name must contain letters, numbers and hyphens only. Did you mean to call setDisplayName()?');
        }

        $this->name = $name;

        return $this;
    }
1001707
public function setName($name)
    {
        $this->name = $name;
        $this->setValue($this->form->getFieldValue($this->name));
        return $this;
    }
751831
protected function setFileName($file)
    {
        if (isset($this->options['thumbnails'])) {
            $thumbs = isset($this->options['changeThumb'])
                ? $this->options['thumbnails'][$this->options['changeThumb']]
                : $this->options['thumbnails'];
            $thumbs = array_values($thumbs);
            $firstThumb = array_shift($thumbs);
            if (isset($firstThumb['name'])) {
                $this->fileName = str_replace(':time',time(),$firstThumb['name']);
                return;
            }
        }
        $this->fileName = $this->createFileName($file);
    }
795789
public function setFileName($filename)
  {
    $a = explode('.', $filename);

    $this->file_name      = $filename;
    $this->file_extension = count($a) >= 2 ? array_pop($a) : false;

    return $this;
  }
1102273
public function setDocumentFileName($documentFileName)
    {
        $this->documentFileName = $documentFileName;

        if ($documentFileName) {
            $this->setDocument('/uploads/documents/'.$documentFileName);
            if ( ! $this->link) {
                $this->link = '/uploads/documents/'.$documentFileName;
            }
        } else {
            // Remove deleted file from database
            if ($this->link == $this->document) {
                $this->link = null;
            }
            $this->setDocument(null);
        }

        return $this;
    }
881410
protected function setFilename($filename)
    {
        $parts = explode('.', $filename);

        $extension = array_pop($parts);

        $name = time() . '-' . str_slug(str_random(35));

        return "{$name}.{$extension}";
    }
720696
public function setName($name)
    {
        if (false !== stripos($name, '.')) {
            $relations = explode('.', $name);
            $name = array_pop($relations);
            $this->relation = implode('.', $relations);
        }

        $this->name = $name;

        return $this;
    }
653631
public function setName($name)
    {
        $this->name = (string)$name;
        $this->getEntry()
             ->setName($this->name);
        return $this;
    }
1181825
private function setClientFilename($clientFilename)
    {
        if (preg_match('`[/\\]+`', $clientFilename) > 0) {
            throw new \InvalidArgumentException('Filename contain invalid character "\" or "/" in his name.');
        }

        $this->clientFilename = (empty($clientFilename) ? null : (string) $clientFilename);

        return $this;
    }
760506
public function set_name($name)
    {
        $previous_name = $this->name;

        $name = self::generateName($name, $this->app['unicode']);

        if ($name === '') {
            throw new \Exception_InvalidArgument();
        }

        $this->name = $name;

        if ($this->name !== $previous_name) {
            $this->renamed = true;
        }

        return $this;
    }
856891
public function setName($name = null)
    {
        $this->fileName = $this->caDataRoot . $name . DS;

        // Create folder for future certificate
        if(!file_exists($this->fileName))
        {
            mkdir($this->fileName, 0777, true);
        }

        return $this;
    }
453813
public function setName($name)
	{
		$this->_name = $name;
		$this->setPath('template', $this->_basePath . '/views/' . $this->getName() . '/tmpl');

		return $this;
	}
290037
public function setName($name)
    {
        // Set name in payload
        $payload = $this->getPayload();
        $payload['name'] = $name;

        return $this->setPayload($payload);
    }