XarayaTranslationMemory
1.6
export
ExporterFactory.php
Go to the documentation of this file.
1
<?php
2
/***************************************************************************
3
* Copyright (C) 2005-2020 by Ferenc Veres *
4
* lion@netngine.hu *
5
* *
6
* This program is free software; you can redistribute it and/or modify *
7
* it under the terms of the GNU General Public License as published by *
8
* the Free Software Foundation; either version 3 of the License, or *
9
* (at your option) any later version. *
10
* *
11
* This program is distributed in the hope that it will be useful, *
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14
* GNU General Public License for more details. *
15
* *
16
* You should have received a copy of the GNU General Public License *
17
* along with this program. If not, see <http://www.gnu.org/licenses/>. *
18
***************************************************************************/
19
include_once(
"ITranslationExport.php"
);
20
include_once(
"TranslationExportXaraya.php"
);
21
include_once(
"TranslationExportXarigami.php"
);
22
27
class
ExporterFactory
28
{
33
function
__construct
()
34
{
35
}
36
42
public
function
NewExporter
($type)
43
{
44
switch
($type)
45
{
46
case
'Xaraya'
:
return
new
TranslationExportXaraya
();
47
case
'Xarigami'
:
return
new
TranslationExportXarigami
();
48
default
:
throw
new
Exception(
"NewExporter: Creating unknown exporter: $type"
);
49
}
50
}
51
}
52
?>
ExporterFactory\NewExporter
NewExporter($type)
Definition:
ExporterFactory.php:42
ExporterFactory\__construct
__construct()
Definition:
ExporterFactory.php:33
TranslationExportXarigami
Definition:
TranslationExportXarigami.php:34
ExporterFactory
Definition:
ExporterFactory.php:27
TranslationExportXaraya
Definition:
TranslationExportXaraya.php:34
Generated by
1.8.13