@@ 32-49 (lines=18) @@ | ||
29 | */ |
|
30 | public $volumes = []; |
|
31 | ||
32 | public function __construct($aData = []) |
|
33 | { |
|
34 | MarathonEntityUtils::setAllPossibleProperties($aData, $this); |
|
35 | ||
36 | if (isset($aData['docker'])) |
|
37 | { |
|
38 | $this->docker = new Docker((array)$aData['docker']); |
|
39 | } |
|
40 | ||
41 | if (isset($aData['volumes'])) |
|
42 | { |
|
43 | foreach ($aData['volumes'] as $volume) |
|
44 | { |
|
45 | $this->volumes[] = new ContainerVolume((array)$volume); |
|
46 | } |
|
47 | } |
|
48 | ||
49 | } |
|
50 | } |
@@ 36-56 (lines=21) @@ | ||
33 | */ |
|
34 | public $parameters = []; |
|
35 | ||
36 | public function __construct($aData = []) |
|
37 | { |
|
38 | MarathonEntityUtils::setAllPossibleProperties($aData, $this); |
|
39 | ||
40 | if (isset($aData['portMappings'])) |
|
41 | { |
|
42 | foreach($aData['portMappings'] as $portMapping) |
|
43 | { |
|
44 | $this->portMappings[] = new DockerPortMapping((array)$portMapping); |
|
45 | } |
|
46 | } |
|
47 | ||
48 | if (isset($aData['parameters'])) |
|
49 | { |
|
50 | foreach($aData['parameters'] as $parameter) |
|
51 | { |
|
52 | $this->parameters[] = new DockerParameters((array)$parameter); |
|
53 | } |
|
54 | } |
|
55 | ||
56 | } |
|
57 | } |