PHP 클래스 Components_Helper_Root, horde

Copyright 2010-2016 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.
파일 보기 프로젝트 열기: horde/horde 1 사용 예제들

공개 메소드들

메소드 설명
__construct ( array $opts = [], Components_Component $comp = null, string $path = null ) Constructor.
getGitIgnore ( ) : string Return the contents of the gitignore file.
getPackageXml ( string $name ) : string Return the path to the package.xml for the package with the provided name.
getRoot ( ) : string Return the root position of the repository.
traverseHierarchy ( string $start ) : string | boolean Traverse the folder tree upwards to determine if a parent folder of the provided file path might be the Horde repository root.

비공개 메소드들

메소드 설명
_determineRoot ( ) : string Try to determine the root path.
_determineRootFromComponent ( ) : string | boolean Try to determine the root path based on a component.
_determineRootFromCwd ( ) : string | boolean Try to determine the root path based on the current working directory.
_determineRootFromOptions ( ) : string | boolean Try to determine the root path based on the options.
_determineRootFromPath ( ) : string | boolean Try to determine the root path based on a fixed path.
_isValidRoot ( string $directory ) : string | boolean Test if the directory path could be the Horde repository root.

메소드 상세

__construct() 공개 메소드

Constructor.
public __construct ( array $opts = [], Components_Component $comp = null, string $path = null )
$opts array If given the helper will try to determine the root of the Horde repository based on these options.
$comp Components_Component If given the helper will try to determine the root of the Horde repository based on this component.
$path string If given the helper will try to determine the root of the Horde repository based on this path.

getGitIgnore() 공개 메소드

Return the contents of the gitignore file.
public getGitIgnore ( ) : string
리턴 string The information from the gitignore file.

getPackageXml() 공개 메소드

Return the path to the package.xml for the package with the provided name.
public getPackageXml ( string $name ) : string
$name string The name of the package.
리턴 string The path to the package.xml of the requested package.

getRoot() 공개 메소드

Return the root position of the repository.
public getRoot ( ) : string
리턴 string The root path.

traverseHierarchy() 공개 메소드

Traverse the folder tree upwards to determine if a parent folder of the provided file path might be the Horde repository root.
public traverseHierarchy ( string $start ) : string | boolean
$start string Path to the file to start from.
리턴 string | boolean The root path or false if it could not be determined.