private function PoStreamWriter::write
private PoStreamWriter::write($data)
Write data to the stream.
Parameters
string $data: Piece of string to write to the stream. If the value is not directly a string, casting will happen in writing.
Throws
Exception If writing the data is not possible.
File
- core/lib/Drupal/Component/Gettext/PoStreamWriter.php, line 106
Class
- PoStreamWriter
- Defines a Gettext PO stream writer.
Namespace
Drupal\Component\GettextCode
private function write($data) { $result = fputs($this->_fd, $data); if ($result === FALSE) { throw new Exception('Unable to write data: ' . substr($data, 0, 20)); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Component!Gettext!PoStreamWriter.php/function/PoStreamWriter::write/8.1.x