1
|
|
|
<?php |
2
|
|
|
namespace Perry\Representation\Eve\v1; |
3
|
|
|
|
4
|
|
|
use \Perry\Representation\Reference as Reference; |
5
|
|
|
use \Perry\Representation\Uri as Uri; |
6
|
|
|
use \Perry\Representation\Base as Base; |
7
|
|
|
|
8
|
|
|
class Corporation extends Base |
9
|
|
|
{ |
10
|
|
|
public $taxRate; |
11
|
|
|
|
12
|
|
|
public $alliance; |
13
|
|
|
|
14
|
|
|
public $founder; |
15
|
|
|
|
16
|
|
|
public $membersRoles; |
17
|
|
|
|
18
|
|
|
public $private; |
19
|
|
|
|
20
|
|
|
public $href; |
21
|
|
|
|
22
|
|
|
public $accounts; |
23
|
|
|
|
24
|
|
|
public $logo; |
25
|
|
|
|
26
|
|
|
public $id; |
27
|
|
|
|
28
|
|
|
public $acceptApplications; |
29
|
|
|
|
30
|
|
|
public $shares; |
31
|
|
|
|
32
|
|
|
public $homepage; |
33
|
|
|
|
34
|
|
|
public $description; |
35
|
|
|
|
36
|
|
|
public $faction; |
37
|
|
|
|
38
|
|
|
public $ceo; |
39
|
|
|
|
40
|
|
|
public $isNpcCorporation; |
41
|
|
|
|
42
|
|
|
public $applications; |
43
|
|
|
|
44
|
|
|
public $members; |
45
|
|
|
|
46
|
|
|
public $conflicts; |
47
|
|
|
|
48
|
|
|
public $ticker; |
49
|
|
|
|
50
|
|
|
public $displayName; |
51
|
|
|
|
52
|
|
|
public $name; |
53
|
|
|
|
54
|
|
|
public $stations = []; |
55
|
|
|
|
56
|
|
|
public $headquarters; |
57
|
|
|
|
58
|
|
|
public $districts; |
59
|
|
|
|
60
|
|
|
public $offices = []; |
61
|
|
|
|
62
|
|
|
public $deposit; |
63
|
|
|
|
64
|
|
|
// by Warringer\Types\Base |
65
|
|
|
public function setTaxRate($taxRate) |
66
|
|
|
{ |
67
|
|
|
$this->taxRate = $taxRate; |
68
|
|
|
} |
69
|
|
|
|
70
|
|
|
// by Warringer\Types\Reference |
71
|
|
|
public function setAlliance($alliance) |
72
|
|
|
{ |
73
|
|
|
$this->alliance = new Reference($alliance); |
74
|
|
|
} |
75
|
|
|
|
76
|
|
|
// by Warringer\Types\Reference |
77
|
|
|
public function setFounder($founder) |
78
|
|
|
{ |
79
|
|
|
$this->founder = new Reference($founder); |
80
|
|
|
} |
81
|
|
|
|
82
|
|
|
// by Warringer\Types\Reference |
83
|
|
|
public function setMembersRoles($membersRoles) |
84
|
|
|
{ |
85
|
|
|
$this->membersRoles = new Reference($membersRoles); |
86
|
|
|
} |
87
|
|
|
|
88
|
|
|
// by Warringer\Types\Reference |
89
|
|
|
public function setPrivate($private) |
90
|
|
|
{ |
91
|
|
|
$this->private = new Reference($private); |
92
|
|
|
} |
93
|
|
|
|
94
|
|
|
// by Warringer\Types\Uri |
95
|
|
|
public function setHref($href) |
96
|
|
|
{ |
97
|
|
|
$this->href = new Uri($href); |
98
|
|
|
} |
99
|
|
|
|
100
|
|
|
// by Warringer\Types\Reference |
101
|
|
|
public function setAccounts($accounts) |
102
|
|
|
{ |
103
|
|
|
$this->accounts = new Reference($accounts); |
104
|
|
|
} |
105
|
|
|
|
106
|
|
|
// by Warringer\Types\Dict |
107
|
|
|
public function setLogo($logo) |
108
|
|
|
{ |
109
|
|
|
// by Warringer\Types\Dict |
110
|
|
|
$converters = []; |
111
|
|
|
$converters['32x32'] = function ($value) { return new Reference($value); }; |
112
|
|
|
$converters['logo'] = function ($value) { return $value; }; |
113
|
|
|
$converters['128x128'] = function ($value) { return new Reference($value); }; |
114
|
|
|
$converters['256x256'] = function ($value) { return new Reference($value); }; |
115
|
|
|
$converters['64x64'] = function ($value) { return new Reference($value); }; |
116
|
|
|
|
117
|
|
|
$func = function ($value) use($converters) { |
118
|
|
|
$return = new \ArrayObject($value, \ArrayObject::ARRAY_AS_PROPS); |
119
|
|
|
$return['32x32'] = isset($value->{'32x32'}) ? $converters['32x32']($value->{'32x32'}) : null; |
120
|
|
|
$return['logo'] = isset($value->{'logo'}) ? $converters['logo']($value->{'logo'}) : null; |
121
|
|
|
$return['128x128'] = isset($value->{'128x128'}) ? $converters['128x128']($value->{'128x128'}) : null; |
122
|
|
|
$return['256x256'] = isset($value->{'256x256'}) ? $converters['256x256']($value->{'256x256'}) : null; |
123
|
|
|
$return['64x64'] = isset($value->{'64x64'}) ? $converters['64x64']($value->{'64x64'}) : null; |
124
|
|
|
return $return; |
125
|
|
|
}; |
126
|
|
|
$this->logo = $func($logo); |
127
|
|
|
} |
128
|
|
|
|
129
|
|
|
// by Warringer\Types\Long |
130
|
|
|
public function setId($id) |
131
|
|
|
{ |
132
|
|
|
$this->id = $id; |
133
|
|
|
} |
134
|
|
|
|
135
|
|
|
// by Warringer\Types\Base |
136
|
|
|
public function setAcceptApplications($acceptApplications) |
137
|
|
|
{ |
138
|
|
|
$this->acceptApplications = $acceptApplications; |
139
|
|
|
} |
140
|
|
|
|
141
|
|
|
// by Warringer\Types\Long |
142
|
|
|
public function setShares($shares) |
143
|
|
|
{ |
144
|
|
|
$this->shares = $shares; |
145
|
|
|
} |
146
|
|
|
|
147
|
|
|
// by Warringer\Types\String |
148
|
|
|
public function setHomepage($homepage) |
149
|
|
|
{ |
150
|
|
|
$this->homepage = $homepage; |
151
|
|
|
} |
152
|
|
|
|
153
|
|
|
// by Warringer\Types\String |
154
|
|
|
public function setDescription($description) |
155
|
|
|
{ |
156
|
|
|
$this->description = $description; |
157
|
|
|
} |
158
|
|
|
|
159
|
|
|
// by Warringer\Types\Reference |
160
|
|
|
public function setFaction($faction) |
161
|
|
|
{ |
162
|
|
|
$this->faction = new Reference($faction); |
163
|
|
|
} |
164
|
|
|
|
165
|
|
|
// by Warringer\Types\Reference |
166
|
|
|
public function setCeo($ceo) |
167
|
|
|
{ |
168
|
|
|
$this->ceo = new Reference($ceo); |
169
|
|
|
} |
170
|
|
|
|
171
|
|
|
// by Warringer\Types\Base |
172
|
|
|
public function setIsNpcCorporation($isNpcCorporation) |
173
|
|
|
{ |
174
|
|
|
$this->isNpcCorporation = $isNpcCorporation; |
175
|
|
|
} |
176
|
|
|
|
177
|
|
|
// by Warringer\Types\Reference |
178
|
|
|
public function setApplications($applications) |
179
|
|
|
{ |
180
|
|
|
$this->applications = new Reference($applications); |
181
|
|
|
} |
182
|
|
|
|
183
|
|
|
// by Warringer\Types\Reference |
184
|
|
|
public function setMembers($members) |
185
|
|
|
{ |
186
|
|
|
$this->members = new Reference($members); |
187
|
|
|
} |
188
|
|
|
|
189
|
|
|
// by Warringer\Types\Reference |
190
|
|
|
public function setConflicts($conflicts) |
191
|
|
|
{ |
192
|
|
|
$this->conflicts = new Reference($conflicts); |
193
|
|
|
} |
194
|
|
|
|
195
|
|
|
// by Warringer\Types\String |
196
|
|
|
public function setTicker($ticker) |
197
|
|
|
{ |
198
|
|
|
$this->ticker = $ticker; |
199
|
|
|
} |
200
|
|
|
|
201
|
|
|
// by Warringer\Types\String |
202
|
|
|
public function setDisplayName($displayName) |
203
|
|
|
{ |
204
|
|
|
$this->displayName = $displayName; |
205
|
|
|
} |
206
|
|
|
|
207
|
|
|
// by Warringer\Types\String |
208
|
|
|
public function setName($name) |
209
|
|
|
{ |
210
|
|
|
$this->name = $name; |
211
|
|
|
} |
212
|
|
|
|
213
|
|
|
// by Warringer\Types\ArrayType |
214
|
|
|
public function setStations($stations) |
215
|
|
|
{ |
216
|
|
|
// by Warringer\Types\Dict |
217
|
|
|
$converters = []; |
218
|
|
|
|
219
|
|
|
$func = function ($value) use($converters) { |
220
|
|
|
$return = new \ArrayObject($value, \ArrayObject::ARRAY_AS_PROPS); |
221
|
|
|
return $return; |
222
|
|
|
}; |
223
|
|
|
|
224
|
|
|
foreach ($stations as $key => $value) { |
225
|
|
|
$this->stations[$key] = $func($value); |
226
|
|
|
} |
227
|
|
|
} |
228
|
|
|
|
229
|
|
|
// by Warringer\Types\Reference |
230
|
|
|
public function setHeadquarters($headquarters) |
231
|
|
|
{ |
232
|
|
|
$this->headquarters = new Reference($headquarters); |
233
|
|
|
} |
234
|
|
|
|
235
|
|
|
// by Warringer\Types\Reference |
236
|
|
|
public function setDistricts($districts) |
237
|
|
|
{ |
238
|
|
|
$this->districts = new Reference($districts); |
239
|
|
|
} |
240
|
|
|
|
241
|
|
|
// by Warringer\Types\ArrayType |
242
|
|
|
public function setOffices($offices) |
243
|
|
|
{ |
244
|
|
|
// by Warringer\Types\Dict |
245
|
|
|
$converters = []; |
246
|
|
|
|
247
|
|
|
$func = function ($value) use($converters) { |
248
|
|
|
$return = new \ArrayObject($value, \ArrayObject::ARRAY_AS_PROPS); |
249
|
|
|
return $return; |
250
|
|
|
}; |
251
|
|
|
|
252
|
|
|
foreach ($offices as $key => $value) { |
253
|
|
|
$this->offices[$key] = $func($value); |
254
|
|
|
} |
255
|
|
|
} |
256
|
|
|
|
257
|
|
|
// by Warringer\Types\Reference |
258
|
|
|
public function setDeposit($deposit) |
259
|
|
|
{ |
260
|
|
|
$this->deposit = new Reference($deposit); |
261
|
|
|
} |
262
|
|
|
|
263
|
|
|
} |
264
|
|
|
|