‪TYPO3CMS  ‪main
TYPO3\CMS\Install\FolderStructure\AbstractNode Class Reference
Inheritance diagram for TYPO3\CMS\Install\FolderStructure\AbstractNode:
TYPO3\CMS\Install\FolderStructure\DirectoryNode TYPO3\CMS\Install\FolderStructure\FileNode TYPO3\CMS\Install\FolderStructure\LinkNode TYPO3\CMS\Install\FolderStructure\RootNode

Public Member Functions

string getName ()
 
string getAbsolutePath ()
 
bool isWritable ()
 

Protected Member Functions

string getTargetPermission ()
 
 setTargetPermission ($permission)
 
array getChildren ()
 
NodeInterface null getParent ()
 
bool exists ()
 
 fixPermission ()
 
bool isPermissionCorrect ()
 
string getCurrentPermission ()
 
bool isWindowsOs ()
 
string getRelativePathBelowSiteRoot ($path=null)
 

Protected Attributes

string $name = ''
 
string null $targetPermission
 
NodeInterface null $parent
 
array $children = array( )
 

Detailed Description

Abstract node implements common methods

This class is only meant to be used within EXT:install and is not part of the TYPO3 Core API.

Definition at line 27 of file AbstractNode.php.

Member Function Documentation

◆ exists()

◆ fixPermission()

◆ getAbsolutePath()

string TYPO3\CMS\Install\FolderStructure\AbstractNode::getAbsolutePath ( )

◆ getChildren()

array TYPO3\CMS\Install\FolderStructure\AbstractNode::getChildren ( )
protected

Get children

Returns
‪array

Definition at line 85 of file AbstractNode.php.

References TYPO3\CMS\Install\FolderStructure\AbstractNode\$children.

◆ getCurrentPermission()

string TYPO3\CMS\Install\FolderStructure\AbstractNode::getCurrentPermission ( )
protected

◆ getName()

string TYPO3\CMS\Install\FolderStructure\AbstractNode::getName ( )

Get name

Returns
‪string Name

Definition at line 50 of file AbstractNode.php.

References TYPO3\CMS\Install\FolderStructure\AbstractNode\$name.

◆ getParent()

NodeInterface null TYPO3\CMS\Install\FolderStructure\AbstractNode::getParent ( )
protected

◆ getRelativePathBelowSiteRoot()

◆ getTargetPermission()

string TYPO3\CMS\Install\FolderStructure\AbstractNode::getTargetPermission ( )
protected

Get target permission

Make sure to call octdec on the value when passing this to chmod

Returns
‪string Permissions as a 4 character octal string, i.e. 2775 or 0644

Definition at line 62 of file AbstractNode.php.

Referenced by TYPO3\CMS\Install\FolderStructure\AbstractNode\fixPermission(), TYPO3\CMS\Install\FolderStructure\DirectoryNode\getSelfStatus(), TYPO3\CMS\Install\FolderStructure\FileNode\getSelfStatus(), and TYPO3\CMS\Install\FolderStructure\AbstractNode\isPermissionCorrect().

◆ isPermissionCorrect()

◆ isWindowsOs()

bool TYPO3\CMS\Install\FolderStructure\AbstractNode::isWindowsOs ( )
protected

◆ isWritable()

bool TYPO3\CMS\Install\FolderStructure\AbstractNode::isWritable ( )

Current node is writable if parent is writable

Returns
‪bool TRUE if parent is writable

Reimplemented in TYPO3\CMS\Install\FolderStructure\DirectoryNode.

Definition at line 115 of file AbstractNode.php.

References TYPO3\CMS\Install\FolderStructure\AbstractNode\getParent(), and TYPO3\CMS\Install\FolderStructure\NodeInterface\isWritable().

Referenced by TYPO3\CMS\Install\FolderStructure\FileNode\getSelfStatus().

◆ setTargetPermission()

TYPO3\CMS\Install\FolderStructure\AbstractNode::setTargetPermission (   $permission)
protected

Set target permission

Parameters
string$permission‪Permissions as a 4 character octal string, i.e. 2775 or 0644

Definition at line 72 of file AbstractNode.php.

Referenced by TYPO3\CMS\Install\FolderStructure\RootNode\__construct(), TYPO3\CMS\Install\FolderStructure\DirectoryNode\__construct(), and TYPO3\CMS\Install\FolderStructure\FileNode\__construct().

Member Data Documentation

◆ $children

array TYPO3\CMS\Install\FolderStructure\AbstractNode::$children = array( )
protected

Directories and root may have children, files and link always empty array

Definition at line 43 of file AbstractNode.php.

Referenced by TYPO3\CMS\Install\FolderStructure\AbstractNode\getChildren().

◆ $name

◆ $parent

◆ $targetPermission

string null TYPO3\CMS\Install\FolderStructure\AbstractNode::$targetPermission
protected

Target permissions for unix, eg. '2775' or '0664' (4 characters string)

Definition at line 35 of file AbstractNode.php.