Starting April 29, 2025, Gemini 1.5 Pro and Gemini 1.5 Flash models are not available in projects that have no prior usage of these models, including new projects. For details, see Model versions and lifecycle.
Optional. Corresponds to the label key of a reservation resource. To target
a SPECIFIC_RESERVATION by name, use
compute.googleapis.com/reservation-name as the key and specify the name
of your reservation as its value.
Optional. Corresponds to the label key of a reservation resource. To target
a SPECIFIC_RESERVATION by name, use
compute.googleapis.com/reservation-name as the key and specify the name
of your reservation as its value.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# Interface ReservationAffinityOrBuilder (1.32.0)\n\n public interface ReservationAffinityOrBuilder extends MessageOrBuilder\n\nImplements\n----------\n\n[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)\n\nMethods\n-------\n\n### getKey()\n\n public abstract String getKey()\n\nOptional. Corresponds to the label key of a reservation resource. To target\na SPECIFIC_RESERVATION by name, use\n`compute.googleapis.com/reservation-name` as the key and specify the name\nof your reservation as its value.\n\n`string key = 2 [(.google.api.field_behavior) = OPTIONAL];`\n\n### getKeyBytes()\n\n public abstract ByteString getKeyBytes()\n\nOptional. Corresponds to the label key of a reservation resource. To target\na SPECIFIC_RESERVATION by name, use\n`compute.googleapis.com/reservation-name` as the key and specify the name\nof your reservation as its value.\n\n`string key = 2 [(.google.api.field_behavior) = OPTIONAL];`\n\n### getReservationAffinityType()\n\n public abstract ReservationAffinity.Type getReservationAffinityType()\n\nRequired. Specifies the reservation affinity type.\n\n`\n.google.cloud.vertexai.v1.ReservationAffinity.Type reservation_affinity_type = 1 [(.google.api.field_behavior) = REQUIRED];\n`\n\n### getReservationAffinityTypeValue()\n\n public abstract int getReservationAffinityTypeValue()\n\nRequired. Specifies the reservation affinity type.\n\n`\n.google.cloud.vertexai.v1.ReservationAffinity.Type reservation_affinity_type = 1 [(.google.api.field_behavior) = REQUIRED];\n`\n\n### getValues(int index)\n\n public abstract String getValues(int index)\n\nOptional. Corresponds to the label values of a reservation resource. This\nmust be the full resource name of the reservation.\n\n`\nrepeated string values = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }\n`\n\n### getValuesBytes(int index)\n\n public abstract ByteString getValuesBytes(int index)\n\nOptional. Corresponds to the label values of a reservation resource. This\nmust be the full resource name of the reservation.\n\n`\nrepeated string values = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }\n`\n\n### getValuesCount()\n\n public abstract int getValuesCount()\n\nOptional. Corresponds to the label values of a reservation resource. This\nmust be the full resource name of the reservation.\n\n`\nrepeated string values = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }\n`\n\n### getValuesList()\n\n public abstract List\u003cString\u003e getValuesList()\n\nOptional. Corresponds to the label values of a reservation resource. This\nmust be the full resource name of the reservation.\n\n`\nrepeated string values = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... }\n`"]]