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 BackendService extends \Google\Collection
21{
22  protected $collection_key = 'localityLbPolicies';
23  /**
24   * @var int
25   */
26  public $affinityCookieTtlSec;
27  protected $backendsType = Backend::class;
28  protected $backendsDataType = 'array';
29  protected $cdnPolicyType = BackendServiceCdnPolicy::class;
30  protected $cdnPolicyDataType = '';
31  protected $circuitBreakersType = CircuitBreakers::class;
32  protected $circuitBreakersDataType = '';
33  protected $connectionDrainingType = ConnectionDraining::class;
34  protected $connectionDrainingDataType = '';
35  protected $connectionTrackingPolicyType = BackendServiceConnectionTrackingPolicy::class;
36  protected $connectionTrackingPolicyDataType = '';
37  protected $consistentHashType = ConsistentHashLoadBalancerSettings::class;
38  protected $consistentHashDataType = '';
39  /**
40   * @var string
41   */
42  public $creationTimestamp;
43  /**
44   * @var string[]
45   */
46  public $customRequestHeaders;
47  /**
48   * @var string[]
49   */
50  public $customResponseHeaders;
51  /**
52   * @var string
53   */
54  public $description;
55  /**
56   * @var string
57   */
58  public $edgeSecurityPolicy;
59  /**
60   * @var bool
61   */
62  public $enableCDN;
63  protected $failoverPolicyType = BackendServiceFailoverPolicy::class;
64  protected $failoverPolicyDataType = '';
65  /**
66   * @var string
67   */
68  public $fingerprint;
69  /**
70   * @var string[]
71   */
72  public $healthChecks;
73  protected $iapType = BackendServiceIAP::class;
74  protected $iapDataType = '';
75  /**
76   * @var string
77   */
78  public $id;
79  /**
80   * @var string
81   */
82  public $kind;
83  /**
84   * @var string
85   */
86  public $loadBalancingScheme;
87  protected $localityLbPoliciesType = BackendServiceLocalityLoadBalancingPolicyConfig::class;
88  protected $localityLbPoliciesDataType = 'array';
89  /**
90   * @var string
91   */
92  public $localityLbPolicy;
93  protected $logConfigType = BackendServiceLogConfig::class;
94  protected $logConfigDataType = '';
95  protected $maxStreamDurationType = Duration::class;
96  protected $maxStreamDurationDataType = '';
97  /**
98   * @var string
99   */
100  public $name;
101  /**
102   * @var string
103   */
104  public $network;
105  protected $outlierDetectionType = OutlierDetection::class;
106  protected $outlierDetectionDataType = '';
107  /**
108   * @var int
109   */
110  public $port;
111  /**
112   * @var string
113   */
114  public $portName;
115  /**
116   * @var string
117   */
118  public $protocol;
119  /**
120   * @var string
121   */
122  public $region;
123  /**
124   * @var string
125   */
126  public $securityPolicy;
127  protected $securitySettingsType = SecuritySettings::class;
128  protected $securitySettingsDataType = '';
129  /**
130   * @var string
131   */
132  public $selfLink;
133  /**
134   * @var string
135   */
136  public $sessionAffinity;
137  protected $subsettingType = Subsetting::class;
138  protected $subsettingDataType = '';
139  /**
140   * @var int
141   */
142  public $timeoutSec;
143
144  /**
145   * @param int
146   */
147  public function setAffinityCookieTtlSec($affinityCookieTtlSec)
148  {
149    $this->affinityCookieTtlSec = $affinityCookieTtlSec;
150  }
151  /**
152   * @return int
153   */
154  public function getAffinityCookieTtlSec()
155  {
156    return $this->affinityCookieTtlSec;
157  }
158  /**
159   * @param Backend[]
160   */
161  public function setBackends($backends)
162  {
163    $this->backends = $backends;
164  }
165  /**
166   * @return Backend[]
167   */
168  public function getBackends()
169  {
170    return $this->backends;
171  }
172  /**
173   * @param BackendServiceCdnPolicy
174   */
175  public function setCdnPolicy(BackendServiceCdnPolicy $cdnPolicy)
176  {
177    $this->cdnPolicy = $cdnPolicy;
178  }
179  /**
180   * @return BackendServiceCdnPolicy
181   */
182  public function getCdnPolicy()
183  {
184    return $this->cdnPolicy;
185  }
186  /**
187   * @param CircuitBreakers
188   */
189  public function setCircuitBreakers(CircuitBreakers $circuitBreakers)
190  {
191    $this->circuitBreakers = $circuitBreakers;
192  }
193  /**
194   * @return CircuitBreakers
195   */
196  public function getCircuitBreakers()
197  {
198    return $this->circuitBreakers;
199  }
200  /**
201   * @param ConnectionDraining
202   */
203  public function setConnectionDraining(ConnectionDraining $connectionDraining)
204  {
205    $this->connectionDraining = $connectionDraining;
206  }
207  /**
208   * @return ConnectionDraining
209   */
210  public function getConnectionDraining()
211  {
212    return $this->connectionDraining;
213  }
214  /**
215   * @param BackendServiceConnectionTrackingPolicy
216   */
217  public function setConnectionTrackingPolicy(BackendServiceConnectionTrackingPolicy $connectionTrackingPolicy)
218  {
219    $this->connectionTrackingPolicy = $connectionTrackingPolicy;
220  }
221  /**
222   * @return BackendServiceConnectionTrackingPolicy
223   */
224  public function getConnectionTrackingPolicy()
225  {
226    return $this->connectionTrackingPolicy;
227  }
228  /**
229   * @param ConsistentHashLoadBalancerSettings
230   */
231  public function setConsistentHash(ConsistentHashLoadBalancerSettings $consistentHash)
232  {
233    $this->consistentHash = $consistentHash;
234  }
235  /**
236   * @return ConsistentHashLoadBalancerSettings
237   */
238  public function getConsistentHash()
239  {
240    return $this->consistentHash;
241  }
242  /**
243   * @param string
244   */
245  public function setCreationTimestamp($creationTimestamp)
246  {
247    $this->creationTimestamp = $creationTimestamp;
248  }
249  /**
250   * @return string
251   */
252  public function getCreationTimestamp()
253  {
254    return $this->creationTimestamp;
255  }
256  /**
257   * @param string[]
258   */
259  public function setCustomRequestHeaders($customRequestHeaders)
260  {
261    $this->customRequestHeaders = $customRequestHeaders;
262  }
263  /**
264   * @return string[]
265   */
266  public function getCustomRequestHeaders()
267  {
268    return $this->customRequestHeaders;
269  }
270  /**
271   * @param string[]
272   */
273  public function setCustomResponseHeaders($customResponseHeaders)
274  {
275    $this->customResponseHeaders = $customResponseHeaders;
276  }
277  /**
278   * @return string[]
279   */
280  public function getCustomResponseHeaders()
281  {
282    return $this->customResponseHeaders;
283  }
284  /**
285   * @param string
286   */
287  public function setDescription($description)
288  {
289    $this->description = $description;
290  }
291  /**
292   * @return string
293   */
294  public function getDescription()
295  {
296    return $this->description;
297  }
298  /**
299   * @param string
300   */
301  public function setEdgeSecurityPolicy($edgeSecurityPolicy)
302  {
303    $this->edgeSecurityPolicy = $edgeSecurityPolicy;
304  }
305  /**
306   * @return string
307   */
308  public function getEdgeSecurityPolicy()
309  {
310    return $this->edgeSecurityPolicy;
311  }
312  /**
313   * @param bool
314   */
315  public function setEnableCDN($enableCDN)
316  {
317    $this->enableCDN = $enableCDN;
318  }
319  /**
320   * @return bool
321   */
322  public function getEnableCDN()
323  {
324    return $this->enableCDN;
325  }
326  /**
327   * @param BackendServiceFailoverPolicy
328   */
329  public function setFailoverPolicy(BackendServiceFailoverPolicy $failoverPolicy)
330  {
331    $this->failoverPolicy = $failoverPolicy;
332  }
333  /**
334   * @return BackendServiceFailoverPolicy
335   */
336  public function getFailoverPolicy()
337  {
338    return $this->failoverPolicy;
339  }
340  /**
341   * @param string
342   */
343  public function setFingerprint($fingerprint)
344  {
345    $this->fingerprint = $fingerprint;
346  }
347  /**
348   * @return string
349   */
350  public function getFingerprint()
351  {
352    return $this->fingerprint;
353  }
354  /**
355   * @param string[]
356   */
357  public function setHealthChecks($healthChecks)
358  {
359    $this->healthChecks = $healthChecks;
360  }
361  /**
362   * @return string[]
363   */
364  public function getHealthChecks()
365  {
366    return $this->healthChecks;
367  }
368  /**
369   * @param BackendServiceIAP
370   */
371  public function setIap(BackendServiceIAP $iap)
372  {
373    $this->iap = $iap;
374  }
375  /**
376   * @return BackendServiceIAP
377   */
378  public function getIap()
379  {
380    return $this->iap;
381  }
382  /**
383   * @param string
384   */
385  public function setId($id)
386  {
387    $this->id = $id;
388  }
389  /**
390   * @return string
391   */
392  public function getId()
393  {
394    return $this->id;
395  }
396  /**
397   * @param string
398   */
399  public function setKind($kind)
400  {
401    $this->kind = $kind;
402  }
403  /**
404   * @return string
405   */
406  public function getKind()
407  {
408    return $this->kind;
409  }
410  /**
411   * @param string
412   */
413  public function setLoadBalancingScheme($loadBalancingScheme)
414  {
415    $this->loadBalancingScheme = $loadBalancingScheme;
416  }
417  /**
418   * @return string
419   */
420  public function getLoadBalancingScheme()
421  {
422    return $this->loadBalancingScheme;
423  }
424  /**
425   * @param BackendServiceLocalityLoadBalancingPolicyConfig[]
426   */
427  public function setLocalityLbPolicies($localityLbPolicies)
428  {
429    $this->localityLbPolicies = $localityLbPolicies;
430  }
431  /**
432   * @return BackendServiceLocalityLoadBalancingPolicyConfig[]
433   */
434  public function getLocalityLbPolicies()
435  {
436    return $this->localityLbPolicies;
437  }
438  /**
439   * @param string
440   */
441  public function setLocalityLbPolicy($localityLbPolicy)
442  {
443    $this->localityLbPolicy = $localityLbPolicy;
444  }
445  /**
446   * @return string
447   */
448  public function getLocalityLbPolicy()
449  {
450    return $this->localityLbPolicy;
451  }
452  /**
453   * @param BackendServiceLogConfig
454   */
455  public function setLogConfig(BackendServiceLogConfig $logConfig)
456  {
457    $this->logConfig = $logConfig;
458  }
459  /**
460   * @return BackendServiceLogConfig
461   */
462  public function getLogConfig()
463  {
464    return $this->logConfig;
465  }
466  /**
467   * @param Duration
468   */
469  public function setMaxStreamDuration(Duration $maxStreamDuration)
470  {
471    $this->maxStreamDuration = $maxStreamDuration;
472  }
473  /**
474   * @return Duration
475   */
476  public function getMaxStreamDuration()
477  {
478    return $this->maxStreamDuration;
479  }
480  /**
481   * @param string
482   */
483  public function setName($name)
484  {
485    $this->name = $name;
486  }
487  /**
488   * @return string
489   */
490  public function getName()
491  {
492    return $this->name;
493  }
494  /**
495   * @param string
496   */
497  public function setNetwork($network)
498  {
499    $this->network = $network;
500  }
501  /**
502   * @return string
503   */
504  public function getNetwork()
505  {
506    return $this->network;
507  }
508  /**
509   * @param OutlierDetection
510   */
511  public function setOutlierDetection(OutlierDetection $outlierDetection)
512  {
513    $this->outlierDetection = $outlierDetection;
514  }
515  /**
516   * @return OutlierDetection
517   */
518  public function getOutlierDetection()
519  {
520    return $this->outlierDetection;
521  }
522  /**
523   * @param int
524   */
525  public function setPort($port)
526  {
527    $this->port = $port;
528  }
529  /**
530   * @return int
531   */
532  public function getPort()
533  {
534    return $this->port;
535  }
536  /**
537   * @param string
538   */
539  public function setPortName($portName)
540  {
541    $this->portName = $portName;
542  }
543  /**
544   * @return string
545   */
546  public function getPortName()
547  {
548    return $this->portName;
549  }
550  /**
551   * @param string
552   */
553  public function setProtocol($protocol)
554  {
555    $this->protocol = $protocol;
556  }
557  /**
558   * @return string
559   */
560  public function getProtocol()
561  {
562    return $this->protocol;
563  }
564  /**
565   * @param string
566   */
567  public function setRegion($region)
568  {
569    $this->region = $region;
570  }
571  /**
572   * @return string
573   */
574  public function getRegion()
575  {
576    return $this->region;
577  }
578  /**
579   * @param string
580   */
581  public function setSecurityPolicy($securityPolicy)
582  {
583    $this->securityPolicy = $securityPolicy;
584  }
585  /**
586   * @return string
587   */
588  public function getSecurityPolicy()
589  {
590    return $this->securityPolicy;
591  }
592  /**
593   * @param SecuritySettings
594   */
595  public function setSecuritySettings(SecuritySettings $securitySettings)
596  {
597    $this->securitySettings = $securitySettings;
598  }
599  /**
600   * @return SecuritySettings
601   */
602  public function getSecuritySettings()
603  {
604    return $this->securitySettings;
605  }
606  /**
607   * @param string
608   */
609  public function setSelfLink($selfLink)
610  {
611    $this->selfLink = $selfLink;
612  }
613  /**
614   * @return string
615   */
616  public function getSelfLink()
617  {
618    return $this->selfLink;
619  }
620  /**
621   * @param string
622   */
623  public function setSessionAffinity($sessionAffinity)
624  {
625    $this->sessionAffinity = $sessionAffinity;
626  }
627  /**
628   * @return string
629   */
630  public function getSessionAffinity()
631  {
632    return $this->sessionAffinity;
633  }
634  /**
635   * @param Subsetting
636   */
637  public function setSubsetting(Subsetting $subsetting)
638  {
639    $this->subsetting = $subsetting;
640  }
641  /**
642   * @return Subsetting
643   */
644  public function getSubsetting()
645  {
646    return $this->subsetting;
647  }
648  /**
649   * @param int
650   */
651  public function setTimeoutSec($timeoutSec)
652  {
653    $this->timeoutSec = $timeoutSec;
654  }
655  /**
656   * @return int
657   */
658  public function getTimeoutSec()
659  {
660    return $this->timeoutSec;
661  }
662}
663
664// Adding a class alias for backwards compatibility with the previous class name.
665class_alias(BackendService::class, 'Google_Service_Compute_BackendService');
666