PHP Class Devise\Media\Files\Manager

Datei anzeigen Open project: devisephp/cms

Protected Properties

Property Type Description
$CategoryPaths Devise\Media\Categories\CategoryPaths
$Filesystem Filesystem
$Image Image

Public Methods

Method Description
__construct ( Filesystem $Filesystem, CategoryPaths $CategoryPaths, MediaPaths $MediaPaths, Images $Image, Caption $Caption, $Config = null ) Construct a new File manager
removeUploadedFile ( string $filepath ) : void Remove uploaded files from the /media directory
renameUploadedFile ( string $filepath, string $newpath ) : void Renames an uploaded file
saveUploadedFile ( $input ) : boolean Saves the uploaded file to the media directory

Private Methods

Method Description
createFile ( File $file, string $serverPath, string $originalName ) : string Checks for file existence and then creates file.
getThumbnailPath ( $currentName ) : string Change this

Method Details

__construct() public method

Construct a new File manager
public __construct ( Filesystem $Filesystem, CategoryPaths $CategoryPaths, MediaPaths $MediaPaths, Images $Image, Caption $Caption, $Config = null )
$Filesystem Filesystem
$CategoryPaths Devise\Media\Categories\CategoryPaths
$MediaPaths Devise\Media\MediaPaths
$Image Devise\Media\Images\Images
$Caption Devise\Media\Helpers\Caption

removeUploadedFile() public method

Remove uploaded files from the /media directory
public removeUploadedFile ( string $filepath ) : void
$filepath string
return void

renameUploadedFile() public method

Renames an uploaded file
public renameUploadedFile ( string $filepath, string $newpath ) : void
$filepath string
$newpath string
return void

saveUploadedFile() public method

Saves the uploaded file to the media directory
public saveUploadedFile ( $input ) : boolean
$input
return boolean

Property Details

$CategoryPaths protected_oe property

protected CategoryPaths,Devise\Media\Categories $CategoryPaths
return Devise\Media\Categories\CategoryPaths

$Filesystem protected_oe property

protected Filesystem,Devise\Media\Files $Filesystem
return Filesystem

$Image protected_oe property

protected Image $Image
return Image