GkeNodePoolTarget.php 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  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\Dataproc;
  18. class GkeNodePoolTarget extends \Google\Collection
  19. {
  20. protected $collection_key = 'roles';
  21. /**
  22. * Required. The target GKE node pool. Format: 'projects/{project}/locations/{
  23. * location}/clusters/{cluster}/nodePools/{node_pool}'
  24. *
  25. * @var string
  26. */
  27. public $nodePool;
  28. protected $nodePoolConfigType = GkeNodePoolConfig::class;
  29. protected $nodePoolConfigDataType = '';
  30. /**
  31. * Required. The roles associated with the GKE node pool.
  32. *
  33. * @var string[]
  34. */
  35. public $roles;
  36. /**
  37. * Required. The target GKE node pool. Format: 'projects/{project}/locations/{
  38. * location}/clusters/{cluster}/nodePools/{node_pool}'
  39. *
  40. * @param string $nodePool
  41. */
  42. public function setNodePool($nodePool)
  43. {
  44. $this->nodePool = $nodePool;
  45. }
  46. /**
  47. * @return string
  48. */
  49. public function getNodePool()
  50. {
  51. return $this->nodePool;
  52. }
  53. /**
  54. * Input only. The configuration for the GKE node pool.If specified, Dataproc
  55. * attempts to create a node pool with the specified shape. If one with the
  56. * same name already exists, it is verified against all specified fields. If a
  57. * field differs, the virtual cluster creation will fail.If omitted, any node
  58. * pool with the specified name is used. If a node pool with the specified
  59. * name does not exist, Dataproc create a node pool with default values.This
  60. * is an input only field. It will not be returned by the API.
  61. *
  62. * @param GkeNodePoolConfig $nodePoolConfig
  63. */
  64. public function setNodePoolConfig(GkeNodePoolConfig $nodePoolConfig)
  65. {
  66. $this->nodePoolConfig = $nodePoolConfig;
  67. }
  68. /**
  69. * @return GkeNodePoolConfig
  70. */
  71. public function getNodePoolConfig()
  72. {
  73. return $this->nodePoolConfig;
  74. }
  75. /**
  76. * Required. The roles associated with the GKE node pool.
  77. *
  78. * @param string[] $roles
  79. */
  80. public function setRoles($roles)
  81. {
  82. $this->roles = $roles;
  83. }
  84. /**
  85. * @return string[]
  86. */
  87. public function getRoles()
  88. {
  89. return $this->roles;
  90. }
  91. }
  92. // Adding a class alias for backwards compatibility with the previous class name.
  93. class_alias(GkeNodePoolTarget::class, 'Google_Service_Dataproc_GkeNodePoolTarget');