Class Certificate

  • All Implemented Interfaces:
    CertificateOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class Certificate
    extends com.google.protobuf.GeneratedMessageV3
    implements CertificateOrBuilder
     A [Certificate][google.cloud.security.privateca.v1beta1.Certificate] corresponds to a signed X.509 certificate issued by a
     [CertificateAuthority][google.cloud.security.privateca.v1beta1.CertificateAuthority].
     
    Protobuf type google.cloud.security.privateca.v1beta1.Certificate
    See Also:
    Serialized Form
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getName

        public String getName()
         Output only. The resource path for this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in the format
         `projects/*/locations/*/certificateAuthorities/*/certificates/*`.
         
        string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getName in interface CertificateOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Output only. The resource path for this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] in the format
         `projects/*/locations/*/certificateAuthorities/*/certificates/*`.
         
        string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getNameBytes in interface CertificateOrBuilder
        Returns:
        The bytes for name.
      • hasPemCsr

        public boolean hasPemCsr()
         Immutable. A pem-encoded X.509 certificate signing request (CSR).
         
        string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        hasPemCsr in interface CertificateOrBuilder
        Returns:
        Whether the pemCsr field is set.
      • getPemCsr

        public String getPemCsr()
         Immutable. A pem-encoded X.509 certificate signing request (CSR).
         
        string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getPemCsr in interface CertificateOrBuilder
        Returns:
        The pemCsr.
      • getPemCsrBytes

        public com.google.protobuf.ByteString getPemCsrBytes()
         Immutable. A pem-encoded X.509 certificate signing request (CSR).
         
        string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getPemCsrBytes in interface CertificateOrBuilder
        Returns:
        The bytes for pemCsr.
      • hasConfig

        public boolean hasConfig()
         Immutable. A description of the certificate and key that does not require X.509 or
         ASN.1.
         
        .google.cloud.security.privateca.v1beta1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        hasConfig in interface CertificateOrBuilder
        Returns:
        Whether the config field is set.
      • getConfig

        public CertificateConfig getConfig()
         Immutable. A description of the certificate and key that does not require X.509 or
         ASN.1.
         
        .google.cloud.security.privateca.v1beta1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getConfig in interface CertificateOrBuilder
        Returns:
        The config.
      • getConfigOrBuilder

        public CertificateConfigOrBuilder getConfigOrBuilder()
         Immutable. A description of the certificate and key that does not require X.509 or
         ASN.1.
         
        .google.cloud.security.privateca.v1beta1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getConfigOrBuilder in interface CertificateOrBuilder
      • hasLifetime

        public boolean hasLifetime()
         Required. Immutable. The desired lifetime of a certificate. Used to create the
         "not_before_time" and "not_after_time" fields inside an X.509
         certificate. Note that the lifetime may be truncated if it would extend
         past the life of any certificate authority in the issuing chain.
         
        .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        hasLifetime in interface CertificateOrBuilder
        Returns:
        Whether the lifetime field is set.
      • getLifetime

        public com.google.protobuf.Duration getLifetime()
         Required. Immutable. The desired lifetime of a certificate. Used to create the
         "not_before_time" and "not_after_time" fields inside an X.509
         certificate. Note that the lifetime may be truncated if it would extend
         past the life of any certificate authority in the issuing chain.
         
        .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getLifetime in interface CertificateOrBuilder
        Returns:
        The lifetime.
      • getLifetimeOrBuilder

        public com.google.protobuf.DurationOrBuilder getLifetimeOrBuilder()
         Required. Immutable. The desired lifetime of a certificate. Used to create the
         "not_before_time" and "not_after_time" fields inside an X.509
         certificate. Note that the lifetime may be truncated if it would extend
         past the life of any certificate authority in the issuing chain.
         
        .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];
        Specified by:
        getLifetimeOrBuilder in interface CertificateOrBuilder
      • hasRevocationDetails

        public boolean hasRevocationDetails()
         Output only. Details regarding the revocation of this [Certificate][google.cloud.security.privateca.v1beta1.Certificate]. This
         [Certificate][google.cloud.security.privateca.v1beta1.Certificate] is considered revoked if and only if this field is present.
         
        .google.cloud.security.privateca.v1beta1.Certificate.RevocationDetails revocation_details = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasRevocationDetails in interface CertificateOrBuilder
        Returns:
        Whether the revocationDetails field is set.
      • getRevocationDetails

        public Certificate.RevocationDetails getRevocationDetails()
         Output only. Details regarding the revocation of this [Certificate][google.cloud.security.privateca.v1beta1.Certificate]. This
         [Certificate][google.cloud.security.privateca.v1beta1.Certificate] is considered revoked if and only if this field is present.
         
        .google.cloud.security.privateca.v1beta1.Certificate.RevocationDetails revocation_details = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getRevocationDetails in interface CertificateOrBuilder
        Returns:
        The revocationDetails.
      • getRevocationDetailsOrBuilder

        public Certificate.RevocationDetailsOrBuilder getRevocationDetailsOrBuilder()
         Output only. Details regarding the revocation of this [Certificate][google.cloud.security.privateca.v1beta1.Certificate]. This
         [Certificate][google.cloud.security.privateca.v1beta1.Certificate] is considered revoked if and only if this field is present.
         
        .google.cloud.security.privateca.v1beta1.Certificate.RevocationDetails revocation_details = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getRevocationDetailsOrBuilder in interface CertificateOrBuilder
      • getPemCertificate

        public String getPemCertificate()
         Output only. The pem-encoded, signed X.509 certificate.
         
        string pem_certificate = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificate in interface CertificateOrBuilder
        Returns:
        The pemCertificate.
      • getPemCertificateBytes

        public com.google.protobuf.ByteString getPemCertificateBytes()
         Output only. The pem-encoded, signed X.509 certificate.
         
        string pem_certificate = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificateBytes in interface CertificateOrBuilder
        Returns:
        The bytes for pemCertificate.
      • hasCertificateDescription

        public boolean hasCertificateDescription()
         Output only. A structured description of the issued X.509 certificate.
         
        .google.cloud.security.privateca.v1beta1.CertificateDescription certificate_description = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCertificateDescription in interface CertificateOrBuilder
        Returns:
        Whether the certificateDescription field is set.
      • getCertificateDescription

        public CertificateDescription getCertificateDescription()
         Output only. A structured description of the issued X.509 certificate.
         
        .google.cloud.security.privateca.v1beta1.CertificateDescription certificate_description = 7 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCertificateDescription in interface CertificateOrBuilder
        Returns:
        The certificateDescription.
      • getPemCertificateChainList

        public com.google.protobuf.ProtocolStringList getPemCertificateChainList()
         Output only. The chain that may be used to verify the X.509 certificate. Expected to be
         in issuer-to-root order according to RFC 5246.
         
        repeated string pem_certificate_chain = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificateChainList in interface CertificateOrBuilder
        Returns:
        A list containing the pemCertificateChain.
      • getPemCertificateChainCount

        public int getPemCertificateChainCount()
         Output only. The chain that may be used to verify the X.509 certificate. Expected to be
         in issuer-to-root order according to RFC 5246.
         
        repeated string pem_certificate_chain = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificateChainCount in interface CertificateOrBuilder
        Returns:
        The count of pemCertificateChain.
      • getPemCertificateChain

        public String getPemCertificateChain​(int index)
         Output only. The chain that may be used to verify the X.509 certificate. Expected to be
         in issuer-to-root order according to RFC 5246.
         
        repeated string pem_certificate_chain = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificateChain in interface CertificateOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The pemCertificateChain at the given index.
      • getPemCertificateChainBytes

        public com.google.protobuf.ByteString getPemCertificateChainBytes​(int index)
         Output only. The chain that may be used to verify the X.509 certificate. Expected to be
         in issuer-to-root order according to RFC 5246.
         
        repeated string pem_certificate_chain = 8 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getPemCertificateChainBytes in interface CertificateOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the pemCertificateChain at the given index.
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was created.
         
        .google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCreateTime in interface CertificateOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was created.
         
        .google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTime in interface CertificateOrBuilder
        Returns:
        The createTime.
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was created.
         
        .google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTimeOrBuilder in interface CertificateOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was updated.
         
        .google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasUpdateTime in interface CertificateOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was updated.
         
        .google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTime in interface CertificateOrBuilder
        Returns:
        The updateTime.
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. The time at which this [Certificate][google.cloud.security.privateca.v1beta1.Certificate] was updated.
         
        .google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTimeOrBuilder in interface CertificateOrBuilder
      • getLabelsCount

        public int getLabelsCount()
        Description copied from interface: CertificateOrBuilder
         Optional. Labels with user-defined metadata.
         
        map<string, string> labels = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsCount in interface CertificateOrBuilder
      • containsLabels

        public boolean containsLabels​(String key)
         Optional. Labels with user-defined metadata.
         
        map<string, string> labels = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        containsLabels in interface CertificateOrBuilder
      • getLabelsMap

        public Map<String,​String> getLabelsMap()
         Optional. Labels with user-defined metadata.
         
        map<string, string> labels = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsMap in interface CertificateOrBuilder
      • getLabelsOrDefault

        public String getLabelsOrDefault​(String key,
                                         String defaultValue)
         Optional. Labels with user-defined metadata.
         
        map<string, string> labels = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsOrDefault in interface CertificateOrBuilder
      • getLabelsOrThrow

        public String getLabelsOrThrow​(String key)
         Optional. Labels with user-defined metadata.
         
        map<string, string> labels = 11 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsOrThrow in interface CertificateOrBuilder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static Certificate parseFrom​(ByteBuffer data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(ByteBuffer data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(com.google.protobuf.ByteString data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(com.google.protobuf.ByteString data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(byte[] data)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(byte[] data,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static Certificate parseFrom​(com.google.protobuf.CodedInputStream input,
                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                     throws IOException
        Throws:
        IOException
      • newBuilderForType

        public Certificate.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public Certificate.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected Certificate.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstance

        public static Certificate getDefaultInstance()
      • parser

        public static com.google.protobuf.Parser<Certificate> parser()
      • getParserForType

        public com.google.protobuf.Parser<Certificate> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public Certificate getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder