You are here

class FakeFile in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/http-foundation/Tests/File/FakeFile.php \Symfony\Component\HttpFoundation\Tests\File\FakeFile

Hierarchy

  • class \Symfony\Component\HttpFoundation\File\File extends \Symfony\Component\HttpFoundation\File\SplFileInfo
    • class \Symfony\Component\HttpFoundation\Tests\File\FakeFile

Expanded class hierarchy of FakeFile

1 file declares its use of FakeFile
BinaryFileResponseTest.php in vendor/symfony/http-foundation/Tests/BinaryFileResponseTest.php

File

vendor/symfony/http-foundation/Tests/File/FakeFile.php, line 16

Namespace

Symfony\Component\HttpFoundation\Tests\File
View source
class FakeFile extends OrigFile {
  private $realpath;
  public function __construct($realpath, $path) {
    $this->realpath = $realpath;
    parent::__construct($path, false);
  }
  public function isReadable() {
    return true;
  }
  public function getRealpath() {
    return $this->realpath;
  }
  public function getSize() {
    return 42;
  }
  public function getMTime() {
    return time();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
FakeFile::$realpath private property
FakeFile::getMTime public function
FakeFile::getRealpath public function
FakeFile::getSize public function
FakeFile::isReadable public function
FakeFile::__construct public function Constructs a new file from the given path. Overrides File::__construct
File::getMimeType public function Returns the mime type of the file.
File::getName protected function Returns locale independent base name of the given path.
File::getTargetFile protected function
File::guessExtension public function Returns the extension based on the mime type.
File::move public function Moves the file to a new location. 1