require_once dirname(__FILE__) . '/translations.php';
require_once dirname(__FILE__) . '/streams.php';
require_once dirname(__FILE__) . '/translations.php';
require_once dirname(__FILE__) . '/streams.php';
function export_to_file($filename) {
$fh = fopen($filename, 'wb');
if ( !$fh ) return false;
function export_to_file($filename) {
$fh = fopen($filename, 'wb');
if ( !$fh ) return false;
function export() {
$tmp_fh = fopen("php://temp", 'r+');
if ( !$tmp_fh ) return false;
function export() {
$tmp_fh = fopen("php://temp", 'r+');
if ( !$tmp_fh ) return false;
function export_to_file_handle($fh) {
$entries = array_filter( $this->entries, array( $this, 'is_entry_good_for_export' ) );
ksort($entries);
function export_to_file_handle($fh) {
$entries = array_filter( $this->entries, array( $this, 'is_entry_good_for_export' ) );
ksort($entries);
function export_original($entry) {
//TODO: warnings for control characters
$exported = $entry->singular;
if ($entry->is_plural) $exported .= chr(0).$entry->plural;
function export_original($entry) {
//TODO: warnings for control characters
$exported = $entry->singular;
if ($entry->is_plural) $exported .= chr(0).$entry->plural;
function import_from_reader($reader) {
$endian_string = MO::get_byteorder($reader->readint32());
if (false === $endian_string) {
function import_from_reader($reader) {
$endian_string = MO::get_byteorder($reader->readint32());
if (false === $endian_string) {