Class Package.Builder (2.20.0)

public static final class Package.Builder extends GeneratedMessageV3.Builder<Package.Builder> implements PackageOrBuilder

This represents a particular package that is distributed over various channels. E.g., glibc (aka libc6) is distributed by many, at various versions.

Protobuf type grafeas.v1beta1.package.Package

Implements

PackageOrBuilder

Static Methods

getDescriptor()

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

Methods

addAllDistribution(Iterable<? extends Distribution> values)

public Package.Builder addAllDistribution(Iterable<? extends Distribution> values)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
valuesIterable<? extends io.grafeas.v1beta1.pkg.Distribution>
Returns
TypeDescription
Package.Builder

addDistribution(int index, Distribution value)

public Package.Builder addDistribution(int index, Distribution value)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameters
NameDescription
indexint
valueDistribution
Returns
TypeDescription
Package.Builder

addDistribution(int index, Distribution.Builder builderForValue)

public Package.Builder addDistribution(int index, Distribution.Builder builderForValue)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameters
NameDescription
indexint
builderForValueDistribution.Builder
Returns
TypeDescription
Package.Builder

addDistribution(Distribution value)

public Package.Builder addDistribution(Distribution value)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
valueDistribution
Returns
TypeDescription
Package.Builder

addDistribution(Distribution.Builder builderForValue)

public Package.Builder addDistribution(Distribution.Builder builderForValue)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
builderForValueDistribution.Builder
Returns
TypeDescription
Package.Builder

addDistributionBuilder()

public Distribution.Builder addDistributionBuilder()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
Distribution.Builder

addDistributionBuilder(int index)

public Distribution.Builder addDistributionBuilder(int index)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
indexint
Returns
TypeDescription
Distribution.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public Package build()
Returns
TypeDescription
Package

buildPartial()

public Package buildPartial()
Returns
TypeDescription
Package

clear()

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

clearDistribution()

public Package.Builder clearDistribution()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
Package.Builder

clearField(Descriptors.FieldDescriptor field)

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

clearName()

public Package.Builder clearName()

Required. Immutable. The name of the package.

string name = 1;

Returns
TypeDescription
Package.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

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

clone()

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

getDefaultInstanceForType()

public Package getDefaultInstanceForType()
Returns
TypeDescription
Package

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getDistribution(int index)

public Distribution getDistribution(int index)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
indexint
Returns
TypeDescription
Distribution

getDistributionBuilder(int index)

public Distribution.Builder getDistributionBuilder(int index)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
indexint
Returns
TypeDescription
Distribution.Builder

getDistributionBuilderList()

public List<Distribution.Builder> getDistributionBuilderList()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
List<Builder>

getDistributionCount()

public int getDistributionCount()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
int

getDistributionList()

public List<Distribution> getDistributionList()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
List<Distribution>

getDistributionOrBuilder(int index)

public DistributionOrBuilder getDistributionOrBuilder(int index)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
indexint
Returns
TypeDescription
DistributionOrBuilder

getDistributionOrBuilderList()

public List<? extends DistributionOrBuilder> getDistributionOrBuilderList()

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Returns
TypeDescription
List<? extends io.grafeas.v1beta1.pkg.DistributionOrBuilder>

getName()

public String getName()

Required. Immutable. The name of the package.

string name = 1;

Returns
TypeDescription
String

The name.

getNameBytes()

public ByteString getNameBytes()

Required. Immutable. The name of the package.

string name = 1;

Returns
TypeDescription
ByteString

The bytes for name.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeFrom(Package other)

public Package.Builder mergeFrom(Package other)
Parameter
NameDescription
otherPackage
Returns
TypeDescription
Package.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

removeDistribution(int index)

public Package.Builder removeDistribution(int index)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameter
NameDescription
indexint
Returns
TypeDescription
Package.Builder

setDistribution(int index, Distribution value)

public Package.Builder setDistribution(int index, Distribution value)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameters
NameDescription
indexint
valueDistribution
Returns
TypeDescription
Package.Builder

setDistribution(int index, Distribution.Builder builderForValue)

public Package.Builder setDistribution(int index, Distribution.Builder builderForValue)

The various channels by which a package is distributed.

repeated .grafeas.v1beta1.package.Distribution distribution = 10;

Parameters
NameDescription
indexint
builderForValueDistribution.Builder
Returns
TypeDescription
Package.Builder

setField(Descriptors.FieldDescriptor field, Object value)

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

setName(String value)

public Package.Builder setName(String value)

Required. Immutable. The name of the package.

string name = 1;

Parameter
NameDescription
valueString

The name to set.

Returns
TypeDescription
Package.Builder

This builder for chaining.

setNameBytes(ByteString value)

public Package.Builder setNameBytes(ByteString value)

Required. Immutable. The name of the package.

string name = 1;

Parameter
NameDescription
valueByteString

The bytes for name to set.

Returns
TypeDescription
Package.Builder

This builder for chaining.

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

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

setUnknownFields(UnknownFieldSet unknownFields)

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