Nextcloud PHP API (master)

IStorageFactory

Creates storage instances and manages and applies storage wrappers

Tags
since
8.0.0
Attributes
#[Consumable]
$since: '8.0.0'

Table of Contents

Methods

addStorageWrapper()  : bool
Allow modifier storage behaviour by adding wrappers around storages.
getInstance()  : IStorage

Methods

addStorageWrapper()

Allow modifier storage behaviour by adding wrappers around storages.

public addStorageWrapper(non-empty-string $wrapperName, callable(string $mountPoint, IStorage $storage, IMountPoint $mountPoint): IStorage $callback[, int<0, 100> $priority = 50 ][, array<string|int, IMountPoint$existingMounts = [] ]) : bool

The BeforeFileSystemSetupEvent should be used in most cases instead to add storage wrappers.

Parameters
$wrapperName : non-empty-string
$callback : callable(string $mountPoint, IStorage $storage, IMountPoint $mountPoint): IStorage
$priority : int<0, 100> = 50
$existingMounts : array<string|int, IMountPoint> = []
Tags
since
8.0.0
see
BeforeFileSystemSetupEvent
Return values
bool

true if the wrapper was added, false if there was already a wrapper with this name registered

On this page

Search results