1 | <?php |
||
21 | class TranslateOptions |
||
22 | { |
||
23 | /** |
||
24 | * @const string |
||
25 | */ |
||
26 | const XML_NAMESPACE_URI = 'http://schemas.datacontract.org/2004/07/Microsoft.MT.Web.Service.V2'; |
||
27 | |||
28 | /** |
||
29 | * @const Html content type, HTML needs to be well-formed. |
||
30 | */ |
||
31 | const CONTENT_TYPE_HTML = 'text/html'; |
||
32 | |||
33 | /** |
||
34 | * @const plain text content type |
||
35 | */ |
||
36 | const CONTENT_TYPE_PLAIN = 'text/plain'; |
||
37 | |||
38 | /** |
||
39 | * @var string; |
||
40 | */ |
||
41 | protected $category; |
||
42 | |||
43 | /** |
||
44 | * @var string |
||
45 | */ |
||
46 | protected $contentType; |
||
47 | |||
48 | /** |
||
49 | * @var string |
||
50 | */ |
||
51 | protected $reservedFlag; |
||
52 | |||
53 | /** |
||
54 | * @var string |
||
55 | */ |
||
56 | protected $state; |
||
57 | |||
58 | /** |
||
59 | * @var string |
||
60 | */ |
||
61 | protected $uri; |
||
62 | |||
63 | /** |
||
64 | * @var string |
||
65 | */ |
||
66 | protected $user; |
||
67 | |||
68 | /** |
||
69 | * TranslateOptions constructor. |
||
70 | * @param $category |
||
71 | * @param $contentType |
||
72 | * @param $reservedType |
||
73 | * @param $state |
||
74 | * @param $uri |
||
75 | * @param $user |
||
76 | */ |
||
77 | 33 | public function __construct( |
|
96 | |||
97 | /** |
||
98 | * @param string $root |
||
99 | * @return \DOMDocument |
||
100 | */ |
||
101 | 15 | public function xml($root = 'TranslateOptions') |
|
117 | |||
118 | /** |
||
119 | * @return string |
||
120 | */ |
||
121 | 9 | public function __toString() |
|
125 | } |
||
126 |