MediaWiki  REL1_22
PNGHandler Class Reference

Handler for PNG images. More...

Inheritance diagram for PNGHandler:
Collaboration diagram for PNGHandler:

List of all members.

Public Member Functions

 canAnimateThumbnail ($image)
 We do not support making APNG thumbnails, so always false.
 formatMetadata ($image)
 getLongDesc ($image)
 getMetadata ($image, $filename)
 getMetadataType ($image)
 Get a string describing the type of metadata, for display purposes.
 isAnimatedImage ($image)
 isMetadataValid ($image, $metadata)
 Check if the metadata string is valid for this handler.

Public Attributes

const BROKEN_FILE = '0'

Detailed Description

Handler for PNG images.

Definition at line 29 of file PNG.php.


Member Function Documentation

We do not support making APNG thumbnails, so always false.

Parameters:
$imageFile
Returns:
bool false

Reimplemented from MediaHandler.

Definition at line 90 of file PNG.php.

Parameters:
$imageFile
Returns:
array|bool

Reimplemented from MediaHandler.

Definition at line 54 of file PNG.php.

References MediaHandler\formatMetadataHelper().

Parameters:
$imageFile
Returns:
string

Reimplemented from ImageHandler.

Definition at line 126 of file PNG.php.

References $wgLang, array(), global, wfMessage(), wfRestoreWarnings(), and wfSuppressWarnings().

PNGHandler::getMetadata ( image,
filename 
)
Parameters:
File$image
string$filename
Returns:
string

Reimplemented from MediaHandler.

Definition at line 38 of file PNG.php.

References BROKEN_FILE, BitmapMetadataHandler\PNG(), and wfDebug().

Get a string describing the type of metadata, for display purposes.

Returns:
string

Reimplemented from MediaHandler.

Definition at line 94 of file PNG.php.

Parameters:
$imageFile
Returns:
bool

Reimplemented from MediaHandler.

Definition at line 75 of file PNG.php.

PNGHandler::isMetadataValid ( image,
metadata 
)

Check if the metadata string is valid for this handler.

If it returns MediaHandler::METADATA_BAD (or false), Image will reload the metadata from the file and update the database. MediaHandler::METADATA_GOOD for if the metadata is a-ok, MediaHanlder::METADATA_COMPATIBLE if metadata is old but backwards compatible (which may or may not trigger a metadata reload).

Returns:
bool

Reimplemented from MediaHandler.

Definition at line 98 of file PNG.php.

References MediaHandler\METADATA_BAD, MediaHandler\METADATA_COMPATIBLE, MediaHandler\METADATA_GOOD, PNGMetadataExtractor\VERSION, wfDebug(), wfRestoreWarnings(), and wfSuppressWarnings().


Member Data Documentation

Definition at line 31 of file PNG.php.

Referenced by getMetadata(), and PNGHandlerTest\testInvalidFile().


The documentation for this class was generated from the following file: