|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
declare(strict_types=1); |
|
4
|
|
|
|
|
5
|
|
|
namespace Stu\Module\Starmap\Lib; |
|
6
|
|
|
|
|
7
|
|
|
use Doctrine\ORM\Mapping\Column; |
|
8
|
|
|
use Doctrine\ORM\Mapping\Entity; |
|
9
|
|
|
use Doctrine\ORM\Mapping\Id; |
|
10
|
|
|
use Doctrine\ORM\Mapping\JoinColumn; |
|
11
|
|
|
use Doctrine\ORM\Mapping\ManyToOne; |
|
12
|
|
|
use Stu\Orm\Entity\MapBorderTypeInterface; |
|
13
|
|
|
use Stu\Orm\Entity\MapRegionInterface; |
|
14
|
|
|
use Stu\Orm\Entity\StarSystemInterface; |
|
15
|
|
|
|
|
16
|
|
|
/** |
|
17
|
|
|
* @Entity |
|
18
|
|
|
*/ |
|
19
|
|
|
class ExploreableStarMap implements ExploreableStarMapInterface |
|
20
|
|
|
{ |
|
21
|
|
|
/** @Id @Column(type="integer") * */ |
|
22
|
|
|
private int $id = 0; |
|
23
|
|
|
|
|
24
|
|
|
/** @Column(type="integer") * */ |
|
25
|
|
|
private int $cx = 0; |
|
26
|
|
|
|
|
27
|
|
|
/** @Column(type="integer") * */ |
|
28
|
|
|
private int $cy = 0; |
|
29
|
|
|
|
|
30
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
31
|
|
|
private ?int $field_id = 0; |
|
32
|
|
|
|
|
33
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
34
|
|
|
private ?int $layer_id = 0; |
|
35
|
|
|
|
|
36
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
37
|
|
|
private ?int $bordertype_id = 0; |
|
38
|
|
|
|
|
39
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
40
|
|
|
private ?int $user_id = 0; |
|
41
|
|
|
|
|
42
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
43
|
|
|
private ?int $mapped = 0; |
|
44
|
|
|
|
|
45
|
|
|
/** @Column(type="string", nullable=true) * */ |
|
46
|
|
|
private ?string $system_name; |
|
47
|
|
|
|
|
48
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
49
|
|
|
private ?int $influence_area_id = 0; |
|
|
|
|
|
|
50
|
|
|
|
|
51
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
52
|
|
|
private ?int $region_id = 0; |
|
|
|
|
|
|
53
|
|
|
|
|
54
|
|
|
/** @Column(type="integer", nullable=true) * */ |
|
55
|
|
|
private ?int $tradepost_id; |
|
56
|
|
|
|
|
57
|
|
|
/** @Column(type="string", nullable=true) * */ |
|
58
|
|
|
private ?string $region_description; |
|
59
|
|
|
|
|
60
|
|
|
/** |
|
61
|
|
|
* @ManyToOne(targetEntity="Stu\Orm\Entity\MapBorderType") |
|
62
|
|
|
* @JoinColumn(name="bordertype_id", referencedColumnName="id") |
|
63
|
|
|
* @var null|MapBorderTypeInterface |
|
64
|
|
|
*/ |
|
65
|
|
|
private ?MapBorderTypeInterface $mapBorderType; |
|
66
|
|
|
|
|
67
|
|
|
/** |
|
68
|
|
|
* @ManyToOne(targetEntity="Stu\Orm\Entity\StarSystem") |
|
69
|
|
|
* @JoinColumn(name="influence_area_id", referencedColumnName="id") |
|
70
|
|
|
* @var null|StarSystemInterface |
|
71
|
|
|
*/ |
|
72
|
|
|
private ?StarSystemInterface $influenceArea; |
|
73
|
|
|
|
|
74
|
|
|
/** |
|
75
|
|
|
* @ManyToOne(targetEntity="Stu\Orm\Entity\MapRegion") |
|
76
|
|
|
* @JoinColumn(name="region_id", referencedColumnName="id") |
|
77
|
|
|
* @var null|MapRegionInterface |
|
78
|
|
|
*/ |
|
79
|
|
|
private ?MapRegionInterface $adminRegion; |
|
80
|
|
|
|
|
81
|
|
|
public function getId(): int |
|
82
|
|
|
{ |
|
83
|
|
|
return $this->id; |
|
84
|
|
|
} |
|
85
|
|
|
|
|
86
|
|
|
public function getCx(): int |
|
87
|
|
|
{ |
|
88
|
|
|
return $this->cx; |
|
89
|
|
|
} |
|
90
|
|
|
|
|
91
|
|
|
public function getCy(): int |
|
92
|
|
|
{ |
|
93
|
|
|
return $this->cy; |
|
94
|
|
|
} |
|
95
|
|
|
|
|
96
|
|
|
public function getFieldId(): int |
|
97
|
|
|
{ |
|
98
|
|
|
return $this->field_id; |
|
|
|
|
|
|
99
|
|
|
} |
|
100
|
|
|
|
|
101
|
|
|
public function getLayer(): ?int |
|
102
|
|
|
{ |
|
103
|
|
|
return $this->layer_id; |
|
104
|
|
|
} |
|
105
|
|
|
|
|
106
|
|
|
public function getBordertypeId(): ?int |
|
107
|
|
|
{ |
|
108
|
|
|
return $this->bordertype_id; |
|
109
|
|
|
} |
|
110
|
|
|
|
|
111
|
|
|
public function getUserId(): ?int |
|
112
|
|
|
{ |
|
113
|
|
|
return $this->user_id; |
|
114
|
|
|
} |
|
115
|
|
|
|
|
116
|
|
|
public function getMapped(): ?int |
|
117
|
|
|
{ |
|
118
|
|
|
return $this->mapped; |
|
119
|
|
|
} |
|
120
|
|
|
|
|
121
|
|
|
public function getSystemName(): ?string |
|
122
|
|
|
{ |
|
123
|
|
|
return $this->system_name; |
|
124
|
|
|
} |
|
125
|
|
|
|
|
126
|
|
|
public function getTradePostId(): ?int |
|
127
|
|
|
{ |
|
128
|
|
|
return $this->tradepost_id; |
|
129
|
|
|
} |
|
130
|
|
|
|
|
131
|
|
|
public function getRegionDescription(): ?string |
|
132
|
|
|
{ |
|
133
|
|
|
return $this->region_description; |
|
134
|
|
|
} |
|
135
|
|
|
|
|
136
|
|
|
public function setRegionDescription(string $regiondescription): ExploreableStarMapInterface |
|
137
|
|
|
{ |
|
138
|
|
|
$this->region_description = $regiondescription; |
|
139
|
|
|
return $this; |
|
140
|
|
|
} |
|
141
|
|
|
|
|
142
|
|
|
public function getMapBorderType(): ?MapBorderTypeInterface |
|
143
|
|
|
{ |
|
144
|
|
|
return $this->mapBorderType; |
|
145
|
|
|
} |
|
146
|
|
|
|
|
147
|
|
|
public function getAdminRegion(): ?MapRegionInterface |
|
148
|
|
|
{ |
|
149
|
|
|
return $this->adminRegion; |
|
150
|
|
|
} |
|
151
|
|
|
|
|
152
|
|
|
public function getInfluenceArea(): ?StarSystemInterface |
|
153
|
|
|
{ |
|
154
|
|
|
return $this->influenceArea; |
|
155
|
|
|
} |
|
156
|
|
|
} |
|
157
|
|
|
|