Definition at line 41 of file Qt.php.
◆ _loadTranslationData()
_loadTranslationData |
( |
|
$filename, |
|
|
|
$locale, |
|
|
array |
$options = array() |
|
) |
| |
|
protected |
Load translation data (QT file reader)
- Parameters
-
string | $locale | Locale/Language to add data for, identical with locale identifier, see Zend_Locale for more information |
string | $filename | QT file to add, full path must be given for access |
array | $option | OPTIONAL Options to use |
- Exceptions
-
Zend_Translation_Exception | |
- Returns
- array
Definition at line 64 of file Qt.php.
66 $this->_data = array();
68 #require_once 'Zend/Translate/Exception.php'; 72 $this->_target = $locale; 74 $encoding = $this->_findEncoding($filename); 75 $this->_file = xml_parser_create($encoding); 76 xml_set_object($this->_file, $this); 77 xml_parser_set_option($this->_file, XML_OPTION_CASE_FOLDING, 0); 78 xml_set_element_handler($this->_file, "_startElement", "_endElement"); 79 xml_set_character_data_handler($this->_file, "_contentElement"); 82 Zend_Xml_Security::scanFile($filename); 83 } catch (Zend_Xml_Exception $e) { 84 #require_once 'Zend/Translate/Exception.php
'; 85 throw new Zend_Translate_Exception( 90 if (!xml_parse($this->_file, file_get_contents($filename))) { 91 $ex = sprintf('XML error: %s at line %d of file %s
', 92 xml_error_string(xml_get_error_code($this->_file)), 93 xml_get_current_line_number($this->_file), 95 xml_parser_free($this->_file); 96 #require_once 'Zend/Translate/Exception.php
'; 97 throw new Zend_Translate_Exception($ex);
◆ toString()
Returns the adapter name
- Returns
- string
Definition at line 171 of file Qt.php.
The documentation for this class was generated from the following file:
- vendor/magento/zendframework1/library/Zend/Translate/Adapter/Qt.php