VmEndpointNatMappingsInterfaceNatMappings.php 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201
  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 VmEndpointNatMappingsInterfaceNatMappings extends \Google\Collection
  19. {
  20. protected $collection_key = 'ruleMappings';
  21. /**
  22. * Output only. List of all drain IP:port-range mappings assigned to this
  23. * interface. These ranges are inclusive, that is, both the first and the last
  24. * ports can be used for NAT. Example: ["2.2.2.2:12345-12355",
  25. * "1.1.1.1:2234-2234"].
  26. *
  27. * @var string[]
  28. */
  29. public $drainNatIpPortRanges;
  30. /**
  31. * Output only. A list of all IP:port-range mappings assigned to this
  32. * interface. These ranges are inclusive, that is, both the first and the last
  33. * ports can be used for NAT. Example: ["2.2.2.2:12345-12355",
  34. * "1.1.1.1:2234-2234"].
  35. *
  36. * @var string[]
  37. */
  38. public $natIpPortRanges;
  39. /**
  40. * Output only. Total number of drain ports across all NAT IPs allocated to
  41. * this interface. It equals to the aggregated port number in the field
  42. * drain_nat_ip_port_ranges.
  43. *
  44. * @var int
  45. */
  46. public $numTotalDrainNatPorts;
  47. /**
  48. * Output only. Total number of ports across all NAT IPs allocated to this
  49. * interface. It equals to the aggregated port number in the field
  50. * nat_ip_port_ranges.
  51. *
  52. * @var int
  53. */
  54. public $numTotalNatPorts;
  55. protected $ruleMappingsType = VmEndpointNatMappingsInterfaceNatMappingsNatRuleMappings::class;
  56. protected $ruleMappingsDataType = 'array';
  57. /**
  58. * Output only. Alias IP range for this interface endpoint. It will be a
  59. * private (RFC 1918) IP range. Examples: "10.33.4.55/32", or
  60. * "192.168.5.0/24".
  61. *
  62. * @var string
  63. */
  64. public $sourceAliasIpRange;
  65. /**
  66. * Output only. Primary IP of the VM for this NIC.
  67. *
  68. * @var string
  69. */
  70. public $sourceVirtualIp;
  71. /**
  72. * Output only. List of all drain IP:port-range mappings assigned to this
  73. * interface. These ranges are inclusive, that is, both the first and the last
  74. * ports can be used for NAT. Example: ["2.2.2.2:12345-12355",
  75. * "1.1.1.1:2234-2234"].
  76. *
  77. * @param string[] $drainNatIpPortRanges
  78. */
  79. public function setDrainNatIpPortRanges($drainNatIpPortRanges)
  80. {
  81. $this->drainNatIpPortRanges = $drainNatIpPortRanges;
  82. }
  83. /**
  84. * @return string[]
  85. */
  86. public function getDrainNatIpPortRanges()
  87. {
  88. return $this->drainNatIpPortRanges;
  89. }
  90. /**
  91. * Output only. A list of all IP:port-range mappings assigned to this
  92. * interface. These ranges are inclusive, that is, both the first and the last
  93. * ports can be used for NAT. Example: ["2.2.2.2:12345-12355",
  94. * "1.1.1.1:2234-2234"].
  95. *
  96. * @param string[] $natIpPortRanges
  97. */
  98. public function setNatIpPortRanges($natIpPortRanges)
  99. {
  100. $this->natIpPortRanges = $natIpPortRanges;
  101. }
  102. /**
  103. * @return string[]
  104. */
  105. public function getNatIpPortRanges()
  106. {
  107. return $this->natIpPortRanges;
  108. }
  109. /**
  110. * Output only. Total number of drain ports across all NAT IPs allocated to
  111. * this interface. It equals to the aggregated port number in the field
  112. * drain_nat_ip_port_ranges.
  113. *
  114. * @param int $numTotalDrainNatPorts
  115. */
  116. public function setNumTotalDrainNatPorts($numTotalDrainNatPorts)
  117. {
  118. $this->numTotalDrainNatPorts = $numTotalDrainNatPorts;
  119. }
  120. /**
  121. * @return int
  122. */
  123. public function getNumTotalDrainNatPorts()
  124. {
  125. return $this->numTotalDrainNatPorts;
  126. }
  127. /**
  128. * Output only. Total number of ports across all NAT IPs allocated to this
  129. * interface. It equals to the aggregated port number in the field
  130. * nat_ip_port_ranges.
  131. *
  132. * @param int $numTotalNatPorts
  133. */
  134. public function setNumTotalNatPorts($numTotalNatPorts)
  135. {
  136. $this->numTotalNatPorts = $numTotalNatPorts;
  137. }
  138. /**
  139. * @return int
  140. */
  141. public function getNumTotalNatPorts()
  142. {
  143. return $this->numTotalNatPorts;
  144. }
  145. /**
  146. * Output only. Information about mappings provided by rules in this NAT.
  147. *
  148. * @param VmEndpointNatMappingsInterfaceNatMappingsNatRuleMappings[] $ruleMappings
  149. */
  150. public function setRuleMappings($ruleMappings)
  151. {
  152. $this->ruleMappings = $ruleMappings;
  153. }
  154. /**
  155. * @return VmEndpointNatMappingsInterfaceNatMappingsNatRuleMappings[]
  156. */
  157. public function getRuleMappings()
  158. {
  159. return $this->ruleMappings;
  160. }
  161. /**
  162. * Output only. Alias IP range for this interface endpoint. It will be a
  163. * private (RFC 1918) IP range. Examples: "10.33.4.55/32", or
  164. * "192.168.5.0/24".
  165. *
  166. * @param string $sourceAliasIpRange
  167. */
  168. public function setSourceAliasIpRange($sourceAliasIpRange)
  169. {
  170. $this->sourceAliasIpRange = $sourceAliasIpRange;
  171. }
  172. /**
  173. * @return string
  174. */
  175. public function getSourceAliasIpRange()
  176. {
  177. return $this->sourceAliasIpRange;
  178. }
  179. /**
  180. * Output only. Primary IP of the VM for this NIC.
  181. *
  182. * @param string $sourceVirtualIp
  183. */
  184. public function setSourceVirtualIp($sourceVirtualIp)
  185. {
  186. $this->sourceVirtualIp = $sourceVirtualIp;
  187. }
  188. /**
  189. * @return string
  190. */
  191. public function getSourceVirtualIp()
  192. {
  193. return $this->sourceVirtualIp;
  194. }
  195. }
  196. // Adding a class alias for backwards compatibility with the previous class name.
  197. class_alias(VmEndpointNatMappingsInterfaceNatMappings::class, 'Google_Service_Compute_VmEndpointNatMappingsInterfaceNatMappings');