Send feedback
Class Resource.Builder (2.57.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version latest keyboard_arrow_down
public static final class Resource . Builder extends GeneratedMessageV3 . Builder<Resource . Builder > implements ResourceOrBuilder
An entity that can have metadata. For example, a Docker image.
Protobuf type grafeas.v1beta1.Resource
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()
public static final Descriptors . Descriptor getDescriptor ()
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public Resource . Builder addRepeatedField ( Descriptors . FieldDescriptor field , Object value )
Overrides
build()
buildPartial()
public Resource buildPartial ()
clear()
public Resource . Builder clear ()
Overrides
clearContentHash()
public Resource . Builder clearContentHash ()
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
clearField(Descriptors.FieldDescriptor field)
public Resource . Builder clearField ( Descriptors . FieldDescriptor field )
Overrides
clearName()
public Resource . Builder clearName ()
The name of the resource. For example, the name of a Docker image -
"Debian".
string name = 1;
clearOneof(Descriptors.OneofDescriptor oneof)
public Resource . Builder clearOneof ( Descriptors . OneofDescriptor oneof )
Overrides
clearUri()
public Resource . Builder clearUri ()
clone()
public Resource . Builder clone ()
Overrides
getContentHash()
public Hash getContentHash ()
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
Returns
Type
Description
Hash
The contentHash.
getContentHashBuilder()
public Hash . Builder getContentHashBuilder ()
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
getContentHashOrBuilder()
public HashOrBuilder getContentHashOrBuilder ()
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
getDefaultInstanceForType()
public Resource getDefaultInstanceForType ()
getDescriptorForType()
public Descriptors . Descriptor getDescriptorForType ()
Overrides
getName()
The name of the resource. For example, the name of a Docker image -
"Debian".
string name = 1;
Returns
Type
Description
String
The name.
getNameBytes()
public ByteString getNameBytes ()
The name of the resource. For example, the name of a Docker image -
"Debian".
string name = 1;
Returns
Type
Description
ByteString
The bytes for name.
getUri()
Returns
Type
Description
String
The uri.
getUriBytes()
public ByteString getUriBytes ()
Returns
Type
Description
ByteString
The bytes for uri.
hasContentHash()
public boolean hasContentHash ()
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
Returns
Type
Description
boolean
Whether the contentHash field is set.
internalGetFieldAccessorTable()
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Overrides
isInitialized()
public final boolean isInitialized ()
Overrides
mergeContentHash(Hash value)
public Resource . Builder mergeContentHash ( Hash value )
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
Parameter
Name
Description
value
Hash
public Resource . Builder mergeFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
Overrides
mergeFrom(Message other)
public Resource . Builder mergeFrom ( Message other )
Parameter
Name
Description
other
Message
Overrides
mergeFrom(Resource other)
public Resource . Builder mergeFrom ( Resource other )
Parameter
Name
Description
other
Resource
mergeUnknownFields(UnknownFieldSet unknownFields)
public final Resource . Builder mergeUnknownFields ( UnknownFieldSet unknownFields )
Overrides
setContentHash(Hash value)
public Resource . Builder setContentHash ( Hash value )
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
Parameter
Name
Description
value
Hash
setContentHash(Hash.Builder builderForValue)
public Resource . Builder setContentHash ( Hash . Builder builderForValue )
The hash of the resource content. For example, the Docker digest.
.grafeas.v1beta1.provenance.Hash content_hash = 3;
setField(Descriptors.FieldDescriptor field, Object value)
public Resource . Builder setField ( Descriptors . FieldDescriptor field , Object value )
Overrides
setName(String value)
public Resource . Builder setName ( String value )
The name of the resource. For example, the name of a Docker image -
"Debian".
string name = 1;
Parameter
Name
Description
value
String
The name to set.
setNameBytes(ByteString value)
public Resource . Builder setNameBytes ( ByteString value )
The name of the resource. For example, the name of a Docker image -
"Debian".
string name = 1;
Parameter
Name
Description
value
ByteString
The bytes for name to set.
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public Resource . Builder setRepeatedField ( Descriptors . FieldDescriptor field , int index , Object value )
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final Resource . Builder setUnknownFields ( UnknownFieldSet unknownFields )
Overrides
setUri(String value)
public Resource . Builder setUri ( String value )
Parameter
Name
Description
value
String
The uri to set.
setUriBytes(ByteString value)
public Resource . Builder setUriBytes ( ByteString value )
Parameter
Name
Description
value
ByteString
The bytes for uri to set.
Send feedback
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-01-27 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-01-27 UTC."],[],[]]