SigningCertificateDetachedSCT.java

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: fulcio.proto
// Protobuf Java Version: 4.30.2

package dev.sigstore.fulcio.v2;

/**
 * <pre>
 * (-- api-linter: core::0142::time-field-type=disabled
 * aip.dev/not-precedent: SCT is defined in RFC6962 and we keep the name consistent for easier understanding. --)
 * </pre>
 *
 * Protobuf type {@code dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT}
 */
@javax.annotation.Generated(value="protoc", comments="annotations:SigningCertificateDetachedSCT.java.pb.meta")
public final class SigningCertificateDetachedSCT extends
    com.google.protobuf.GeneratedMessage implements
    // @@protoc_insertion_point(message_implements:dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)
    SigningCertificateDetachedSCTOrBuilder {
private static final long serialVersionUID = 0L;
  static {
    com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
      com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
      /* major= */ 4,
      /* minor= */ 30,
      /* patch= */ 2,
      /* suffix= */ "",
      SigningCertificateDetachedSCT.class.getName());
  }
  // Use SigningCertificateDetachedSCT.newBuilder() to construct.
  private SigningCertificateDetachedSCT(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
    super(builder);
  }
  private SigningCertificateDetachedSCT() {
    signedCertificateTimestamp_ = com.google.protobuf.ByteString.EMPTY;
  }

  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return dev.sigstore.fulcio.v2.FulcioProto.internal_static_dev_sigstore_fulcio_v2_SigningCertificateDetachedSCT_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return dev.sigstore.fulcio.v2.FulcioProto.internal_static_dev_sigstore_fulcio_v2_SigningCertificateDetachedSCT_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.class, dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.Builder.class);
  }

  private int bitField0_;
  public static final int CHAIN_FIELD_NUMBER = 1;
  private dev.sigstore.fulcio.v2.CertificateChain chain_;
  /**
   * <pre>
   *
   * The certificate chain serialized with the leaf certificate first, followed
   * by all intermediate certificates (if present), finishing with the root certificate.
   *
   * All values are PEM-encoded certificates.
   * </pre>
   *
   * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
   * @return Whether the chain field is set.
   */
  @java.lang.Override
  public boolean hasChain() {
    return ((bitField0_ & 0x00000001) != 0);
  }
  /**
   * <pre>
   *
   * The certificate chain serialized with the leaf certificate first, followed
   * by all intermediate certificates (if present), finishing with the root certificate.
   *
   * All values are PEM-encoded certificates.
   * </pre>
   *
   * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
   * @return The chain.
   */
  @java.lang.Override
  public dev.sigstore.fulcio.v2.CertificateChain getChain() {
    return chain_ == null ? dev.sigstore.fulcio.v2.CertificateChain.getDefaultInstance() : chain_;
  }
  /**
   * <pre>
   *
   * The certificate chain serialized with the leaf certificate first, followed
   * by all intermediate certificates (if present), finishing with the root certificate.
   *
   * All values are PEM-encoded certificates.
   * </pre>
   *
   * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
   */
  @java.lang.Override
  public dev.sigstore.fulcio.v2.CertificateChainOrBuilder getChainOrBuilder() {
    return chain_ == null ? dev.sigstore.fulcio.v2.CertificateChain.getDefaultInstance() : chain_;
  }

  public static final int SIGNED_CERTIFICATE_TIMESTAMP_FIELD_NUMBER = 2;
  private com.google.protobuf.ByteString signedCertificateTimestamp_ = com.google.protobuf.ByteString.EMPTY;
  /**
   * <pre>
   *
   * The signed certificate timestamp is a promise for including the certificate in
   * a certificate transparency log. It can be "stapled" to verify the inclusion of
   * a certificate in the log in an offline fashion.
   * </pre>
   *
   * <code>bytes signed_certificate_timestamp = 2;</code>
   * @return The signedCertificateTimestamp.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString getSignedCertificateTimestamp() {
    return signedCertificateTimestamp_;
  }

  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 (((bitField0_ & 0x00000001) != 0)) {
      output.writeMessage(1, getChain());
    }
    if (!signedCertificateTimestamp_.isEmpty()) {
      output.writeBytes(2, signedCertificateTimestamp_);
    }
    getUnknownFields().writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (((bitField0_ & 0x00000001) != 0)) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, getChain());
    }
    if (!signedCertificateTimestamp_.isEmpty()) {
      size += com.google.protobuf.CodedOutputStream
        .computeBytesSize(2, signedCertificateTimestamp_);
    }
    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 dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)) {
      return super.equals(obj);
    }
    dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT other = (dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT) obj;

    if (hasChain() != other.hasChain()) return false;
    if (hasChain()) {
      if (!getChain()
          .equals(other.getChain())) return false;
    }
    if (!getSignedCertificateTimestamp()
        .equals(other.getSignedCertificateTimestamp())) 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();
    if (hasChain()) {
      hash = (37 * hash) + CHAIN_FIELD_NUMBER;
      hash = (53 * hash) + getChain().hashCode();
    }
    hash = (37 * hash) + SIGNED_CERTIFICATE_TIMESTAMP_FIELD_NUMBER;
    hash = (53 * hash) + getSignedCertificateTimestamp().hashCode();
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseDelimitedWithIOException(PARSER, input);
  }

  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input);
  }
  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessage
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT 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.GeneratedMessage.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * <pre>
   * (-- api-linter: core::0142::time-field-type=disabled
   * aip.dev/not-precedent: SCT is defined in RFC6962 and we keep the name consistent for easier understanding. --)
   * </pre>
   *
   * Protobuf type {@code dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessage.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)
      dev.sigstore.fulcio.v2.SigningCertificateDetachedSCTOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return dev.sigstore.fulcio.v2.FulcioProto.internal_static_dev_sigstore_fulcio_v2_SigningCertificateDetachedSCT_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return dev.sigstore.fulcio.v2.FulcioProto.internal_static_dev_sigstore_fulcio_v2_SigningCertificateDetachedSCT_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.class, dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.Builder.class);
    }

    // Construct using dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessage.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessage
              .alwaysUseFieldBuilders) {
        internalGetChainFieldBuilder();
      }
    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      bitField0_ = 0;
      chain_ = null;
      if (chainBuilder_ != null) {
        chainBuilder_.dispose();
        chainBuilder_ = null;
      }
      signedCertificateTimestamp_ = com.google.protobuf.ByteString.EMPTY;
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return dev.sigstore.fulcio.v2.FulcioProto.internal_static_dev_sigstore_fulcio_v2_SigningCertificateDetachedSCT_descriptor;
    }

    @java.lang.Override
    public dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT getDefaultInstanceForType() {
      return dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.getDefaultInstance();
    }

    @java.lang.Override
    public dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT build() {
      dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT buildPartial() {
      dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT result = new dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT(this);
      if (bitField0_ != 0) { buildPartial0(result); }
      onBuilt();
      return result;
    }

    private void buildPartial0(dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT result) {
      int from_bitField0_ = bitField0_;
      int to_bitField0_ = 0;
      if (((from_bitField0_ & 0x00000001) != 0)) {
        result.chain_ = chainBuilder_ == null
            ? chain_
            : chainBuilder_.build();
        to_bitField0_ |= 0x00000001;
      }
      if (((from_bitField0_ & 0x00000002) != 0)) {
        result.signedCertificateTimestamp_ = signedCertificateTimestamp_;
      }
      result.bitField0_ |= to_bitField0_;
    }

    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT) {
        return mergeFrom((dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT other) {
      if (other == dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT.getDefaultInstance()) return this;
      if (other.hasChain()) {
        mergeChain(other.getChain());
      }
      if (!other.getSignedCertificateTimestamp().isEmpty()) {
        setSignedCertificateTimestamp(other.getSignedCertificateTimestamp());
      }
      this.mergeUnknownFields(other.getUnknownFields());
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            case 10: {
              input.readMessage(
                  internalGetChainFieldBuilder().getBuilder(),
                  extensionRegistry);
              bitField0_ |= 0x00000001;
              break;
            } // case 10
            case 18: {
              signedCertificateTimestamp_ = input.readBytes();
              bitField0_ |= 0x00000002;
              break;
            } // case 18
            default: {
              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
                done = true; // was an endgroup tag
              }
              break;
            } // default:
          } // switch (tag)
        } // while (!done)
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.unwrapIOException();
      } finally {
        onChanged();
      } // finally
      return this;
    }
    private int bitField0_;

    private dev.sigstore.fulcio.v2.CertificateChain chain_;
    private com.google.protobuf.SingleFieldBuilder<
        dev.sigstore.fulcio.v2.CertificateChain, dev.sigstore.fulcio.v2.CertificateChain.Builder, dev.sigstore.fulcio.v2.CertificateChainOrBuilder> chainBuilder_;
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     * @return Whether the chain field is set.
     */
    public boolean hasChain() {
      return ((bitField0_ & 0x00000001) != 0);
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     * @return The chain.
     */
    public dev.sigstore.fulcio.v2.CertificateChain getChain() {
      if (chainBuilder_ == null) {
        return chain_ == null ? dev.sigstore.fulcio.v2.CertificateChain.getDefaultInstance() : chain_;
      } else {
        return chainBuilder_.getMessage();
      }
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public Builder setChain(dev.sigstore.fulcio.v2.CertificateChain value) {
      if (chainBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        chain_ = value;
      } else {
        chainBuilder_.setMessage(value);
      }
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public Builder setChain(
        dev.sigstore.fulcio.v2.CertificateChain.Builder builderForValue) {
      if (chainBuilder_ == null) {
        chain_ = builderForValue.build();
      } else {
        chainBuilder_.setMessage(builderForValue.build());
      }
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public Builder mergeChain(dev.sigstore.fulcio.v2.CertificateChain value) {
      if (chainBuilder_ == null) {
        if (((bitField0_ & 0x00000001) != 0) &&
          chain_ != null &&
          chain_ != dev.sigstore.fulcio.v2.CertificateChain.getDefaultInstance()) {
          getChainBuilder().mergeFrom(value);
        } else {
          chain_ = value;
        }
      } else {
        chainBuilder_.mergeFrom(value);
      }
      if (chain_ != null) {
        bitField0_ |= 0x00000001;
        onChanged();
      }
      return this;
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public Builder clearChain() {
      bitField0_ = (bitField0_ & ~0x00000001);
      chain_ = null;
      if (chainBuilder_ != null) {
        chainBuilder_.dispose();
        chainBuilder_ = null;
      }
      onChanged();
      return this;
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public dev.sigstore.fulcio.v2.CertificateChain.Builder getChainBuilder() {
      bitField0_ |= 0x00000001;
      onChanged();
      return internalGetChainFieldBuilder().getBuilder();
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    public dev.sigstore.fulcio.v2.CertificateChainOrBuilder getChainOrBuilder() {
      if (chainBuilder_ != null) {
        return chainBuilder_.getMessageOrBuilder();
      } else {
        return chain_ == null ?
            dev.sigstore.fulcio.v2.CertificateChain.getDefaultInstance() : chain_;
      }
    }
    /**
     * <pre>
     *
     * The certificate chain serialized with the leaf certificate first, followed
     * by all intermediate certificates (if present), finishing with the root certificate.
     *
     * All values are PEM-encoded certificates.
     * </pre>
     *
     * <code>.dev.sigstore.fulcio.v2.CertificateChain chain = 1;</code>
     */
    private com.google.protobuf.SingleFieldBuilder<
        dev.sigstore.fulcio.v2.CertificateChain, dev.sigstore.fulcio.v2.CertificateChain.Builder, dev.sigstore.fulcio.v2.CertificateChainOrBuilder> 
        internalGetChainFieldBuilder() {
      if (chainBuilder_ == null) {
        chainBuilder_ = new com.google.protobuf.SingleFieldBuilder<
            dev.sigstore.fulcio.v2.CertificateChain, dev.sigstore.fulcio.v2.CertificateChain.Builder, dev.sigstore.fulcio.v2.CertificateChainOrBuilder>(
                getChain(),
                getParentForChildren(),
                isClean());
        chain_ = null;
      }
      return chainBuilder_;
    }

    private com.google.protobuf.ByteString signedCertificateTimestamp_ = com.google.protobuf.ByteString.EMPTY;
    /**
     * <pre>
     *
     * The signed certificate timestamp is a promise for including the certificate in
     * a certificate transparency log. It can be "stapled" to verify the inclusion of
     * a certificate in the log in an offline fashion.
     * </pre>
     *
     * <code>bytes signed_certificate_timestamp = 2;</code>
     * @return The signedCertificateTimestamp.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString getSignedCertificateTimestamp() {
      return signedCertificateTimestamp_;
    }
    /**
     * <pre>
     *
     * The signed certificate timestamp is a promise for including the certificate in
     * a certificate transparency log. It can be "stapled" to verify the inclusion of
     * a certificate in the log in an offline fashion.
     * </pre>
     *
     * <code>bytes signed_certificate_timestamp = 2;</code>
     * @param value The signedCertificateTimestamp to set.
     * @return This builder for chaining.
     */
    public Builder setSignedCertificateTimestamp(com.google.protobuf.ByteString value) {
      if (value == null) { throw new NullPointerException(); }
      signedCertificateTimestamp_ = value;
      bitField0_ |= 0x00000002;
      onChanged();
      return this;
    }
    /**
     * <pre>
     *
     * The signed certificate timestamp is a promise for including the certificate in
     * a certificate transparency log. It can be "stapled" to verify the inclusion of
     * a certificate in the log in an offline fashion.
     * </pre>
     *
     * <code>bytes signed_certificate_timestamp = 2;</code>
     * @return This builder for chaining.
     */
    public Builder clearSignedCertificateTimestamp() {
      bitField0_ = (bitField0_ & ~0x00000002);
      signedCertificateTimestamp_ = getDefaultInstance().getSignedCertificateTimestamp();
      onChanged();
      return this;
    }

    // @@protoc_insertion_point(builder_scope:dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)
  }

  // @@protoc_insertion_point(class_scope:dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT)
  private static final dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT();
  }

  public static dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<SigningCertificateDetachedSCT>
      PARSER = new com.google.protobuf.AbstractParser<SigningCertificateDetachedSCT>() {
    @java.lang.Override
    public SigningCertificateDetachedSCT parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      Builder builder = newBuilder();
      try {
        builder.mergeFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(builder.buildPartial());
      } catch (com.google.protobuf.UninitializedMessageException e) {
        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(e)
            .setUnfinishedMessage(builder.buildPartial());
      }
      return builder.buildPartial();
    }
  };

  public static com.google.protobuf.Parser<SigningCertificateDetachedSCT> parser() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.protobuf.Parser<SigningCertificateDetachedSCT> getParserForType() {
    return PARSER;
  }

  @java.lang.Override
  public dev.sigstore.fulcio.v2.SigningCertificateDetachedSCT getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}