public function createFromFile($path, $mimeType, $filename = '')
    {
        $destination = $this->buildDestination();

        try {
            return FileSystemFile::createFromExistingFile($path, $destination, $mimeType, $filename);
        } catch (RuntimeException $e) {
            $msg = "An error occured while creating a QTI FileSystemFile object.";
            throw new FileManagerException($msg, 0, $e);
        }
    }
public function createFromFile($path, $mimeType, $filename = '')
    {
        $destination = $this->buildDestination();

        try {
            return FileSystemFile::createFromExistingFile($path, $destination, $mimeType, $filename);
        } catch (RuntimeException $e) {
            $msg = "An error occured while creating a QTI FileSystemFile object.";
            throw new FileManagerException($msg, 0, $e);
        }
    }
public function createFromFile ( $ path , $ mimeType , $ filename = '' ) { $ destination = $ this -> buildDestination ( ) ; try { return FileSystemFile :: createFromExistingFile ( $ path , $ destination , $ mimeType , $ filename ) ; } catch ( RuntimeException $ e ) { $ msg = "An error occured while creating a QTI FileSystemFile object." ; throw new FileManagerException ( $ msg , 0 , $ e ) ; } }
Create a FileSystemFile object from an existing
file on the file system.

@param string $path The canonical path to the file.
@param string $mimeType The mime-type of the file (if you want to force it).
@param string $filename The file name of the file (if you want to force it).
@throws \qtism\common\datatypes\files\FileManagerException
@return \qtism\common\datatypes\files\FileSystemFile
Create a FileSystemFile object from an existing file on the file system .