Class SetMaintenancePolicyRequest.Builder (2.17.0)

public static final class SetMaintenancePolicyRequest.Builder extends GeneratedMessageV3.Builder<SetMaintenancePolicyRequest.Builder> implements SetMaintenancePolicyRequestOrBuilder

SetMaintenancePolicyRequest sets the maintenance policy for a cluster.

Protobuf type google.container.v1.SetMaintenancePolicyRequest

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SetMaintenancePolicyRequest.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

build()

public SetMaintenancePolicyRequest build()
Returns
TypeDescription
SetMaintenancePolicyRequest

buildPartial()

public SetMaintenancePolicyRequest buildPartial()
Returns
TypeDescription
SetMaintenancePolicyRequest

clear()

public SetMaintenancePolicyRequest.Builder clear()
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

clearClusterId()

public SetMaintenancePolicyRequest.Builder clearClusterId()

Required. The name of the cluster to update.

string cluster_id = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public SetMaintenancePolicyRequest.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

clearMaintenancePolicy()

public SetMaintenancePolicyRequest.Builder clearMaintenancePolicy()

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

clearName()

public SetMaintenancePolicyRequest.Builder clearName()

The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format projects/*/locations/*/clusters/*.

string name = 5;

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public SetMaintenancePolicyRequest.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

clearProjectId()

public SetMaintenancePolicyRequest.Builder clearProjectId()

Required. The Google Developers Console project ID or project number.

string project_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

clearZone()

public SetMaintenancePolicyRequest.Builder clearZone()

Required. The name of the Google Compute Engine zone in which the cluster resides.

string zone = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

clone()

public SetMaintenancePolicyRequest.Builder clone()
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

getClusterId()

public String getClusterId()

Required. The name of the cluster to update.

string cluster_id = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The clusterId.

getClusterIdBytes()

public ByteString getClusterIdBytes()

Required. The name of the cluster to update.

string cluster_id = 3 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for clusterId.

getDefaultInstanceForType()

public SetMaintenancePolicyRequest getDefaultInstanceForType()
Returns
TypeDescription
SetMaintenancePolicyRequest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getMaintenancePolicy()

public MaintenancePolicy getMaintenancePolicy()

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
MaintenancePolicy

The maintenancePolicy.

getMaintenancePolicyBuilder()

public MaintenancePolicy.Builder getMaintenancePolicyBuilder()

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
MaintenancePolicy.Builder

getMaintenancePolicyOrBuilder()

public MaintenancePolicyOrBuilder getMaintenancePolicyOrBuilder()

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
MaintenancePolicyOrBuilder

getName()

public String getName()

The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format projects/*/locations/*/clusters/*.

string name = 5;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format projects/*/locations/*/clusters/*.

string name = 5;

Returns
TypeDescription
ByteString

The bytes for name.

getProjectId()

public String getProjectId()

Required. The Google Developers Console project ID or project number.

string project_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The projectId.

getProjectIdBytes()

public ByteString getProjectIdBytes()

Required. The Google Developers Console project ID or project number.

string project_id = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for projectId.

getZone()

public String getZone()

Required. The name of the Google Compute Engine zone in which the cluster resides.

string zone = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
String

The zone.

getZoneBytes()

public ByteString getZoneBytes()

Required. The name of the Google Compute Engine zone in which the cluster resides.

string zone = 2 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
ByteString

The bytes for zone.

hasMaintenancePolicy()

public boolean hasMaintenancePolicy()

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the maintenancePolicy field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(SetMaintenancePolicyRequest other)

public SetMaintenancePolicyRequest.Builder mergeFrom(SetMaintenancePolicyRequest other)
Parameter
NameDescription
otherSetMaintenancePolicyRequest
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SetMaintenancePolicyRequest.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public SetMaintenancePolicyRequest.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

mergeMaintenancePolicy(MaintenancePolicy value)

public SetMaintenancePolicyRequest.Builder mergeMaintenancePolicy(MaintenancePolicy value)

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueMaintenancePolicy
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SetMaintenancePolicyRequest.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

setClusterId(String value)

public SetMaintenancePolicyRequest.Builder setClusterId(String value)

Required. The name of the cluster to update.

string cluster_id = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The clusterId to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setClusterIdBytes(ByteString value)

public SetMaintenancePolicyRequest.Builder setClusterIdBytes(ByteString value)

Required. The name of the cluster to update.

string cluster_id = 3 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for clusterId to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public SetMaintenancePolicyRequest.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

setMaintenancePolicy(MaintenancePolicy value)

public SetMaintenancePolicyRequest.Builder setMaintenancePolicy(MaintenancePolicy value)

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueMaintenancePolicy
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

setMaintenancePolicy(MaintenancePolicy.Builder builderForValue)

public SetMaintenancePolicyRequest.Builder setMaintenancePolicy(MaintenancePolicy.Builder builderForValue)

Required. The maintenance policy to be set for the cluster. An empty field clears the existing maintenance policy.

.google.container.v1.MaintenancePolicy maintenance_policy = 4 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
builderForValueMaintenancePolicy.Builder
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

setName(String value)

public SetMaintenancePolicyRequest.Builder setName(String value)

The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format projects/*/locations/*/clusters/*.

string name = 5;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setNameBytes(ByteString value)

public SetMaintenancePolicyRequest.Builder setNameBytes(ByteString value)

The name (project, location, cluster name) of the cluster to set maintenance policy. Specified in the format projects/*/locations/*/clusters/*.

string name = 5;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setProjectId(String value)

public SetMaintenancePolicyRequest.Builder setProjectId(String value)

Required. The Google Developers Console project ID or project number.

string project_id = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The projectId to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setProjectIdBytes(ByteString value)

public SetMaintenancePolicyRequest.Builder setProjectIdBytes(ByteString value)

Required. The Google Developers Console project ID or project number.

string project_id = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for projectId to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public SetMaintenancePolicyRequest.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SetMaintenancePolicyRequest.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SetMaintenancePolicyRequest.Builder
Overrides

setZone(String value)

public SetMaintenancePolicyRequest.Builder setZone(String value)

Required. The name of the Google Compute Engine zone in which the cluster resides.

string zone = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueString

The zone to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.

setZoneBytes(ByteString value)

public SetMaintenancePolicyRequest.Builder setZoneBytes(ByteString value)

Required. The name of the Google Compute Engine zone in which the cluster resides.

string zone = 2 [(.google.api.field_behavior) = REQUIRED];

Parameter
NameDescription
valueByteString

The bytes for zone to set.

Returns
TypeDescription
SetMaintenancePolicyRequest.Builder

This builder for chaining.