public static final class AllocationPolicy.InstancePolicyOrTemplate.Builder extends GeneratedMessageV3.Builder<AllocationPolicy.InstancePolicyOrTemplate.Builder> implements AllocationPolicy.InstancePolicyOrTemplateOrBuilder
Either an InstancePolicy or an instance template.
Protobuf type google.cloud.batch.v1.AllocationPolicy.InstancePolicyOrTemplate
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public AllocationPolicy.InstancePolicyOrTemplate build()
Returns
buildPartial()
public AllocationPolicy.InstancePolicyOrTemplate buildPartial()
Returns
clear()
public AllocationPolicy.InstancePolicyOrTemplate.Builder clear()
Returns
Overrides
clearField(Descriptors.FieldDescriptor field)
public AllocationPolicy.InstancePolicyOrTemplate.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearInstanceTemplate()
public AllocationPolicy.InstancePolicyOrTemplate.Builder clearInstanceTemplate()
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Returns
clearOneof(Descriptors.OneofDescriptor oneof)
public AllocationPolicy.InstancePolicyOrTemplate.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearPolicy()
public AllocationPolicy.InstancePolicyOrTemplate.Builder clearPolicy()
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Returns
clearPolicyTemplate()
public AllocationPolicy.InstancePolicyOrTemplate.Builder clearPolicyTemplate()
Returns
clone()
public AllocationPolicy.InstancePolicyOrTemplate.Builder clone()
Returns
Overrides
getDefaultInstanceForType()
public AllocationPolicy.InstancePolicyOrTemplate getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getInstanceTemplate()
public String getInstanceTemplate()
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Returns
Type |
Description |
String |
The instanceTemplate.
|
getInstanceTemplateBytes()
public ByteString getInstanceTemplateBytes()
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Returns
Type |
Description |
ByteString |
The bytes for instanceTemplate.
|
getPolicy()
public AllocationPolicy.InstancePolicy getPolicy()
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Returns
getPolicyBuilder()
public AllocationPolicy.InstancePolicy.Builder getPolicyBuilder()
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Returns
getPolicyOrBuilder()
public AllocationPolicy.InstancePolicyOrBuilder getPolicyOrBuilder()
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Returns
getPolicyTemplateCase()
public AllocationPolicy.InstancePolicyOrTemplate.PolicyTemplateCase getPolicyTemplateCase()
Returns
hasInstanceTemplate()
public boolean hasInstanceTemplate()
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Returns
Type |
Description |
boolean |
Whether the instanceTemplate field is set.
|
hasPolicy()
public boolean hasPolicy()
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Returns
Type |
Description |
boolean |
Whether the policy field is set.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(AllocationPolicy.InstancePolicyOrTemplate other)
public AllocationPolicy.InstancePolicyOrTemplate.Builder mergeFrom(AllocationPolicy.InstancePolicyOrTemplate other)
Parameter
Returns
public AllocationPolicy.InstancePolicyOrTemplate.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public AllocationPolicy.InstancePolicyOrTemplate.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergePolicy(AllocationPolicy.InstancePolicy value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder mergePolicy(AllocationPolicy.InstancePolicy value)
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Parameter
Returns
mergeUnknownFields(UnknownFieldSet unknownFields)
public final AllocationPolicy.InstancePolicyOrTemplate.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setField(Descriptors.FieldDescriptor field, Object value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setInstanceTemplate(String value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setInstanceTemplate(String value)
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Parameter
Name |
Description |
value |
String
The instanceTemplate to set.
|
Returns
setInstanceTemplateBytes(ByteString value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setInstanceTemplateBytes(ByteString value)
Name of an instance template used to create VMs.
Named the field as 'instance_template' instead of 'template' to avoid
c++ keyword conflict.
string instance_template = 2;
Parameter
Name |
Description |
value |
ByteString
The bytes for instanceTemplate to set.
|
Returns
setPolicy(AllocationPolicy.InstancePolicy value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setPolicy(AllocationPolicy.InstancePolicy value)
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Parameter
Returns
setPolicy(AllocationPolicy.InstancePolicy.Builder builderForValue)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setPolicy(AllocationPolicy.InstancePolicy.Builder builderForValue)
InstancePolicy.
.google.cloud.batch.v1.AllocationPolicy.InstancePolicy policy = 1;
Parameter
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public AllocationPolicy.InstancePolicyOrTemplate.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final AllocationPolicy.InstancePolicyOrTemplate.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides