/* * Copyright 2019 The Grafeas Authors. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ // Generated by the protocol buffer compiler. DO NOT EDIT! // source: grafeas/v1/attestation.proto package io.grafeas.v1; /** * * *
* Occurrence that represents a single "attestation". The authenticity of an * attestation can be verified using the attached signature. If the verifier * trusts the public key of the signer, then verifying the signature is * sufficient to establish trust. In this circumstance, the authority to which * this attestation is attached is primarily useful for lookup (how to find * this attestation if you already know the authority and artifact to be * verified) and intent (for which authority this attestation was intended to * sign. ** * Protobuf type {@code grafeas.v1.AttestationOccurrence} */ public final class AttestationOccurrence extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:grafeas.v1.AttestationOccurrence) AttestationOccurrenceOrBuilder { private static final long serialVersionUID = 0L; // Use AttestationOccurrence.newBuilder() to construct. private AttestationOccurrence(com.google.protobuf.GeneratedMessageV3.Builder> builder) { super(builder); } private AttestationOccurrence() { serializedPayload_ = com.google.protobuf.ByteString.EMPTY; signatures_ = java.util.Collections.emptyList(); jwts_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new AttestationOccurrence(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return io.grafeas.v1.Attestation.internal_static_grafeas_v1_AttestationOccurrence_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return io.grafeas.v1.Attestation .internal_static_grafeas_v1_AttestationOccurrence_fieldAccessorTable .ensureFieldAccessorsInitialized( io.grafeas.v1.AttestationOccurrence.class, io.grafeas.v1.AttestationOccurrence.Builder.class); } public static final int SERIALIZED_PAYLOAD_FIELD_NUMBER = 1; private com.google.protobuf.ByteString serializedPayload_ = com.google.protobuf.ByteString.EMPTY; /** * * *
* Required. The serialized payload that is verified by one or more * `signatures`. ** *
bytes serialized_payload = 1;
*
* @return The serializedPayload.
*/
@java.lang.Override
public com.google.protobuf.ByteString getSerializedPayload() {
return serializedPayload_;
}
public static final int SIGNATURES_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List* One or more signatures over `serialized_payload`. Verifier implementations * should consider this attestation message verified if at least one * `signature` verifies `serialized_payload`. See `Signature` in common.proto * for more details on signature structure and verification. ** *
repeated .grafeas.v1.Signature signatures = 2;
*/
@java.lang.Override
public java.util.List* One or more signatures over `serialized_payload`. Verifier implementations * should consider this attestation message verified if at least one * `signature` verifies `serialized_payload`. See `Signature` in common.proto * for more details on signature structure and verification. ** *
repeated .grafeas.v1.Signature signatures = 2;
*/
@java.lang.Override
public java.util.List extends io.grafeas.v1.SignatureOrBuilder> getSignaturesOrBuilderList() {
return signatures_;
}
/**
*
*
* * One or more signatures over `serialized_payload`. Verifier implementations * should consider this attestation message verified if at least one * `signature` verifies `serialized_payload`. See `Signature` in common.proto * for more details on signature structure and verification. ** *
repeated .grafeas.v1.Signature signatures = 2;
*/
@java.lang.Override
public int getSignaturesCount() {
return signatures_.size();
}
/**
*
*
* * One or more signatures over `serialized_payload`. Verifier implementations * should consider this attestation message verified if at least one * `signature` verifies `serialized_payload`. See `Signature` in common.proto * for more details on signature structure and verification. ** *
repeated .grafeas.v1.Signature signatures = 2;
*/
@java.lang.Override
public io.grafeas.v1.Signature getSignatures(int index) {
return signatures_.get(index);
}
/**
*
*
* * One or more signatures over `serialized_payload`. Verifier implementations * should consider this attestation message verified if at least one * `signature` verifies `serialized_payload`. See `Signature` in common.proto * for more details on signature structure and verification. ** *
repeated .grafeas.v1.Signature signatures = 2;
*/
@java.lang.Override
public io.grafeas.v1.SignatureOrBuilder getSignaturesOrBuilder(int index) {
return signatures_.get(index);
}
public static final int JWTS_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private java.util.List* One or more JWTs encoding a self-contained attestation. * Each JWT encodes the payload that it verifies within the JWT itself. * Verifier implementation SHOULD ignore the `serialized_payload` field * when verifying these JWTs. * If only JWTs are present on this AttestationOccurrence, then the * `serialized_payload` SHOULD be left empty. * Each JWT SHOULD encode a claim specific to the `resource_uri` of this * Occurrence, but this is not validated by Grafeas metadata API * implementations. The JWT itself is opaque to Grafeas. ** *
repeated .grafeas.v1.Jwt jwts = 3;
*/
@java.lang.Override
public java.util.List* One or more JWTs encoding a self-contained attestation. * Each JWT encodes the payload that it verifies within the JWT itself. * Verifier implementation SHOULD ignore the `serialized_payload` field * when verifying these JWTs. * If only JWTs are present on this AttestationOccurrence, then the * `serialized_payload` SHOULD be left empty. * Each JWT SHOULD encode a claim specific to the `resource_uri` of this * Occurrence, but this is not validated by Grafeas metadata API * implementations. The JWT itself is opaque to Grafeas. ** *
repeated .grafeas.v1.Jwt jwts = 3;
*/
@java.lang.Override
public java.util.List extends io.grafeas.v1.JwtOrBuilder> getJwtsOrBuilderList() {
return jwts_;
}
/**
*
*
* * One or more JWTs encoding a self-contained attestation. * Each JWT encodes the payload that it verifies within the JWT itself. * Verifier implementation SHOULD ignore the `serialized_payload` field * when verifying these JWTs. * If only JWTs are present on this AttestationOccurrence, then the * `serialized_payload` SHOULD be left empty. * Each JWT SHOULD encode a claim specific to the `resource_uri` of this * Occurrence, but this is not validated by Grafeas metadata API * implementations. The JWT itself is opaque to Grafeas. ** *
repeated .grafeas.v1.Jwt jwts = 3;
*/
@java.lang.Override
public int getJwtsCount() {
return jwts_.size();
}
/**
*
*
* * One or more JWTs encoding a self-contained attestation. * Each JWT encodes the payload that it verifies within the JWT itself. * Verifier implementation SHOULD ignore the `serialized_payload` field * when verifying these JWTs. * If only JWTs are present on this AttestationOccurrence, then the * `serialized_payload` SHOULD be left empty. * Each JWT SHOULD encode a claim specific to the `resource_uri` of this * Occurrence, but this is not validated by Grafeas metadata API * implementations. The JWT itself is opaque to Grafeas. ** *
repeated .grafeas.v1.Jwt jwts = 3;
*/
@java.lang.Override
public io.grafeas.v1.Jwt getJwts(int index) {
return jwts_.get(index);
}
/**
*
*
* * One or more JWTs encoding a self-contained attestation. * Each JWT encodes the payload that it verifies within the JWT itself. * Verifier implementation SHOULD ignore the `serialized_payload` field * when verifying these JWTs. * If only JWTs are present on this AttestationOccurrence, then the * `serialized_payload` SHOULD be left empty. * Each JWT SHOULD encode a claim specific to the `resource_uri` of this * Occurrence, but this is not validated by Grafeas metadata API * implementations. The JWT itself is opaque to Grafeas. ** *
repeated .grafeas.v1.Jwt jwts = 3;
*/
@java.lang.Override
public io.grafeas.v1.JwtOrBuilder getJwtsOrBuilder(int index) {
return jwts_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
if (!serializedPayload_.isEmpty()) {
output.writeBytes(1, serializedPayload_);
}
for (int i = 0; i < signatures_.size(); i++) {
output.writeMessage(2, signatures_.get(i));
}
for (int i = 0; i < jwts_.size(); i++) {
output.writeMessage(3, jwts_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!serializedPayload_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream.computeBytesSize(1, serializedPayload_);
}
for (int i = 0; i < signatures_.size(); i++) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, signatures_.get(i));
}
for (int i = 0; i < jwts_.size(); i++) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, jwts_.get(i));
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.grafeas.v1.AttestationOccurrence)) {
return super.equals(obj);
}
io.grafeas.v1.AttestationOccurrence other = (io.grafeas.v1.AttestationOccurrence) obj;
if (!getSerializedPayload().equals(other.getSerializedPayload())) return false;
if (!getSignaturesList().equals(other.getSignaturesList())) return false;
if (!getJwtsList().equals(other.getJwtsList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SERIALIZED_PAYLOAD_FIELD_NUMBER;
hash = (53 * hash) + getSerializedPayload().hashCode();
if (getSignaturesCount() > 0) {
hash = (37 * hash) + SIGNATURES_FIELD_NUMBER;
hash = (53 * hash) + getSignaturesList().hashCode();
}
if (getJwtsCount() > 0) {
hash = (37 * hash) + JWTS_FIELD_NUMBER;
hash = (53 * hash) + getJwtsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
PARSER, input, extensionRegistry);
}
public static io.grafeas.v1.AttestationOccurrence parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
}
public static io.grafeas.v1.AttestationOccurrence parseDelimitedFrom(
java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
PARSER, input, extensionRegistry);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
com.google.protobuf.CodedInputStream input) throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static io.grafeas.v1.AttestationOccurrence parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() {
return newBuilder();
}
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.grafeas.v1.AttestationOccurrence prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
*
* * Occurrence that represents a single "attestation". The authenticity of an * attestation can be verified using the attached signature. If the verifier * trusts the public key of the signer, then verifying the signature is * sufficient to establish trust. In this circumstance, the authority to which * this attestation is attached is primarily useful for lookup (how to find * this attestation if you already know the authority and artifact to be * verified) and intent (for which authority this attestation was intended to * sign. ** * Protobuf type {@code grafeas.v1.AttestationOccurrence} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
* Required. The serialized payload that is verified by one or more
* `signatures`.
*
*
* bytes serialized_payload = 1;
*
* @return The serializedPayload.
*/
@java.lang.Override
public com.google.protobuf.ByteString getSerializedPayload() {
return serializedPayload_;
}
/**
*
*
*
* Required. The serialized payload that is verified by one or more
* `signatures`.
*
*
* bytes serialized_payload = 1;
*
* @param value The serializedPayload to set.
* @return This builder for chaining.
*/
public Builder setSerializedPayload(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
serializedPayload_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
*
*
* Required. The serialized payload that is verified by one or more
* `signatures`.
*
*
* bytes serialized_payload = 1;
*
* @return This builder for chaining.
*/
public Builder clearSerializedPayload() {
bitField0_ = (bitField0_ & ~0x00000001);
serializedPayload_ = getDefaultInstance().getSerializedPayload();
onChanged();
return this;
}
private java.util.List
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public java.util.List
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public int getSignaturesCount() {
if (signaturesBuilder_ == null) {
return signatures_.size();
} else {
return signaturesBuilder_.getCount();
}
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public io.grafeas.v1.Signature getSignatures(int index) {
if (signaturesBuilder_ == null) {
return signatures_.get(index);
} else {
return signaturesBuilder_.getMessage(index);
}
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder setSignatures(int index, io.grafeas.v1.Signature value) {
if (signaturesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSignaturesIsMutable();
signatures_.set(index, value);
onChanged();
} else {
signaturesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder setSignatures(int index, io.grafeas.v1.Signature.Builder builderForValue) {
if (signaturesBuilder_ == null) {
ensureSignaturesIsMutable();
signatures_.set(index, builderForValue.build());
onChanged();
} else {
signaturesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder addSignatures(io.grafeas.v1.Signature value) {
if (signaturesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSignaturesIsMutable();
signatures_.add(value);
onChanged();
} else {
signaturesBuilder_.addMessage(value);
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder addSignatures(int index, io.grafeas.v1.Signature value) {
if (signaturesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSignaturesIsMutable();
signatures_.add(index, value);
onChanged();
} else {
signaturesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder addSignatures(io.grafeas.v1.Signature.Builder builderForValue) {
if (signaturesBuilder_ == null) {
ensureSignaturesIsMutable();
signatures_.add(builderForValue.build());
onChanged();
} else {
signaturesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder addSignatures(int index, io.grafeas.v1.Signature.Builder builderForValue) {
if (signaturesBuilder_ == null) {
ensureSignaturesIsMutable();
signatures_.add(index, builderForValue.build());
onChanged();
} else {
signaturesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder addAllSignatures(java.lang.Iterable extends io.grafeas.v1.Signature> values) {
if (signaturesBuilder_ == null) {
ensureSignaturesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(values, signatures_);
onChanged();
} else {
signaturesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder clearSignatures() {
if (signaturesBuilder_ == null) {
signatures_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
signaturesBuilder_.clear();
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public Builder removeSignatures(int index) {
if (signaturesBuilder_ == null) {
ensureSignaturesIsMutable();
signatures_.remove(index);
onChanged();
} else {
signaturesBuilder_.remove(index);
}
return this;
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public io.grafeas.v1.Signature.Builder getSignaturesBuilder(int index) {
return getSignaturesFieldBuilder().getBuilder(index);
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public io.grafeas.v1.SignatureOrBuilder getSignaturesOrBuilder(int index) {
if (signaturesBuilder_ == null) {
return signatures_.get(index);
} else {
return signaturesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public java.util.List extends io.grafeas.v1.SignatureOrBuilder> getSignaturesOrBuilderList() {
if (signaturesBuilder_ != null) {
return signaturesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(signatures_);
}
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public io.grafeas.v1.Signature.Builder addSignaturesBuilder() {
return getSignaturesFieldBuilder().addBuilder(io.grafeas.v1.Signature.getDefaultInstance());
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public io.grafeas.v1.Signature.Builder addSignaturesBuilder(int index) {
return getSignaturesFieldBuilder()
.addBuilder(index, io.grafeas.v1.Signature.getDefaultInstance());
}
/**
*
*
*
* One or more signatures over `serialized_payload`. Verifier implementations
* should consider this attestation message verified if at least one
* `signature` verifies `serialized_payload`. See `Signature` in common.proto
* for more details on signature structure and verification.
*
*
* repeated .grafeas.v1.Signature signatures = 2;
*/
public java.util.List
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public java.util.List
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public int getJwtsCount() {
if (jwtsBuilder_ == null) {
return jwts_.size();
} else {
return jwtsBuilder_.getCount();
}
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public io.grafeas.v1.Jwt getJwts(int index) {
if (jwtsBuilder_ == null) {
return jwts_.get(index);
} else {
return jwtsBuilder_.getMessage(index);
}
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder setJwts(int index, io.grafeas.v1.Jwt value) {
if (jwtsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureJwtsIsMutable();
jwts_.set(index, value);
onChanged();
} else {
jwtsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder setJwts(int index, io.grafeas.v1.Jwt.Builder builderForValue) {
if (jwtsBuilder_ == null) {
ensureJwtsIsMutable();
jwts_.set(index, builderForValue.build());
onChanged();
} else {
jwtsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder addJwts(io.grafeas.v1.Jwt value) {
if (jwtsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureJwtsIsMutable();
jwts_.add(value);
onChanged();
} else {
jwtsBuilder_.addMessage(value);
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder addJwts(int index, io.grafeas.v1.Jwt value) {
if (jwtsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureJwtsIsMutable();
jwts_.add(index, value);
onChanged();
} else {
jwtsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder addJwts(io.grafeas.v1.Jwt.Builder builderForValue) {
if (jwtsBuilder_ == null) {
ensureJwtsIsMutable();
jwts_.add(builderForValue.build());
onChanged();
} else {
jwtsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder addJwts(int index, io.grafeas.v1.Jwt.Builder builderForValue) {
if (jwtsBuilder_ == null) {
ensureJwtsIsMutable();
jwts_.add(index, builderForValue.build());
onChanged();
} else {
jwtsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder addAllJwts(java.lang.Iterable extends io.grafeas.v1.Jwt> values) {
if (jwtsBuilder_ == null) {
ensureJwtsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(values, jwts_);
onChanged();
} else {
jwtsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder clearJwts() {
if (jwtsBuilder_ == null) {
jwts_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
} else {
jwtsBuilder_.clear();
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public Builder removeJwts(int index) {
if (jwtsBuilder_ == null) {
ensureJwtsIsMutable();
jwts_.remove(index);
onChanged();
} else {
jwtsBuilder_.remove(index);
}
return this;
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public io.grafeas.v1.Jwt.Builder getJwtsBuilder(int index) {
return getJwtsFieldBuilder().getBuilder(index);
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public io.grafeas.v1.JwtOrBuilder getJwtsOrBuilder(int index) {
if (jwtsBuilder_ == null) {
return jwts_.get(index);
} else {
return jwtsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public java.util.List extends io.grafeas.v1.JwtOrBuilder> getJwtsOrBuilderList() {
if (jwtsBuilder_ != null) {
return jwtsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(jwts_);
}
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public io.grafeas.v1.Jwt.Builder addJwtsBuilder() {
return getJwtsFieldBuilder().addBuilder(io.grafeas.v1.Jwt.getDefaultInstance());
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public io.grafeas.v1.Jwt.Builder addJwtsBuilder(int index) {
return getJwtsFieldBuilder().addBuilder(index, io.grafeas.v1.Jwt.getDefaultInstance());
}
/**
*
*
*
* One or more JWTs encoding a self-contained attestation.
* Each JWT encodes the payload that it verifies within the JWT itself.
* Verifier implementation SHOULD ignore the `serialized_payload` field
* when verifying these JWTs.
* If only JWTs are present on this AttestationOccurrence, then the
* `serialized_payload` SHOULD be left empty.
* Each JWT SHOULD encode a claim specific to the `resource_uri` of this
* Occurrence, but this is not validated by Grafeas metadata API
* implementations. The JWT itself is opaque to Grafeas.
*
*
* repeated .grafeas.v1.Jwt jwts = 3;
*/
public java.util.List