RouterStatusNatStatusNatRuleStatus.php 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147
  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. namespace Google\Service\Compute;
  18. class RouterStatusNatStatusNatRuleStatus extends \Google\Collection
  19. {
  20. protected $collection_key = 'drainNatIps';
  21. /**
  22. * Output only. A list of active IPs for NAT. Example: ["1.1.1.1",
  23. * "179.12.26.133"].
  24. *
  25. * @var string[]
  26. */
  27. public $activeNatIps;
  28. /**
  29. * Output only. A list of IPs for NAT that are in drain mode. Example:
  30. * ["1.1.1.1", "179.12.26.133"].
  31. *
  32. * @var string[]
  33. */
  34. public $drainNatIps;
  35. /**
  36. * Output only. The number of extra IPs to allocate. This will be greater than
  37. * 0 only if the existing IPs in this NAT Rule are NOT enough to allow all
  38. * configured VMs to use NAT.
  39. *
  40. * @var int
  41. */
  42. public $minExtraIpsNeeded;
  43. /**
  44. * Output only. Number of VM endpoints (i.e., NICs) that have NAT Mappings
  45. * from this NAT Rule.
  46. *
  47. * @var int
  48. */
  49. public $numVmEndpointsWithNatMappings;
  50. /**
  51. * Output only. Rule number of the rule.
  52. *
  53. * @var int
  54. */
  55. public $ruleNumber;
  56. /**
  57. * Output only. A list of active IPs for NAT. Example: ["1.1.1.1",
  58. * "179.12.26.133"].
  59. *
  60. * @param string[] $activeNatIps
  61. */
  62. public function setActiveNatIps($activeNatIps)
  63. {
  64. $this->activeNatIps = $activeNatIps;
  65. }
  66. /**
  67. * @return string[]
  68. */
  69. public function getActiveNatIps()
  70. {
  71. return $this->activeNatIps;
  72. }
  73. /**
  74. * Output only. A list of IPs for NAT that are in drain mode. Example:
  75. * ["1.1.1.1", "179.12.26.133"].
  76. *
  77. * @param string[] $drainNatIps
  78. */
  79. public function setDrainNatIps($drainNatIps)
  80. {
  81. $this->drainNatIps = $drainNatIps;
  82. }
  83. /**
  84. * @return string[]
  85. */
  86. public function getDrainNatIps()
  87. {
  88. return $this->drainNatIps;
  89. }
  90. /**
  91. * Output only. The number of extra IPs to allocate. This will be greater than
  92. * 0 only if the existing IPs in this NAT Rule are NOT enough to allow all
  93. * configured VMs to use NAT.
  94. *
  95. * @param int $minExtraIpsNeeded
  96. */
  97. public function setMinExtraIpsNeeded($minExtraIpsNeeded)
  98. {
  99. $this->minExtraIpsNeeded = $minExtraIpsNeeded;
  100. }
  101. /**
  102. * @return int
  103. */
  104. public function getMinExtraIpsNeeded()
  105. {
  106. return $this->minExtraIpsNeeded;
  107. }
  108. /**
  109. * Output only. Number of VM endpoints (i.e., NICs) that have NAT Mappings
  110. * from this NAT Rule.
  111. *
  112. * @param int $numVmEndpointsWithNatMappings
  113. */
  114. public function setNumVmEndpointsWithNatMappings($numVmEndpointsWithNatMappings)
  115. {
  116. $this->numVmEndpointsWithNatMappings = $numVmEndpointsWithNatMappings;
  117. }
  118. /**
  119. * @return int
  120. */
  121. public function getNumVmEndpointsWithNatMappings()
  122. {
  123. return $this->numVmEndpointsWithNatMappings;
  124. }
  125. /**
  126. * Output only. Rule number of the rule.
  127. *
  128. * @param int $ruleNumber
  129. */
  130. public function setRuleNumber($ruleNumber)
  131. {
  132. $this->ruleNumber = $ruleNumber;
  133. }
  134. /**
  135. * @return int
  136. */
  137. public function getRuleNumber()
  138. {
  139. return $this->ruleNumber;
  140. }
  141. }
  142. // Adding a class alias for backwards compatibility with the previous class name.
  143. class_alias(RouterStatusNatStatusNatRuleStatus::class, 'Google_Service_Compute_RouterStatusNatStatusNatRuleStatus');