27 $this->db = $DIC->database();
48 $this->candidates =
array();
51 $set = $this->db->query(
"SELECT module, identifier FROM lng_log ");
52 while ($rec = $this->db->fetchAssoc($set))
54 $log[$rec[
"module"].
":".$rec[
"identifier"]] = 1;
56 $set = $this->db->query(
"SELECT module, identifier FROM lng_data WHERE lang_key = ".
57 $this->db->quote(
"en",
"text").
" ORDER BY module, identifier");
58 while ($rec = $this->db->fetchAssoc($set))
60 if (!isset(
$log[$rec[
"module"].
":".$rec[
"identifier"]]))
62 $this->candidates[$rec[
"identifier"]] = $rec[
"module"];
87 new \RecursiveDirectoryIterator(
$path),
88 \RecursiveIteratorIterator::SELF_FIRST,
89 \RecursiveIteratorIterator::CATCH_GET_CHILD
90 ),
'/' . self::ILIAS_CLASS_FILE_RE .
'/i' 104 $tokens = token_get_all(file_get_contents($file_path));
115 $num_tokens = count($tokens);
117 for ($i = 0; $i < $num_tokens; $i++) {
118 if (is_string($tokens[$i])) {
122 $token = $tokens[$i][0];
126 case T_CONSTANT_ENCAPSED_STRING:
127 $lv = str_replace(
array(
"'",
'"'),
"", $tokens[$i][1]);
129 unset($this->candidates[$lv]);
__construct()
ilLangDeprecated constructor.
parseCodeFiles()
Parse Code Files.
Search for deprecated lang vars.
const ILIAS_CLASS_FILE_RE
getDeprecatedLangVars()
Get deprecated lang vars.
getCandidates()
Get candidates from the db.
Create styles array
The data for the language used.
parseCodeFile($file_path)
Parse code file and reduce candidates.
if(!file_exists("$old.txt")) if($old===$new) if(file_exists("$new.txt")) $file