Class Version.Builder (2.55.0)

publicstaticfinalclass Version.BuilderextendsGeneratedMessageV3.Builder<Version.Builder>implementsVersionOrBuilder

Version contains structured information about the version of a package.

Protobuf type grafeas.v1beta1.package.Version

Implements

VersionOrBuilder

Inherited Members

com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)
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()

publicstaticfinalDescriptors.DescriptorgetDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

publicVersion.BuilderaddRepeatedField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Version.Builder
Overrides

build()

publicVersionbuild()
Returns
Type Description
Version

buildPartial()

publicVersionbuildPartial()
Returns
Type Description
Version

clear()

publicVersion.Builderclear()
Returns
Type Description
Version.Builder
Overrides

clearEpoch()

publicVersion.BuilderclearEpoch()

Used to correct mistakes in the version numbering scheme.

int32 epoch = 1;

Returns
Type Description
Version.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

publicVersion.BuilderclearField(Descriptors.FieldDescriptorfield)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
Version.Builder
Overrides

clearKind()

publicVersion.BuilderclearKind()

Required. Distinguishes between sentinel MIN/MAX versions and normal versions.

.grafeas.v1beta1.package.Version.VersionKind kind = 4;

Returns
Type Description
Version.Builder

This builder for chaining.

clearName()

publicVersion.BuilderclearName()

Required only when version kind is NORMAL. The main part of the version name.

string name = 2;

Returns
Type Description
Version.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

publicVersion.BuilderclearOneof(Descriptors.OneofDescriptoroneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
Version.Builder
Overrides

clearRevision()

publicVersion.BuilderclearRevision()

The iteration of the package build from the above version.

string revision = 3;

Returns
Type Description
Version.Builder

This builder for chaining.

clone()

publicVersion.Builderclone()
Returns
Type Description
Version.Builder
Overrides

getDefaultInstanceForType()

publicVersiongetDefaultInstanceForType()
Returns
Type Description
Version

getDescriptorForType()

publicDescriptors.DescriptorgetDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getEpoch()

publicintgetEpoch()

Used to correct mistakes in the version numbering scheme.

int32 epoch = 1;

Returns
Type Description
int

The epoch.

getKind()

publicVersion.VersionKindgetKind()

Required. Distinguishes between sentinel MIN/MAX versions and normal versions.

.grafeas.v1beta1.package.Version.VersionKind kind = 4;

Returns
Type Description
Version.VersionKind

The kind.

getKindValue()

publicintgetKindValue()

Required. Distinguishes between sentinel MIN/MAX versions and normal versions.

.grafeas.v1beta1.package.Version.VersionKind kind = 4;

Returns
Type Description
int

The enum numeric value on the wire for kind.

getName()

publicStringgetName()

Required only when version kind is NORMAL. The main part of the version name.

string name = 2;

Returns
Type Description
String

The name.

getNameBytes()

publicByteStringgetNameBytes()

Required only when version kind is NORMAL. The main part of the version name.

string name = 2;

Returns
Type Description
ByteString

The bytes for name.

getRevision()

publicStringgetRevision()

The iteration of the package build from the above version.

string revision = 3;

Returns
Type Description
String

The revision.

getRevisionBytes()

publicByteStringgetRevisionBytes()

The iteration of the package build from the above version.

string revision = 3;

Returns
Type Description
ByteString

The bytes for revision.

internalGetFieldAccessorTable()

protectedGeneratedMessageV3.FieldAccessorTableinternalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

publicfinalbooleanisInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

publicVersion.BuildermergeFrom(CodedInputStreaminput,ExtensionRegistryLiteextensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
Version.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

publicVersion.BuildermergeFrom(Messageother)
Parameter
Name Description
other Message
Returns
Type Description
Version.Builder
Overrides

mergeFrom(Version other)

publicVersion.BuildermergeFrom(Versionother)
Parameter
Name Description
other Version
Returns
Type Description
Version.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

publicfinalVersion.BuildermergeUnknownFields(UnknownFieldSetunknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Version.Builder
Overrides

setEpoch(int value)

publicVersion.BuildersetEpoch(intvalue)

Used to correct mistakes in the version numbering scheme.

int32 epoch = 1;

Parameter
Name Description
value int

The epoch to set.

Returns
Type Description
Version.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

publicVersion.BuildersetField(Descriptors.FieldDescriptorfield,Objectvalue)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
Version.Builder
Overrides

setKind(Version.VersionKind value)

publicVersion.BuildersetKind(Version.VersionKindvalue)

Required. Distinguishes between sentinel MIN/MAX versions and normal versions.

.grafeas.v1beta1.package.Version.VersionKind kind = 4;

Parameter
Name Description
value Version.VersionKind

The kind to set.

Returns
Type Description
Version.Builder

This builder for chaining.

setKindValue(int value)

publicVersion.BuildersetKindValue(intvalue)

Required. Distinguishes between sentinel MIN/MAX versions and normal versions.

.grafeas.v1beta1.package.Version.VersionKind kind = 4;

Parameter
Name Description
value int

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

Returns
Type Description
Version.Builder

This builder for chaining.

setName(String value)

publicVersion.BuildersetName(Stringvalue)

Required only when version kind is NORMAL. The main part of the version name.

string name = 2;

Parameter
Name Description
value String

The name to set.

Returns
Type Description
Version.Builder

This builder for chaining.

setNameBytes(ByteString value)

publicVersion.BuildersetNameBytes(ByteStringvalue)

Required only when version kind is NORMAL. The main part of the version name.

string name = 2;

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
Version.Builder

This builder for chaining.

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

publicVersion.BuildersetRepeatedField(Descriptors.FieldDescriptorfield,intindex,Objectvalue)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
Version.Builder
Overrides

setRevision(String value)

publicVersion.BuildersetRevision(Stringvalue)

The iteration of the package build from the above version.

string revision = 3;

Parameter
Name Description
value String

The revision to set.

Returns
Type Description
Version.Builder

This builder for chaining.

setRevisionBytes(ByteString value)

publicVersion.BuildersetRevisionBytes(ByteStringvalue)

The iteration of the package build from the above version.

string revision = 3;

Parameter
Name Description
value ByteString

The bytes for revision to set.

Returns
Type Description
Version.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

publicfinalVersion.BuildersetUnknownFields(UnknownFieldSetunknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
Version.Builder
Overrides

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年11月19日 UTC.