lib/ezutils/classes/ezsys.php

Show: inherited
Table of Contents

\eZSys

Package:

Properties

Propertyprotectedarray  $AccessPath= ''

The access path of the current site view, associated array of associated arrays.

On first level key is 'siteaccess' and 'path' to distinguish between siteaccess and general path. On second level you have (string)'name' and (array)'url', where url is the path and name is the name of the source (used to match siteaccess in {@link eZSys::indexFile()} for RemoveSiteAccessIfDefaultAccess matching) .

Details
Type
array
Propertypublicstring  $EnvSeparator= ''

The list separator used for env variables (':' or ';')

Details
Type
string
Propertypublicstring  $FileSeparator= ''

The directory separator used for files, '/' or '\'

Details
Type
string
Propertypublicstring  $FileSystemType= ''

The type of filesystem, is either win32 or unix. This often used to determine OS specific paths.

Details
Type
string
Propertypublicstring  $IndexFile= ''

The indef file name (eg: 'index.php')

Details
Type
string
Propertypublicstring  $LineSeparator= ''

The line separator used in files, "\n" / "\n\r" / "\r"

Details
Type
string
Propertypublicstring  $OSType= ''

The type of OS, is either win32, mac or unix.

Details
Type
string
Propertyprotectedarray  $Params= 'null'

Holds server variables as read automatically or provided by unit tests Only used by init functionality as other calls will need to use live data direclty from globals.

Default valuenullDetails
Type
array
Propertypublicstring  $RequestURI= ''

The uri which is used for parsing module/view information from, may differ from $_SERVER['REQUEST_URI']

Details
Type
string
Propertypublicstring  $RootDir= ''

The absolute path to the root directory.

Details
Type
string
Propertypublic\stringt  $ShellEscapeCharacter= ''

The character to be used in shell escaping, this character is OS specific

Details
Type
\stringt
Propertypublicstring  $SiteDir= ''

The system path to where all the code resides

Details
Type
string
Propertypublicstring  $WWWDir= ''

The relative directory path of the vhless setup

Details
Type
string
Propertyprotectednull|\eZSys  $instance= 'null'
static

Holds eZSys instance

Default valuenullDetails
Type
null | \eZSys

Methods

methodpublic__construct( array | null $serverParams = null ) : void

Initializes the object with settings taken from the current script run.

Parameters
Name Type Description
$serverParams array | null

For unit testing use, see first few lines for content

methodpublic__get(  $propertyName ) : mixed

Magic function to get access readonly properties (protected)

Parameters
Name Type Description
$propertyName
Returns
Type Description
mixed
Throws
Exception Description
\ezcBasePropertyNotFoundException
methodpublicaddAccessPath( array | string $path, string $name = 'undefined', bool $siteaccess = true ) : void
static

Appends the access path (parts of url that identifies siteaccess), used by {@link eZSys::indexFile()} NOTE: Does not make sense to use for siteaccess, as you would want to clear current path and set new one normally, so preferably use {@link eZSys::setAccessPath()} in this case.

Parameters
Name Type Description
$path array | string
$name string

An identifer of the name of the path provided {@link $AccessPath}

$siteaccess bool

Hints if path is siteaccess related or not, needed in case subsequesnt code suddenly changes siteaccess and needs to clear siteaccess scope

methodpublicattribute(  $attr ) : void

Parameters
Name Type Description
$attr
methodpublicattributes( ) : void

methodpublicbackupFilename( ) : void
static

methodpubliccacheDirectory( ) : void
static

methodpublicclearAccessPath(  $siteaccess = true ) : void
static

Clears the access path, used by {@link eZSys::indexFile()}

Parameters
Name Type Description
$siteaccess
methodpubliccreateShellArgument(  $argumentText,  $replaceList ) : void
static

Parameters
Name Type Description
$argumentText
$replaceList
methodpublicenvSeparator( ) : void
static

methodpublicenvironmentVariable(  $variableName,  $quiet = false ) : void
static

Return the variable named \a $variableName in the global \c ENV variable.

If the variable is not present an error is shown and \c null is returned.

Parameters
Name Type Description
$variableName
$quiet
methodpublicescapeShellArgument(  $argument ) : void
static

Parameters
Name Type Description
$argument
methodpublicezcrc32(  $string ) : void
static

Parameters
Name Type Description
$string
methodpublicfileSeparator( ) : void
static

methodpublicfilesystemType( ) : void
static

methodprotectedgetValidwwwDir( string $phpSelf, string $scriptFileName, string $index ) : string | null | false
static

Generate wwwdir from phpSelf if valid accoring to scriptFileName and return null if invalid and false if there is no index in phpSelf

Parameters
Name Type Description
$phpSelf string
$scriptFileName string
$index string
Returns
Type Description
string | null | false String in form 'path/path2' if valid, null if not and false if $index is not part of phpself
methodpublicglobBrace(  $pattern,  $flags = 0 ) : void
static

