Nextcloud PHP API (master)

IProvider

Interface IProvider

Tags
since
8.1.0
deprecated
17.0.0

use IProviderV2 instead

Table of Contents

Methods

getMimeType()  : string
getThumbnail()  : bool|IImage
get thumbnail for file at path $path
isAvailable()  : bool
Check if a preview can be generated for $path

Methods

getMimeType()

public getMimeType() : string
Tags
since
8.1.0
Return values
string

Regex with the mimetypes that are supported by this provider

getThumbnail()

get thumbnail for file at path $path

public getThumbnail(string $path, int $maxX, int $maxY, bool $scalingup, View $fileview) : bool|IImage
Parameters
$path : string

Path of file

$maxX : int

The maximum X size of the thumbnail. It can be smaller depending on the shape of the image

$maxY : int

The maximum Y size of the thumbnail. It can be smaller depending on the shape of the image

$scalingup : bool

Disable/Enable upscaling of previews

$fileview : View

fileview object of user folder

Tags
since
8.1.0
Return values
bool|IImage

false if no preview was generated

isAvailable()

Check if a preview can be generated for $path

public isAvailable(FileInfo $file) : bool
Parameters
$file : FileInfo
Tags
since
8.1.0
Return values
bool

        
On this page

Search results