public static final class LocationPolicy.Builder extends GeneratedMessageV3.Builder<LocationPolicy.Builder> implements LocationPolicyOrBuilder
Configuration for location policy among multiple possible locations (e.g. preferences for zone selection among zones in a single region).
Protobuf type google.cloud.compute.v1.LocationPolicy
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public LocationPolicy.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public LocationPolicy build()
Returns
buildPartial()
public LocationPolicy buildPartial()
Returns
clear()
public LocationPolicy.Builder clear()
Returns
Overrides
clearField(Descriptors.FieldDescriptor field)
public LocationPolicy.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearLocations()
public LocationPolicy.Builder clearLocations()
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public LocationPolicy.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clone()
public LocationPolicy.Builder clone()
Returns
Overrides
containsLocations(String key)
public boolean containsLocations(String key)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameter
Returns
getDefaultInstanceForType()
public LocationPolicy getDefaultInstanceForType()
Returns
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getLocations()
public Map<String,LocationPolicyLocation> getLocations()
Returns
getLocationsCount()
public int getLocationsCount()
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Returns
getLocationsMap()
public Map<String,LocationPolicyLocation> getLocationsMap()
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Returns
getLocationsOrDefault(String key, LocationPolicyLocation defaultValue)
public LocationPolicyLocation getLocationsOrDefault(String key, LocationPolicyLocation defaultValue)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameters
Returns
getLocationsOrThrow(String key)
public LocationPolicyLocation getLocationsOrThrow(String key)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameter
Returns
getMutableLocations()
public Map<String,LocationPolicyLocation> getMutableLocations()
Use alternate mutation accessors instead.
Returns
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
internalGetMapField(int number)
protected MapField internalGetMapField(int number)
Parameter
Returns
Overrides
internalGetMutableMapField(int number)
protected MapField internalGetMutableMapField(int number)
Parameter
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(LocationPolicy other)
public LocationPolicy.Builder mergeFrom(LocationPolicy other)
Parameter
Returns
public LocationPolicy.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public LocationPolicy.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final LocationPolicy.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
putAllLocations(Map<String,LocationPolicyLocation> values)
public LocationPolicy.Builder putAllLocations(Map<String,LocationPolicyLocation> values)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameter
Returns
putLocations(String key, LocationPolicyLocation value)
public LocationPolicy.Builder putLocations(String key, LocationPolicyLocation value)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameters
Returns
removeLocations(String key)
public LocationPolicy.Builder removeLocations(String key)
Location configurations mapped by location name. Currently only zone names are supported and must be represented as valid internal URLs, such as zones/us-central1-a.
map<string, .google.cloud.compute.v1.LocationPolicyLocation> locations = 413423454;
Parameter
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public LocationPolicy.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public LocationPolicy.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final LocationPolicy.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides