PHP 클래스 Gregwar\RST\Builder

파일 보기 프로젝트 열기: gregwar/rst 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$beforeHooks Hooks before the parsing on the environment
$directory Source and target directory
$documents Parsed documents waiting to be rendered
$errorManager Error manager
$hooks Hooks after the parsing
$indexName Tree index name
$kernel Kernel
$metas Metas for documents
$parseQueue Queue of documents to be parsed
$states States (decision) of the scanned documents
$targetDirectory
$toCopy Files to copy at the end of the build
$toMkdir
$verbose Verbose build ?

공개 메소드들

메소드 설명
__construct ( $kernel = null )
addBeforeHook ( $function ) Adds an hook which will be called on each environment during building
addHook ( $function ) Adds an hook which will be called on each document after parsing
build ( $directory, $targetDirectory = 'output', $verbose = true )
copy ( $source, $destination = null ) Add a file to copy
doCopy ( ) Run the copy
doMkdir ( ) Run the directories creation
getErrorManager ( )
getIndexName ( )
getRST ( $file ) Gets the .rst of a source file
getSourceFile ( $filename ) Gets the name of a source file
getTargetFile ( $filename ) Gets the name of a target file
getTargetOf ( $file ) Gets the name of a target for a file, for instance /introduction/part1 could be resolved into /path/to/introduction/part1.html
getUrl ( $document ) Gets the URL of a target file
mkdir ( $directory ) Creates a directory in the target
scan ( $file ) Scans a file, this will check the status of the file and tell if it needs to be parsed or not
scanMetas ( ) Scans all the metas
setIndexName ( $name )

보호된 메소드들

메소드 설명
addToParseQueue ( $file ) Adding a file to the parse queue
display ( $text )
getFileToParse ( ) Returns the next file to parse
getMetaFile ( ) Get the meta file name
loadMetas ( ) Try to inport the metas from the meta files
parseAll ( ) Parses all the document that need to be parsed
render ( ) Renders all the pending documents
saveMetas ( ) Saving the meta files

메소드 상세

__construct() 공개 메소드

public __construct ( $kernel = null )

addBeforeHook() 공개 메소드

Adds an hook which will be called on each environment during building
public addBeforeHook ( $function )

addHook() 공개 메소드

Adds an hook which will be called on each document after parsing
public addHook ( $function )

addToParseQueue() 보호된 메소드

Adding a file to the parse queue
protected addToParseQueue ( $file )

build() 공개 메소드

public build ( $directory, $targetDirectory = 'output', $verbose = true )

copy() 공개 메소드

Add a file to copy
public copy ( $source, $destination = null )

display() 보호된 메소드

protected display ( $text )

doCopy() 공개 메소드

Run the copy
public doCopy ( )

doMkdir() 공개 메소드

Run the directories creation
public doMkdir ( )

getErrorManager() 공개 메소드

public getErrorManager ( )

getFileToParse() 보호된 메소드

Returns the next file to parse
protected getFileToParse ( )

getIndexName() 공개 메소드

public getIndexName ( )

getMetaFile() 보호된 메소드

Get the meta file name
protected getMetaFile ( )

getRST() 공개 메소드

Gets the .rst of a source file
public getRST ( $file )

getSourceFile() 공개 메소드

Gets the name of a source file
public getSourceFile ( $filename )

getTargetFile() 공개 메소드

Gets the name of a target file
public getTargetFile ( $filename )

getTargetOf() 공개 메소드

Gets the name of a target for a file, for instance /introduction/part1 could be resolved into /path/to/introduction/part1.html
public getTargetOf ( $file )

getUrl() 공개 메소드

Gets the URL of a target file
public getUrl ( $document )

loadMetas() 보호된 메소드

Try to inport the metas from the meta files
protected loadMetas ( )

mkdir() 공개 메소드

Creates a directory in the target
public mkdir ( $directory )
$directory the directory name to create

parseAll() 보호된 메소드

Parses all the document that need to be parsed
protected parseAll ( )

render() 보호된 메소드

Renders all the pending documents
protected render ( )

saveMetas() 보호된 메소드

Saving the meta files
protected saveMetas ( )

scan() 공개 메소드

Scans a file, this will check the status of the file and tell if it needs to be parsed or not
public scan ( $file )

scanMetas() 공개 메소드

Scans all the metas
public scanMetas ( )

setIndexName() 공개 메소드

public setIndexName ( $name )

프로퍼티 상세

$beforeHooks 보호되어 있는 프로퍼티

Hooks before the parsing on the environment
protected $beforeHooks

$directory 보호되어 있는 프로퍼티

Source and target directory
protected $directory

$documents 보호되어 있는 프로퍼티

Parsed documents waiting to be rendered
protected $documents

$errorManager 보호되어 있는 프로퍼티

Error manager
protected $errorManager

$hooks 보호되어 있는 프로퍼티

Hooks after the parsing
protected $hooks

$indexName 보호되어 있는 프로퍼티

Tree index name
protected $indexName

$kernel 보호되어 있는 프로퍼티

Kernel
protected $kernel

$metas 보호되어 있는 프로퍼티

Metas for documents
protected $metas

$parseQueue 보호되어 있는 프로퍼티

Queue of documents to be parsed
protected $parseQueue

$states 보호되어 있는 프로퍼티

States (decision) of the scanned documents
protected $states

$targetDirectory 보호되어 있는 프로퍼티

protected $targetDirectory

$toCopy 보호되어 있는 프로퍼티

Files to copy at the end of the build
protected $toCopy

$toMkdir 보호되어 있는 프로퍼티

protected $toMkdir

$verbose 보호되어 있는 프로퍼티

Verbose build ?
protected $verbose