Class ResourceManifest.Builder (1.11.0)

public static final class ResourceManifest.Builder extends GeneratedMessageV3.Builder<ResourceManifest.Builder> implements ResourceManifestOrBuilder

ResourceManifest represents a single Kubernetes resource to be applied to the cluster.

Protobuf type google.cloud.gkehub.v1.ResourceManifest

Static Methods

getDescriptor()

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

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public ResourceManifest build()
Returns
TypeDescription
ResourceManifest

buildPartial()

public ResourceManifest buildPartial()
Returns
TypeDescription
ResourceManifest

clear()

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

clearClusterScoped()

public ResourceManifest.Builder clearClusterScoped()

Whether the resource provided in the manifest is cluster_scoped. If unset, the manifest is assumed to be namespace scoped. This field is used for REST mapping when applying the resource in a cluster.

bool cluster_scoped = 2;

Returns
TypeDescription
ResourceManifest.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

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

clearManifest()

public ResourceManifest.Builder clearManifest()

YAML manifest of the resource.

string manifest = 1;

Returns
TypeDescription
ResourceManifest.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getClusterScoped()

public boolean getClusterScoped()

Whether the resource provided in the manifest is cluster_scoped. If unset, the manifest is assumed to be namespace scoped. This field is used for REST mapping when applying the resource in a cluster.

bool cluster_scoped = 2;

Returns
TypeDescription
boolean

The clusterScoped.

getDefaultInstanceForType()

public ResourceManifest getDefaultInstanceForType()
Returns
TypeDescription
ResourceManifest

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getManifest()

public String getManifest()

YAML manifest of the resource.

string manifest = 1;

Returns
TypeDescription
String

The manifest.

getManifestBytes()

public ByteString getManifestBytes()

YAML manifest of the resource.

string manifest = 1;

Returns
TypeDescription
ByteString

The bytes for manifest.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(ResourceManifest other)

public ResourceManifest.Builder mergeFrom(ResourceManifest other)
Parameter
NameDescription
otherResourceManifest
Returns
TypeDescription
ResourceManifest.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setClusterScoped(boolean value)

public ResourceManifest.Builder setClusterScoped(boolean value)

Whether the resource provided in the manifest is cluster_scoped. If unset, the manifest is assumed to be namespace scoped. This field is used for REST mapping when applying the resource in a cluster.

bool cluster_scoped = 2;

Parameter
NameDescription
valueboolean

The clusterScoped to set.

Returns
TypeDescription
ResourceManifest.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

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

setManifest(String value)

public ResourceManifest.Builder setManifest(String value)

YAML manifest of the resource.

string manifest = 1;

Parameter
NameDescription
valueString

The manifest to set.

Returns
TypeDescription
ResourceManifest.Builder

This builder for chaining.

setManifestBytes(ByteString value)

public ResourceManifest.Builder setManifestBytes(ByteString value)

YAML manifest of the resource.

string manifest = 1;

Parameter
NameDescription
valueByteString

The bytes for manifest to set.

Returns
TypeDescription
ResourceManifest.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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