public function deleteFile(StorageFacilityParams $params, $fileid)
    {
        $this->validateFileID($fileid);

        $storagePath = $this->generateStoragePath($params, $fileid);

        if (is_file($storagePath)) {
            if (!@unlink($storagePath)) {
                throw new StorageFacilityException("Cannot delete file '".$storagePath."'");
            } else {
                return true;
            }
        }
    }
public function deleteFile(StorageFacilityParams $params, $fileid)
    {
        $this->validateFileID($fileid);

        $storagePath = $this->generateStoragePath($params, $fileid);

        if (is_file($storagePath)) {
            if (!@unlink($storagePath)) {
                throw new StorageFacilityException("Cannot delete file '".$storagePath."'");
            } else {
                return true;
            }
        }
    }
public function deleteFile ( StorageFacilityParams $ params , $ fileid ) { $ this -> validateFileID ( $ fileid ) ; $ storagePath = $ this -> generateStoragePath ( $ params , $ fileid ) ; if ( is_file ( $ storagePath ) ) { if ( ! @ unlink ( $ storagePath ) ) { throw new StorageFacilityException ( "Cannot delete file '" . $ storagePath . "'" ) ; } else { return true ; } } }
Deletes a file in the storage facility.

@param Site   $site   Site used to determine storage location
@param string $fileid File identifier of stored file, ex. /path/to/file.jpg

@return boolean True upon success
@throws StorageFacilityException if operation fails
Deletes a file in the storage facility .