FileFetcher

Fetch files for the ExtensionInstaller to install.

Fetching files can happen in different ways:

  • Upload ZIP
  • wget ZIP from a URL
  • Enter git repo
  • Etc. Each method is its own subclass of this class. Each extension type can support a number of different file fetch methods.
since 2018-09-24
author

Olle Haerstedt

package

Default

Methods

Abort procedure, remove temporary files.

abort(): void
abstract

Move files from source to tmp/ folder.

fetch(): void
abstract

getConfig

getConfig(): \LimeSurvey\ExtensionInstaller\ExtensionConfig
abstract
Throws
\LimeSurvey\ExtensionInstaller\Exception

if config cannot be parsed.

Response

\LimeSurvey\ExtensionInstaller\ExtensionConfig

Move files from tmp/ folder to final destination.

move(string $destdir): boolean
abstract

Arguments

$destdir

string

Response

boolean

Set source for this file fetcher.

setSource(string $source): void
abstract

Can be ZIP file name, git repo URL, folder name, etc.

Arguments

$source

string