class Illuminate / Filesystem / FilesystemManager

FilesystemManager

Implements

Properties

protected

$app Application

The application instance.

Default: null
protected

$disks array

The array of resolved filesystem drivers.

Default: []
protected

$customCreators array

The registered custom driver creators.

Default: []

Methods

public

__construct ( $app ) : void

Create a new filesystem manager instance.

Parameters

public

drive ( $name ) : Filesystem

Get a filesystem instance.

Parameters

  • $name string|null
public

disk ( $name ) : Filesystem

Get a filesystem instance.

Parameters

  • $name string|null
public

cloud ( ) : Cloud

Get a default cloud filesystem instance.

public

build ( $config ) : Filesystem

Build an on-demand disk.

Parameters

  • $config string|array
protected

get ( $name ) : Filesystem

Attempt to get the disk from the local cache.

Parameters

  • $name string
protected

resolve ( $name , $config ) : Filesystem

Resolve the given disk.

Parameters

  • $name string
  • $config array|null
protected

callCustomCreator ( array $config ) : Filesystem

Call a custom driver creator.

Parameters

  • $config array
public

createLocalDriver ( array $config ) : Filesystem

Create an instance of the local driver.

Parameters

  • $config array
public

createFtpDriver ( array $config ) : Filesystem

Create an instance of the ftp driver.

Parameters

  • $config array
public

createSftpDriver ( array $config ) : Filesystem

Create an instance of the sftp driver.

Parameters

  • $config array
public

createS3Driver ( array $config ) : Cloud

Create an instance of the Amazon S3 driver.

Parameters

  • $config array
protected

formatS3Config ( array $config ) : array

Format the given S3 configuration with the default options.

Parameters

  • $config array
public

createScopedDriver ( array $config ) : Filesystem

Create a scoped driver.

Parameters

  • $config array
protected

createFlysystem ( League\...\FilesystemAdapter $adapter , array $config ) : League\...\FilesystemOperator

Create a Flysystem instance with the given adapter.

Parameters

  • $adapter League\...\FilesystemAdapter
  • $config array
public

set ( $name , $disk ) : $this

Set the given disk instance.

Parameters

  • $name string
  • $disk mixed
protected

getConfig ( $name ) : array

Get the filesystem connection configuration.

Parameters

  • $name string
public

getDefaultDriver ( ) : string

Get the default driver name.

public

getDefaultCloudDriver ( ) : string

Get the default cloud driver name.

public

forgetDisk ( $disk ) : $this

Unset the given disk instances.

Parameters

  • $disk array|string
public

purge ( $name ) : void

Disconnect the given disk and remove from local cache.

Parameters

  • $name string|null
public

extend ( $driver , Closure $callback ) : $this

Register a custom driver creator Closure.

Parameters

public

setApplication ( $app ) : $this

Set the application instance used by the manager.

Parameters

public

__call ( $method , $parameters ) : mixed

Dynamically call the default driver instance.

Parameters

  • $method string
  • $parameters array