PHP Class Horde_Pack, horde

Author: Michael Slusarz ([email protected])
Afficher le fichier Open project: horde/horde Class Usage Examples

Protected Properties

Свойство Type Description
$_compress Horde_Compress_Fast Instance of Horde_Compress_Fast shared between all instances.
$_drivers array Drivers. Shared between all instances.

Méthodes publiques

Méthode Description
__construct ( ) Constructor.
__sleep ( )
pack ( mixed $data, array $opts = [] ) : string Pack a string.
unpack ( string $data ) : mixed Unpack a string.

Method Details

__construct() public méthode

Constructor.
public __construct ( )

__sleep() public méthode

public __sleep ( )

pack() public méthode

Pack a string.
public pack ( mixed $data, array $opts = [] ) : string
$data mixed The data to pack.
$opts array Additional options:
  - compress: (mixed) If false, don't use compression. If true, uses
              default compress length (DEFAULT). If 0, always compress.
              All other integer values: compress only if data is
              greater than this string length.
  - drivers: (array) Only use these drivers to pack. By default, driver
             to use is auto-determined.
  - phpob: (boolean) If true, the data contains PHP serializable
           objects (i.e. objects that have a PHP-specific serialized
           representation). If false, the data does not contain any of
           these objects. If not present, will auto-determine
           existence of these objects.
Résultat string The packed string.

unpack() public méthode

Unpack a string.
public unpack ( string $data ) : mixed
$data string The packed string.
Résultat mixed The unpacked data.

Property Details

$_compress protected_oe static_oe property

Instance of Horde_Compress_Fast shared between all instances.
protected static Horde_Compress_Fast $_compress
Résultat Horde_Compress_Fast

$_drivers protected_oe static_oe property

Drivers. Shared between all instances.
protected static array $_drivers
Résultat array