Horde_Mime_Viewer
in package
The Horde_Mime_Viewer:: class provides an abstracted interface to render MIME data into various formats. It depends on both a set of Horde_Mime_Viewer_* drivers which handle the actual rendering, and a configuration file to map MIME types to drivers.
Copyright 1999-2017 Horde LLC (http://www.horde.org/)
See the enclosed file LICENSE for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
Tags
Table of Contents
- factory() : Horde_Mime_Viewer_Base
- Attempts to return a concrete Horde_Mime_Viewer_Base instance based on $driver.
Methods
factory()
Attempts to return a concrete Horde_Mime_Viewer_Base instance based on $driver.
public
static factory(string $driver, Horde_Mime_Part $part[, array<string|int, mixed> $params = array() ]) : Horde_Mime_Viewer_Base
Parameters
- $driver : string
-
Either a driver name, or the full class name to use (class must extend Horde_Mime_Viewer_Base).
- $part : Horde_Mime_Part
-
The MIME part object to display.
- $params : array<string|int, mixed> = array()
-
A hash containing any additional configuration or parameters a subclass might need.
Tags
Return values
Horde_Mime_Viewer_Base —The newly created concrete instance.