ForeignDBFile.php extends LocalFile
Image.php extends LocalFile
UnregisteredLocalFile.php extends File.
-FileRepo.php defined an abstract class FileRepo.
+FileRepo.php defines an abstract class FileRepo.
ForeignAPIRepo.php extends FileRepo
FSRepo extends FileRepo
LocalRepo.php extends FSRepo
NullRepo extends FileRepo
Russ Nelson, March 2011
+
$this->dims = array();
}
- function getPageDimensions( $page = 1 ) {
+ private function cachePageDimensions( $page = 1 ) {
if ( !isset( $this->dims[$page] ) ) {
if ( !$this->getHandler() ) {
return false;
}
function getWidth( $page = 1 ) {
- $dim = $this->getPageDimensions( $page );
+ $dim = $this->cachePageDimensions( $page );
return $dim['width'];
}
function getHeight( $page = 1 ) {
- $dim = $this->getPageDimensions( $page );
+ $dim = $this->cachePageDimensions( $page );
return $dim['height'];
}
function getMimeType() {
if ( !isset( $this->mime ) ) {
$magic = MimeMagic::singleton();
- $this->mime = $magic->guessMimeType( $this->path );
+ $this->mime = $magic->guessMimeType( $this->getPath() );
}
return $this->mime;
}