PHP 클래스 Webiny\Component\Storage\Driver\Local\LocalHelper

상속: use trait Webiny\Component\StdLib\SingletonTrait
파일 보기 프로젝트 열기: Webiny/Framework 1 사용 예제들

공개 메소드들

메소드 설명
buildPath ( $key, $directory, $create ) : mixed Build absolute path by given $key and $directory
ensureDirectoryExists ( string $directory, boolean $create = false ) Make sure the target directory exists
getKey ( string $path, string $directory ) : string Gets the key using file $path and storage $directory
normalizeDirectoryPath ( $path ) : string Normalize path (strip '.', '.

보호된 메소드들

메소드 설명
createDirectory ( string $directory ) Create directory
getAbsolutePrefix ( string $path ) : string Returns the absolute prefix of the given path
normalizePath ( string $path ) : string Normalizes the given path

메소드 상세

buildPath() 공개 메소드

Build absolute path by given $key and $directory
public buildPath ( $key, $directory, $create ) : mixed
$key
$directory
$create
리턴 mixed

createDirectory() 보호된 메소드

Create directory
protected createDirectory ( string $directory )
$directory string Directory path to create

ensureDirectoryExists() 공개 메소드

Make sure the target directory exists
public ensureDirectoryExists ( string $directory, boolean $create = false )
$directory string Path to check
$create boolean (Optional) Create path if doesn't exist

getAbsolutePrefix() 보호된 메소드

Returns the absolute prefix of the given path
protected getAbsolutePrefix ( string $path ) : string
$path string A normalized path
리턴 string

getKey() 공개 메소드

Gets the key using file $path and storage $directory
public getKey ( string $path, string $directory ) : string
$path string Path to extract file key from
$directory string Directory of the storage
리턴 string

normalizeDirectoryPath() 공개 메소드

.' and make sure it's not a symlink)
public normalizeDirectoryPath ( $path ) : string
$path
리턴 string

normalizePath() 보호된 메소드

Normalizes the given path
protected normalizePath ( string $path ) : string
$path string
리턴 string