JsonFileDumper.php in Plug 7
File
lib/Symfony/translation/Dumper/JsonFileDumper.php
View source
<?php
namespace Symfony\Component\Translation\Dumper;
use Symfony\Component\Translation\MessageCatalogue;
class JsonFileDumper extends FileDumper {
public function format(MessageCatalogue $messages, $domain = 'messages') {
return json_encode($messages
->all($domain), defined('JSON_PRETTY_PRINT') ? JSON_PRETTY_PRINT : 0);
}
protected function getExtension() {
return 'json';
}
}
Classes
Name |
Description |
JsonFileDumper |
JsonFileDumper generates an json formatted string representation of a message catalogue. |