Exponential 6.0.13 Exponential Enterprise Open Source CMS - PHP Class Reference

Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
eZGZIPShellCompressionHandler Class Reference

Handles files compressed with gzip using the shell commands. More...

Inheritance diagram for eZGZIPShellCompressionHandler:

## Public Member Functions
| __construct ()
| setCompressionLevel ( $level)
| compressionLevel ()
| gunzipFile ( $filename)
| doOpen ( $filename, $mode)
| doClose ()
| doRead ( $uncompressedLength=false)
| doWrite ( $data, $uncompressedLength=false)
| doFlush ()
| doSeek ( $offset, $whence)
| doRewind ()
| doTell ()
| doEOF ()
| doPasstrough ( $closeFile=true)
| compress ( $source)
| decompress ( $source)
| errorString ()
| errorNumber ()
Public Member Functions inherited from eZFileHandler
| __construct ( $handlerIdentifier=false, $handlerName=false)
| isOpen ()
| isBinaryMode ()
| filename ()
| mode ()
| name ()
| identifier ()
| exists ( $filename=false)
| isDirectory ( $filename=false)
| isExecutable ( $filename=false)
| isFile ( $filename=false)
| isLink ( $filename=false)
| isReadable ( $filename=false)
| isWriteable ( $filename=false)
| statistics ( $filename=false)
| open ( $filename, $mode, $binaryFile=true)
| close ()
| unlink ( $filename=false)
| rename ( $destinationFilename, $sourceFilename=false)
| read ( $length=false)
| write ( $data, $length=false)
| flush ()
| seek ( $offset, $whence=SEEK_SET)
| rewind ()
| tell ()
| eof ()
| passtrough ( $closeFile=true)
| error ()
| duplicate ()

## Static Public Member Functions
static | isAvailable ()
Static Public Member Functions inherited from eZFileHandler
static | linkCopy ( $sourceFilename, $destinationFilename, $symbolicLink=true)
static | symlink ( $sourceFilename, $destinationFilename)
static | link ( $sourceFilename, $destinationFilename)
static | move ( $sourceFilename, $destinationFilename)
static | copy ( $sourceFilename, $destinationFilename)
static | doUnlink ( $filename)
static | doExists ( $filename)
static | doIsDirectory ( $filename)
static | doIsExecutable ( $filename)
static | doIsFile ( $filename)
static | doIsLink ( $filename)
static | doIsReadable ( $filename)
static | doIsWriteable ( $filename)
static | doStatistics ( $filename)
static | doRename ( $destinationFilename, $sourceFilename)
static | instance ( $identifier, $filename=false, $mode=false, $binaryFile=true)

## Public Attributes
| $File
| $Level
| The compression level. More...
Public Attributes inherited from eZFileHandler
| $Identifier
| $FileHandler
| $Name
| $FileName
| $Mode
| $IsBinary
| $IsOpen

## Detailed Description

Handles files compressed with gzip using the shell commands.

Handles GZIP compression by executing the 'gzip' executable, without this the handler cannot work.

NOTE: This is not done yet.

Definition at line 21 of file ezgzipshellcompressionhandler.php.

## Constructor & Destructor Documentation

## ◆ __construct()

eZGZIPShellCompressionHandler::__construct | ( |  | ) |

Definition at line 23 of file ezgzipshellcompressionhandler.php.

## Member Function Documentation

## ◆ compress()

eZGZIPShellCompressionHandler::compress | ( |  | $source | ) |
| virtual

Compress the $source string and return it as compressed data.

Implements eZCompressionHandler.

Definition at line 120 of file ezgzipshellcompressionhandler.php.

## ◆ compressionLevel()

eZGZIPShellCompressionHandler::compressionLevel | ( |  | ) |

Returns
  the current compression level which is a number between 0 and 9, or `false` if the default is to be used.

Definition at line 44 of file ezgzipshellcompressionhandler.php.

References $Level.

## ◆ decompress()

eZGZIPShellCompressionHandler::decompress | ( |  | $source | ) |
| virtual

Decompress the $source string containing compressed data and return it as a string.

Implements eZCompressionHandler.

Definition at line 125 of file ezgzipshellcompressionhandler.php.

## ◆ doClose()

eZGZIPShellCompressionHandler::doClose | ( |  | ) |
| virtual

Does the actual file closing.

See also
  close

Implements eZFileHandler.