Parameters
Name Type Description
$pattern
$flags
methodpublichasAttribute(  $attr ) : void

Parameters
Name Type Description
$attr
methodpublichasEnvironmentVariable(  $variableName ) : void
static

Parameters
Name Type Description
$variableName
methodpublichostname( ) : void
static

methodpublicindexDir(  $withAccessList = true ) : void
static

Parameters
Name Type Description
$withAccessList
methodpublicindexFile(  $withAccessPath = true ) : void
static

Parameters
Name Type Description
$withAccessPath
methodpublicindexFileName( ) : void
static

methodpublicinit( string $index = 'index.php', bool $forceVirtualHost = null ) : void
static

Initializes some variables according to some global PHP values.

This function should be called once in the index file with the parameters stated in the parameter list.

Parameters
Name Type Description
$index string

The current index file, needed for virtual host mode detection.

$forceVirtualHost bool

Virtual host mode is normally autodetected, but if not this can be forced by setting this to true.

methodpublicinstance( ) : \eZSys
static

Returns a shared instance of the eZSys class

Returns
Type Description
\eZSys
methodpublicisDebugEnabled( ) : bool
static

Return true if debugging of internals is enabled, this will display which server variables are read.

Set the option with setIsDebugEnabled().

Returns
Type Description
bool
Details
Deprecated
Since 4.5, not used  
methodpublicisPHPVersionSufficient( array $requiredVersion ) : bool
static

Return \c true if the PHP version is equal or higher than \a $requiredVersion.

Use: eZSys::isPHPVersionSufficient( array( 4, 1, 0 ) );

Parameters
Name Type Description
$requiredVersion array

Must be an array with version number

Returns
Type Description
bool
Details
Deprecated
Since 4.5  
methodpublicisSSLNow( ) : void
static

methodpublicisShellExecution( ) : void
static

methodpubliclineSeparator( ) : void
static

methodpublicmagickQuotes( ) : void
static

Returns true if magick quotes is enabled, but does nothing.

Details
Deprecated
since 4.5  
methodpublicmergeArgumentElements(  $argumentElements ) : void
static

Parameters
Name Type Description
$argumentElements
methodpublicosName( ) : void
static

methodpublicosType( ) : void
static

methodpublicpath(  $quiet = false ) : void
static

Parameters
Name Type Description
$quiet
methodpublicphpVersion( ) : array
static

Return the PHP version as an array with the version elements.

Returns
Type Description
array
Details
Deprecated
Since 4.5  
methodpublicphpVersionText( ) : string
static

The PHP version as text.

Returns
Type Description
string
Details
Deprecated
Since 4.5, use PHP_VERSION  
methodpublicprotocolSchema( ) : void
static

methodpublicremoveMagicQuotes( ) : void
static

Removes magic quotes

Details
Deprecated
Since 4.5, magic quotes setting has been deprecated in PHP 5.3  
methodpublicrequestURI( ) : void
static

methodpublicrootDir( ) : void
static

methodpublicserverPort( ) : void
static

methodpublicserverProtocol( ) : void
static

methodpublicserverURL( ) : void
static

methodpublicserverVariable(  $variableName,  $quiet = false ) : void
static

Parameters
Name Type Description
$variableName
$quiet
methodpublicsetAccessPath( array $path = array(), string $name = 'undefined', bool $siteaccess = true ) : void
static

Set access path (parts of url that identifies siteaccess), used by {@link eZSys::indexFile()}

Parameters
Name Type Description
$path array
$name string

An identifer of the name of the path provided {@link $AccessPath}

$siteaccess bool

Hints if path is siteaccess related or not, needed in case subsequesnt code suddenly changes siteaccess and needs to clear siteaccess scope

methodpublicsetEnvironmentVariable(  $variableName,  $variableValue ) : void
static

Parameters
Name Type Description
$variableName
$variableValue
methodpublicsetInstance( \eZSys $instance = null ) : void
static

Sets eZSys instance or clears it if left undefined.

Parameters
Name Type Description
$instance \eZSys
methodpublicsetIsDebugEnabled( bool $debug ) : void
static

Sets whether internal debugging is enabled or not.

Parameters
Name Type Description
$debug bool
Details
Deprecated
Since 4.5, has not effect anymore  
methodpublicsetServerVariable(  $variableName,  $variableValue ) : void
static

Parameters
Name Type Description
$variableName
$variableValue
methodprotectedsimulateGlobBrace(  $filenames ) : void
static

Parameters
Name Type Description
$filenames
methodpublicsiteDir( ) : void
static

methodpublicsplitArgumentIntoElements(  $argumentText ) : void
static

Parameters
Name Type Description
$argumentText
methodpublicstorageDirectory( ) : void
static

methodpublicvarDirectory( ) : void
static

methodpublicwwwDir( ) : void
static

Documentation was generated by DocBlox 0.18.1.