Class PatchJobs.AptSettings.Builder (2.25.0)

public static final class PatchJobs.AptSettings.Builder extends GeneratedMessageV3.Builder<PatchJobs.AptSettings.Builder> implements PatchJobs.AptSettingsOrBuilder

Apt patching is completed by executing apt-get update && apt-get upgrade. Additional options can be set to control how this is executed.

Protobuf type google.cloud.osconfig.v1beta.AptSettings

Static Methods

getDescriptor()

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

Methods

addAllExcludes(Iterable<String> values)

public PatchJobs.AptSettings.Builder addAllExcludes(Iterable<String> values)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameter
NameDescription
valuesIterable<String>

The excludes to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addAllExclusivePackages(Iterable<String> values)

public PatchJobs.AptSettings.Builder addAllExclusivePackages(Iterable<String> values)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameter
NameDescription
valuesIterable<String>

The exclusivePackages to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addExcludes(String value)

public PatchJobs.AptSettings.Builder addExcludes(String value)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameter
NameDescription
valueString

The excludes to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addExcludesBytes(ByteString value)

public PatchJobs.AptSettings.Builder addExcludesBytes(ByteString value)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameter
NameDescription
valueByteString

The bytes of the excludes to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addExclusivePackages(String value)

public PatchJobs.AptSettings.Builder addExclusivePackages(String value)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameter
NameDescription
valueString

The exclusivePackages to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addExclusivePackagesBytes(ByteString value)

public PatchJobs.AptSettings.Builder addExclusivePackagesBytes(ByteString value)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameter
NameDescription
valueByteString

The bytes of the exclusivePackages to add.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public PatchJobs.AptSettings build()
Returns
TypeDescription
PatchJobs.AptSettings

buildPartial()

public PatchJobs.AptSettings buildPartial()
Returns
TypeDescription
PatchJobs.AptSettings

clear()

public PatchJobs.AptSettings.Builder clear()
Returns
TypeDescription
PatchJobs.AptSettings.Builder
Overrides

clearExcludes()

public PatchJobs.AptSettings.Builder clearExcludes()

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

clearExclusivePackages()

public PatchJobs.AptSettings.Builder clearExclusivePackages()

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearType()

public PatchJobs.AptSettings.Builder clearType()

By changing the type to DIST, the patching is performed using apt-get dist-upgrade instead.

.google.cloud.osconfig.v1beta.AptSettings.Type type = 1;

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

clone()

public PatchJobs.AptSettings.Builder clone()
Returns
TypeDescription
PatchJobs.AptSettings.Builder
Overrides

getDefaultInstanceForType()

public PatchJobs.AptSettings getDefaultInstanceForType()
Returns
TypeDescription
PatchJobs.AptSettings

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getExcludes(int index)

public String getExcludes(int index)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The excludes at the given index.

getExcludesBytes(int index)

public ByteString getExcludesBytes(int index)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the excludes at the given index.

getExcludesCount()

public int getExcludesCount()

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Returns
TypeDescription
int

The count of excludes.

getExcludesList()

public ProtocolStringList getExcludesList()

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Returns
TypeDescription
ProtocolStringList

A list containing the excludes.

getExclusivePackages(int index)

public String getExclusivePackages(int index)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
String

The exclusivePackages at the given index.

getExclusivePackagesBytes(int index)

public ByteString getExclusivePackagesBytes(int index)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
ByteString

The bytes of the exclusivePackages at the given index.

getExclusivePackagesCount()

public int getExclusivePackagesCount()

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Returns
TypeDescription
int

The count of exclusivePackages.

getExclusivePackagesList()

public ProtocolStringList getExclusivePackagesList()

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Returns
TypeDescription
ProtocolStringList

A list containing the exclusivePackages.

getType()

public PatchJobs.AptSettings.Type getType()

By changing the type to DIST, the patching is performed using apt-get dist-upgrade instead.

.google.cloud.osconfig.v1beta.AptSettings.Type type = 1;

Returns
TypeDescription
PatchJobs.AptSettings.Type

The type.

getTypeValue()

public int getTypeValue()

By changing the type to DIST, the patching is performed using apt-get dist-upgrade instead.

.google.cloud.osconfig.v1beta.AptSettings.Type type = 1;

Returns
TypeDescription
int

The enum numeric value on the wire for type.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(PatchJobs.AptSettings other)

public PatchJobs.AptSettings.Builder mergeFrom(PatchJobs.AptSettings other)
Parameter
NameDescription
otherPatchJobs.AptSettings
Returns
TypeDescription
PatchJobs.AptSettings.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setExcludes(int index, String value)

public PatchJobs.AptSettings.Builder setExcludes(int index, String value)

List of packages to exclude from update. These packages will be excluded

repeated string excludes = 2;

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The excludes to set.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

setExclusivePackages(int index, String value)

public PatchJobs.AptSettings.Builder setExclusivePackages(int index, String value)

An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.

repeated string exclusive_packages = 3;

Parameters
NameDescription
indexint

The index to set the value at.

valueString

The exclusivePackages to set.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

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

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

setType(PatchJobs.AptSettings.Type value)

public PatchJobs.AptSettings.Builder setType(PatchJobs.AptSettings.Type value)

By changing the type to DIST, the patching is performed using apt-get dist-upgrade instead.

.google.cloud.osconfig.v1beta.AptSettings.Type type = 1;

Parameter
NameDescription
valuePatchJobs.AptSettings.Type

The type to set.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

setTypeValue(int value)

public PatchJobs.AptSettings.Builder setTypeValue(int value)

By changing the type to DIST, the patching is performed using apt-get dist-upgrade instead.

.google.cloud.osconfig.v1beta.AptSettings.Type type = 1;

Parameter
NameDescription
valueint

The enum numeric value on the wire for type to set.

Returns
TypeDescription
PatchJobs.AptSettings.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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