/usr/share/php/Horde/Compress.php is in php-horde-compress 2.2.1-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 | <?php
/**
* Copyright 2003-2017 Horde LLC (http://www.horde.org/)
*
* See the enclosed file COPYING for license information (LGPL). If you
* did not receive this file, see http://www.horde.org/licenses/lgpl21.
*
* @author Michael Slusarz <slusarz@horde.org>
* @category Horde
* @license http://www.horde.org/licenses/lgpl21 LGPL 2.1
* @package Compress
*/
/**
* This class provides an API for various compression techniques that can be
* used by Horde applications.
*
* @author Michael Slusarz <slusarz@horde.org>
* @category Horde
* @copyright 2003-2017 Horde LLC
* @license http://www.horde.org/licenses/lgpl21 LGPL 2.1
* @package Compress
*/
class Horde_Compress
{
/**
* Attempts to return a concrete Horde_Compress_Base instance based on
* $driver.
*
* @param string $driver Either a driver name, or the full class name to
* use (class must extend Horde_Compress_Base).
* @param array $params Hash containing any additional configuration
* or parameters a subclass needs.
*
* @return Horde_Compress_Base The newly created concrete instance.
* @throws Horde_Compress_Exception
*/
public static function factory($driver, $params = null)
{
/* Base drivers (in Compress/ directory). */
$class = __CLASS__ . '_' . Horde_String::ucfirst($driver);
if (@class_exists($class)) {
return new $class($params);
}
/* Explicit class name. */
if (@class_exists($driver)) {
return new $driver($params);
}
throw new Horde_Compress_Exception(__CLASS__ . ': Class definition of ' . $driver . ' not found.');
}
}
|