Definition at line 67 of file ezgzipshellcompressionhandler.php.

## ◆ doEOF()

eZGZIPShellCompressionHandler::doEOF | ( |  | ) |
| virtual

Does the actual file eof detection.

See also
  eof

Implements eZFileHandler.

Definition at line 110 of file ezgzipshellcompressionhandler.php.

## ◆ doFlush()

eZGZIPShellCompressionHandler::doFlush | ( |  | ) |
| virtual

Does the actual file flushing.

See also
  flush

Implements eZFileHandler.

Definition at line 82 of file ezgzipshellcompressionhandler.php.

## ◆ doOpen()

eZGZIPShellCompressionHandler::doOpen | ( |  | $filename,
|  |  | $mode
| ) |  |
| virtual

Does the actual file opening.

See also
  open

Implements eZFileHandler.

Definition at line 62 of file ezgzipshellcompressionhandler.php.

## ◆ doPasstrough()

eZGZIPShellCompressionHandler::doPasstrough | ( |  | $closeFile = `true` | ) |
| virtual

Does the actual file passtrough.

See also
  eof

Implements eZFileHandler.

Definition at line 115 of file ezgzipshellcompressionhandler.php.

## ◆ doRead()

eZGZIPShellCompressionHandler::doRead | ( |  | $length = `false` | ) |
| virtual

Does the actual file reading.

See also
  read

Implements eZFileHandler.

Definition at line 72 of file ezgzipshellcompressionhandler.php.

## ◆ doRewind()

eZGZIPShellCompressionHandler::doRewind | ( |  | ) |

Does the actual file rewind.

See also
  rewind

Note
  Default implementation calls seek with offset set to 0 from the file start.

Reimplemented from eZFileHandler.

Definition at line 100 of file ezgzipshellcompressionhandler.php.

## ◆ doSeek()

eZGZIPShellCompressionHandler::doSeek | ( |  | $offset,
|  |  | $whence
| ) |  |
| virtual

Does the actual file seek.

See also
  seek

Implements eZFileHandler.

Definition at line 87 of file ezgzipshellcompressionhandler.php.

References eZDebugSetting\writeError().

## ◆ doTell()

eZGZIPShellCompressionHandler::doTell | ( |  | ) |
| virtual

Does the actual file telling.

See also
  tell

Implements eZFileHandler.

Definition at line 105 of file ezgzipshellcompressionhandler.php.

## ◆ doWrite()

eZGZIPShellCompressionHandler::doWrite | ( |  | $data,
|  |  | $length = `false`
| ) |  |
| virtual

Does the actual file writing.

See also
  write

Implements eZFileHandler.

Definition at line 77 of file ezgzipshellcompressionhandler.php.

## ◆ errorNumber()

eZGZIPShellCompressionHandler::errorNumber | ( |  | ) |
| virtual

Returns
  the error number from the last error that occured.

Implements eZFileHandler.

Definition at line 135 of file ezgzipshellcompressionhandler.php.

## ◆ errorString()

eZGZIPShellCompressionHandler::errorString | ( |  | ) |
| virtual

Returns
  the error string from the last error that occured.

Implements eZFileHandler.

Definition at line 130 of file ezgzipshellcompressionhandler.php.

## ◆ gunzipFile()

eZGZIPShellCompressionHandler::gunzipFile | ( |  | $filename | ) |

Definition at line 57 of file ezgzipshellcompressionhandler.php.

## ◆ isAvailable()

static eZGZIPShellCompressionHandler::isAvailable | ( |  | ) |
| static

Returns
  true if this handler can be used.

Reimplemented from eZFileHandler.

Definition at line 52 of file ezgzipshellcompressionhandler.php.

Referenced by eZGZIPCompressionHandler\__construct().

## ◆ setCompressionLevel()

eZGZIPShellCompressionHandler::setCompressionLevel | ( |  | $level | ) |

Sets the current compression level.

Definition at line 33 of file ezgzipshellcompressionhandler.php.

## Member Data Documentation

## ◆ $File

eZGZIPShellCompressionHandler::$File

File pointer, returned by gzopen

Definition at line 142 of file ezgzipshellcompressionhandler.php.

## ◆ $Level

eZGZIPShellCompressionHandler::$Level

The compression level.

Definition at line 144 of file ezgzipshellcompressionhandler.php.

Referenced by compressionLevel().

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

- ezgzipshellcompressionhandler.php

Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.