Inheritance diagram for ExtractTask:

Public Member Functions | |
| __buildFiles () | |
| __extract () | |
| __extractTokens () | |
| __findVersion ($code, $file) | |
| __formatString ($string) | |
| __markerError ($file, $line, $marker, $count) | |
| __mergeFiles ($output) | |
| __searchDirectory ($path=null) | |
| __store ($file=0, $input=0, $fileList=array(), $get=0) | |
| __writeFiles () | |
| __writeHeader () | |
| basic ($functionName= '__') | |
| execute () | |
| extended ($functionName= '__d', $shift=0, $plural=false) | |
| help () | |
Public Attributes | |
| $__file = null | |
| $__filename = 'default' | |
| $__fileVersions = array() | |
| $__oneFile = true | |
| $__output = null | |
| $__strings = array() | |
| $__tokens = array() | |
| $files = array() | |
| $path = null | |
Definition at line 60 of file extract.php.
| ExtractTask::__buildFiles | ( | ) |
Build the translate template file contents out of obtained strings
private
Definition at line 410 of file extract.php.
References $filename, $output, and __store().
Referenced by __extractTokens().
| ExtractTask::__extract | ( | ) |
Extract text
private
Definition at line 188 of file extract.php.
References $filename, __(), __extractTokens(), Shell::hr(), Shell::in(), name(), and Shell::out().
Referenced by execute().
| ExtractTask::__extractTokens | ( | ) |
Extract tokens out of all files to be processed
private
Definition at line 245 of file extract.php.
References __(), __buildFiles(), __c(), __dc(), __dcn(), __dn(), __findVersion(), __n(), __writeFiles(), basic(), extended(), and Shell::out().
Referenced by __extract().
| ExtractTask::__findVersion | ( | $ | code, | |
| $ | file | |||
| ) |
Find the version number of a file looking for SVN commands
| string | $code Source code of file | |
| string | $file File private |
Definition at line 600 of file extract.php.
Referenced by __extractTokens().
| ExtractTask::__formatString | ( | $ | string | ) |
Format a string to be added as a translateable string
| string | $string String to format |
Definition at line 614 of file extract.php.
Referenced by basic(), and extended().
| ExtractTask::__markerError | ( | $ | file, | |
| $ | line, | |||
| $ | marker, | |||
| $ | count | |||
| ) |
Indicate an invalid marker on a processed file
| string | $file File where invalid marker resides | |
| integer | $line Line number | |
| string | $marker Marker found | |
| integer | $count Count private |
Definition at line 634 of file extract.php.
References Shell::out().
Referenced by basic(), and extended().
| ExtractTask::__mergeFiles | ( | $ | output | ) |
Merge output files
| array | $output Output to merge |
Definition at line 549 of file extract.php.
References $output.
Referenced by __writeFiles().
| ExtractTask::__searchDirectory | ( | $ | path = null |
) |
| ExtractTask::__store | ( | $ | file = 0, |
|
| $ | input = 0, |
|||
| $ | fileList = array(), |
|||
| $ | get = 0 | |||
| ) |
Prepare a file to be stored
| string | $file Filename | |
| string | $input What to store | |
| array | $fileList File list | |
| integer | $get Set to 1 to get files to store, false to set |
Definition at line 477 of file extract.php.
References __writeHeader().
Referenced by __buildFiles(), and __writeFiles().
| ExtractTask::__writeFiles | ( | ) |
Write the files that need to be stored
private
Definition at line 499 of file extract.php.
References $output, __mergeFiles(), __store(), Object::_stop(), exists(), Shell::in(), and Shell::out().
Referenced by __extractTokens().
| ExtractTask::__writeHeader | ( | ) |
Build the translation template header
Definition at line 574 of file extract.php.
References $output.
Referenced by __store().
| ExtractTask::basic | ( | $ | functionName = '__' |
) |
Will parse __(), __c() functions
| string | $functionName Function name that indicates translatable string (e.g: '__') public |
Definition at line 290 of file extract.php.
References __formatString(), and __markerError().
Referenced by __extractTokens().
| ExtractTask::execute | ( | ) |
Execution method always used for tasks
public
Definition at line 129 of file extract.php.
References __extract(), __searchDirectory(), Object::_stop(), debug(), Shell::err(), Shell::in(), Shell::out(), and params().
| ExtractTask::extended | ( | $ | functionName = '__d', |
|
| $ | shift = 0, |
|||
| $ | plural = false | |||
| ) |
Will parse __d(), __dc(), __n(), __dn(), __dcn()
| string | $functionName Function name that indicates translatable string (e.g: '__') | |
| integer | $shift Number of parameters to shift to find translateable string | |
| boolean | $plural Set to true if function supports plural format, false otherwise public |
Definition at line 327 of file extract.php.
References __formatString(), and __markerError().
Referenced by __extractTokens().
| ExtractTask::help | ( | ) |
Show help options
public
Reimplemented from Shell.
Definition at line 220 of file extract.php.
References __(), debug(), Shell::hr(), Shell::in(), and Shell::out().
| ExtractTask::$__file = null |
Definition at line 95 of file extract.php.
| ExtractTask::$__filename = 'default' |
Definition at line 81 of file extract.php.
| ExtractTask::$__fileVersions = array() |
Definition at line 116 of file extract.php.
| ExtractTask::$__oneFile = true |
Definition at line 88 of file extract.php.
| ExtractTask::$__output = null |
Definition at line 123 of file extract.php.
| ExtractTask::$__strings = array() |
Definition at line 109 of file extract.php.
| ExtractTask::$__tokens = array() |
Definition at line 102 of file extract.php.
| ExtractTask::$files = array() |
| ExtractTask::$path = null |
1.4.7