Handbuch:File.php
Appearance
Diese Seite ist veraltet. |
| MediaWiki-Datei: File.php | |
|---|---|
| Speicherort: | includes/filerepo/file/ (includes/FileRepo/File/ in 1.46 or later) |
| Quellcode: | master • 1.45.3 • 1.44.5 • 1.43.8 |
| Klassen: | MediaWiki\FileRepo\File\File |
File.php contains a class, File, to represent files in a repository.
Usage notes:
- A number of public functions, especially many of the 'stubs' (i.e. unimplemented public methods), are meant to be overridden.
- The name of a file class is known only to the Repo object. To get File objects or generate new ones, use the Repo factory functions. It is usually sufficient to use something like:
- MediaWikiServices::getInstance()->getRepoGroup()->findFile()
- MediaWikiServices::getInstance()->getRepoGroup()->getLocalRepo()->newFile()
Siehe auch
- Handbuch:LocalFile.php - Extends the File class to represent a local file in the database.
- Manual:RepoGroup.php - Creates prioritized list of file repositories.