1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service\Compute;
19
20class RouterNat extends \Google\Collection
21{
22  protected $collection_key = 'subnetworks';
23  /**
24   * @var string[]
25   */
26  public $drainNatIps;
27  /**
28   * @var bool
29   */
30  public $enableDynamicPortAllocation;
31  /**
32   * @var bool
33   */
34  public $enableEndpointIndependentMapping;
35  /**
36   * @var int
37   */
38  public $icmpIdleTimeoutSec;
39  protected $logConfigType = RouterNatLogConfig::class;
40  protected $logConfigDataType = '';
41  /**
42   * @var int
43   */
44  public $maxPortsPerVm;
45  /**
46   * @var int
47   */
48  public $minPortsPerVm;
49  /**
50   * @var string
51   */
52  public $name;
53  /**
54   * @var string
55   */
56  public $natIpAllocateOption;
57  /**
58   * @var string[]
59   */
60  public $natIps;
61  protected $rulesType = RouterNatRule::class;
62  protected $rulesDataType = 'array';
63  /**
64   * @var string
65   */
66  public $sourceSubnetworkIpRangesToNat;
67  protected $subnetworksType = RouterNatSubnetworkToNat::class;
68  protected $subnetworksDataType = 'array';
69  /**
70   * @var int
71   */
72  public $tcpEstablishedIdleTimeoutSec;
73  /**
74   * @var int
75   */
76  public $tcpTimeWaitTimeoutSec;
77  /**
78   * @var int
79   */
80  public $tcpTransitoryIdleTimeoutSec;
81  /**
82   * @var int
83   */
84  public $udpIdleTimeoutSec;
85
86  /**
87   * @param string[]
88   */
89  public function setDrainNatIps($drainNatIps)
90  {
91    $this->drainNatIps = $drainNatIps;
92  }
93  /**
94   * @return string[]
95   */
96  public function getDrainNatIps()
97  {
98    return $this->drainNatIps;
99  }
100  /**
101   * @param bool
102   */
103  public function setEnableDynamicPortAllocation($enableDynamicPortAllocation)
104  {
105    $this->enableDynamicPortAllocation = $enableDynamicPortAllocation;
106  }
107  /**
108   * @return bool
109   */
110  public function getEnableDynamicPortAllocation()
111  {
112    return $this->enableDynamicPortAllocation;
113  }
114  /**
115   * @param bool
116   */
117  public function setEnableEndpointIndependentMapping($enableEndpointIndependentMapping)
118  {
119    $this->enableEndpointIndependentMapping = $enableEndpointIndependentMapping;
120  }
121  /**
122   * @return bool
123   */
124  public function getEnableEndpointIndependentMapping()
125  {
126    return $this->enableEndpointIndependentMapping;
127  }
128  /**
129   * @param int
130   */
131  public function setIcmpIdleTimeoutSec($icmpIdleTimeoutSec)
132  {
133    $this->icmpIdleTimeoutSec = $icmpIdleTimeoutSec;
134  }
135  /**
136   * @return int
137   */
138  public function getIcmpIdleTimeoutSec()
139  {
140    return $this->icmpIdleTimeoutSec;
141  }
142  /**
143   * @param RouterNatLogConfig
144   */
145  public function setLogConfig(RouterNatLogConfig $logConfig)
146  {
147    $this->logConfig = $logConfig;
148  }
149  /**
150   * @return RouterNatLogConfig
151   */
152  public function getLogConfig()
153  {
154    return $this->logConfig;
155  }
156  /**
157   * @param int
158   */
159  public function setMaxPortsPerVm($maxPortsPerVm)
160  {
161    $this->maxPortsPerVm = $maxPortsPerVm;
162  }
163  /**
164   * @return int
165   */
166  public function getMaxPortsPerVm()
167  {
168    return $this->maxPortsPerVm;
169  }
170  /**
171   * @param int
172   */
173  public function setMinPortsPerVm($minPortsPerVm)
174  {
175    $this->minPortsPerVm = $minPortsPerVm;
176  }
177  /**
178   * @return int
179   */
180  public function getMinPortsPerVm()
181  {
182    return $this->minPortsPerVm;
183  }
184  /**
185   * @param string
186   */
187  public function setName($name)
188  {
189    $this->name = $name;
190  }
191  /**
192   * @return string
193   */
194  public function getName()
195  {
196    return $this->name;
197  }
198  /**
199   * @param string
200   */
201  public function setNatIpAllocateOption($natIpAllocateOption)
202  {
203    $this->natIpAllocateOption = $natIpAllocateOption;
204  }
205  /**
206   * @return string
207   */
208  public function getNatIpAllocateOption()
209  {
210    return $this->natIpAllocateOption;
211  }
212  /**
213   * @param string[]
214   */
215  public function setNatIps($natIps)
216  {
217    $this->natIps = $natIps;
218  }
219  /**
220   * @return string[]
221   */
222  public function getNatIps()
223  {
224    return $this->natIps;
225  }
226  /**
227   * @param RouterNatRule[]
228   */
229  public function setRules($rules)
230  {
231    $this->rules = $rules;
232  }
233  /**
234   * @return RouterNatRule[]
235   */
236  public function getRules()
237  {
238    return $this->rules;
239  }
240  /**
241   * @param string
242   */
243  public function setSourceSubnetworkIpRangesToNat($sourceSubnetworkIpRangesToNat)
244  {
245    $this->sourceSubnetworkIpRangesToNat = $sourceSubnetworkIpRangesToNat;
246  }
247  /**
248   * @return string
249   */
250  public function getSourceSubnetworkIpRangesToNat()
251  {
252    return $this->sourceSubnetworkIpRangesToNat;
253  }
254  /**
255   * @param RouterNatSubnetworkToNat[]
256   */
257  public function setSubnetworks($subnetworks)
258  {
259    $this->subnetworks = $subnetworks;
260  }
261  /**
262   * @return RouterNatSubnetworkToNat[]
263   */
264  public function getSubnetworks()
265  {
266    return $this->subnetworks;
267  }
268  /**
269   * @param int
270   */
271  public function setTcpEstablishedIdleTimeoutSec($tcpEstablishedIdleTimeoutSec)
272  {
273    $this->tcpEstablishedIdleTimeoutSec = $tcpEstablishedIdleTimeoutSec;
274  }
275  /**
276   * @return int
277   */
278  public function getTcpEstablishedIdleTimeoutSec()
279  {
280    return $this->tcpEstablishedIdleTimeoutSec;
281  }
282  /**
283   * @param int
284   */
285  public function setTcpTimeWaitTimeoutSec($tcpTimeWaitTimeoutSec)
286  {
287    $this->tcpTimeWaitTimeoutSec = $tcpTimeWaitTimeoutSec;
288  }
289  /**
290   * @return int
291   */
292  public function getTcpTimeWaitTimeoutSec()
293  {
294    return $this->tcpTimeWaitTimeoutSec;
295  }
296  /**
297   * @param int
298   */
299  public function setTcpTransitoryIdleTimeoutSec($tcpTransitoryIdleTimeoutSec)
300  {
301    $this->tcpTransitoryIdleTimeoutSec = $tcpTransitoryIdleTimeoutSec;
302  }
303  /**
304   * @return int
305   */
306  public function getTcpTransitoryIdleTimeoutSec()
307  {
308    return $this->tcpTransitoryIdleTimeoutSec;
309  }
310  /**
311   * @param int
312   */
313  public function setUdpIdleTimeoutSec($udpIdleTimeoutSec)
314  {
315    $this->udpIdleTimeoutSec = $udpIdleTimeoutSec;
316  }
317  /**
318   * @return int
319   */
320  public function getUdpIdleTimeoutSec()
321  {
322    return $this->udpIdleTimeoutSec;
323  }
324}
325
326// Adding a class alias for backwards compatibility with the previous class name.
327class_alias(RouterNat::class, 'Google_Service_Compute_RouterNat');
328