target.apidocs.com.google.api.services.compute.model.ReservationAffinity.html Maven / Gradle / Ivy
ReservationAffinity (Compute Engine API alpha-rev20200526-1.30.9)
com.google.api.services.compute.model
Class ReservationAffinity
- java.lang.Object
-
- java.util.AbstractMap<String,Object>
-
- com.google.api.client.util.GenericData
-
- com.google.api.client.json.GenericJson
-
- com.google.api.services.compute.model.ReservationAffinity
-
public final class ReservationAffinity
extends GenericJson
Specifies the reservations that this instance can consume from.
This is the Java data model class that specifies how to parse/serialize into the JSON that is
transmitted over HTTP when working with the Compute Engine API. For a detailed explanation see:
https://developers.google.com/api-client-library/java/google-http-java-client/json
- Author:
- Google, Inc.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.api.client.util.GenericData
GenericData.Flags
-
Nested classes/interfaces inherited from class java.util.AbstractMap
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
-
Constructor Summary
Constructors
Constructor and Description
ReservationAffinity()
-
Method Summary
All Methods Instance Methods Concrete Methods
Modifier and Type
Method and Description
ReservationAffinity
clone()
String
getConsumeReservationType()
Specifies the type of reservation from which this instance can consume resources:
ANY_RESERVATION (default), SPECIFIC_RESERVATION, or NO_RESERVATION.
String
getKey()
Corresponds to the label key of a reservation resource.
List<String>
getValues()
Corresponds to the label values of a reservation resource.
ReservationAffinity
set(String fieldName,
Object value)
ReservationAffinity
setConsumeReservationType(String consumeReservationType)
Specifies the type of reservation from which this instance can consume resources:
ANY_RESERVATION (default), SPECIFIC_RESERVATION, or NO_RESERVATION.
ReservationAffinity
setKey(String key)
Corresponds to the label key of a reservation resource.
ReservationAffinity
setValues(List<String> values)
Corresponds to the label values of a reservation resource.
-
Methods inherited from class com.google.api.client.json.GenericJson
getFactory, setFactory, toPrettyString, toString
-
Methods inherited from class com.google.api.client.util.GenericData
entrySet, equals, get, getClassInfo, getUnknownKeys, hashCode, put, putAll, remove, setUnknownKeys
-
Methods inherited from class java.util.AbstractMap
clear, containsKey, containsValue, isEmpty, keySet, size, values
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
-
Method Detail
-
getConsumeReservationType
public String getConsumeReservationType()
Specifies the type of reservation from which this instance can consume resources:
ANY_RESERVATION (default), SPECIFIC_RESERVATION, or NO_RESERVATION. See Consuming reserved
instances for examples.
- Returns:
- value or
null
for none
-
setConsumeReservationType
public ReservationAffinity setConsumeReservationType(String consumeReservationType)
Specifies the type of reservation from which this instance can consume resources:
ANY_RESERVATION (default), SPECIFIC_RESERVATION, or NO_RESERVATION. See Consuming reserved
instances for examples.
- Parameters:
consumeReservationType
- consumeReservationType or null
for none
-
getKey
public String getKey()
Corresponds to the label key of a reservation resource. To target a SPECIFIC_RESERVATION by
name, specify googleapis.com/reservation-name as the key and specify the name of your
reservation as its value.
- Returns:
- value or
null
for none
-
setKey
public ReservationAffinity setKey(String key)
Corresponds to the label key of a reservation resource. To target a SPECIFIC_RESERVATION by
name, specify googleapis.com/reservation-name as the key and specify the name of your
reservation as its value.
- Parameters:
key
- key or null
for none
-
getValues
public List<String> getValues()
Corresponds to the label values of a reservation resource.
- Returns:
- value or
null
for none
-
setValues
public ReservationAffinity setValues(List<String> values)
Corresponds to the label values of a reservation resource.
- Parameters:
values
- values or null
for none
-
set
public ReservationAffinity set(String fieldName,
Object value)
- Overrides:
set
in class GenericJson
-
clone
public ReservationAffinity clone()
- Overrides:
clone
in class GenericJson
Copyright © 2011–2020 Google. All rights reserved.
© 2015 - 2025 Weber Informatics LLC | Privacy Policy