dmBridge PHP API
DMMediaType Class Reference

Encapsulates an RFC 2046 Internet media type, a.k.a. More...

Public Member Functions

Static Public Member Functions


Detailed Description

Encapsulates an RFC 2046 Internet media type, a.k.a.

MIME type.

Author:
Alex Dolski <alex.dolski@unlv.edu> http://www.opensource.org/licenses/mit-license.php

Definition at line 15 of file DMMediaType.php.


Constructor & Destructor Documentation

DMMediaType::__construct ( type,
subtype 
)
Parameters:
stringtype
stringsubtype

Definition at line 88 of file DMMediaType.php.


Member Function Documentation

DMMediaType::__toString ( )
Returns:
string String representation of the media type.

Definition at line 96 of file DMMediaType.php.

DMMediaType::equals ( object)
Parameters:
objectobject
Returns:
boolean

Definition at line 104 of file DMMediaType.php.

static DMMediaType::getKnownExtensions ( ) [static]
Returns:
array

Definition at line 32 of file DMMediaType.php.

DMMediaType::getName ( )
Returns:
string

Definition at line 115 of file DMMediaType.php.

DMMediaType::getSubtype ( )
Returns:
string

Definition at line 144 of file DMMediaType.php.

Referenced by __toString(), equals(), and getName().

DMMediaType::getType ( )
Returns:
string

Definition at line 158 of file DMMediaType.php.

Referenced by __toString(), equals(), and getName().

static DMMediaType::getTypeForExtension ( ext) [static]
Parameters:
stringext
Returns:
DMMediaType A best guess at the media type for the given extension. If the guess is unsuccessful, returns null.

Definition at line 52 of file DMMediaType.php.

Referenced by DMObject::getMediaType(), and DMFile::getMediaType().

static DMMediaType::getTypeForString ( str) [static]
Parameters:
stringstr
Returns:
DMMediaType

Definition at line 76 of file DMMediaType.php.

Referenced by DMConfigXML::loadCollection(), and DMHTTPClient::send().

DMMediaType::setName ( name)
Parameters:
stringname

Definition at line 137 of file DMMediaType.php.

DMMediaType::setSubtype ( subtype)
Parameters:
stringsubtype

Definition at line 151 of file DMMediaType.php.

Referenced by __construct().

DMMediaType::setType ( type)
Parameters:
stringtype

Definition at line 165 of file DMMediaType.php.

Referenced by __construct().


The documentation for this class was generated from the following file:
 All Data Structures Functions Variables