// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.gcp.appengine.outputs;

import com.pulumi.core.annotations.CustomType;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class DomainMappingSslSettings {
    /**
     * @return ID of the AuthorizedCertificate resource configuring SSL for the application. Clearing this field will
     * remove SSL support.
     * By default, a managed certificate is automatically created for every domain mapping. To omit SSL support
     * or to configure SSL manually, specify `SslManagementType.MANUAL` on a `CREATE` or `UPDATE` request. You must be
     * authorized to administer the `AuthorizedCertificate` resource to manually map it to a DomainMapping resource.
     * Example: 12345.
     * 
     */
    private @Nullable String certificateId;
    /**
     * @return (Output)
     * ID of the managed `AuthorizedCertificate` resource currently being provisioned, if applicable. Until the new
     * managed certificate has been successfully provisioned, the previous SSL state will be preserved. Once the
     * provisioning process completes, the `certificateId` field will reflect the new managed certificate and this
     * field will be left empty. To remove SSL support while there is still a pending managed certificate, clear the
     * `certificateId` field with an update request.
     * 
     */
    private @Nullable String pendingManagedCertificateId;
    /**
     * @return SSL management type for this domain. If `AUTOMATIC`, a managed certificate is automatically provisioned.
     * If `MANUAL`, `certificateId` must be manually specified in order to configure SSL for this domain.
     * Possible values are: `AUTOMATIC`, `MANUAL`.
     * 
     */
    private String sslManagementType;

    private DomainMappingSslSettings() {}
    /**
     * @return ID of the AuthorizedCertificate resource configuring SSL for the application. Clearing this field will
     * remove SSL support.
     * By default, a managed certificate is automatically created for every domain mapping. To omit SSL support
     * or to configure SSL manually, specify `SslManagementType.MANUAL` on a `CREATE` or `UPDATE` request. You must be
     * authorized to administer the `AuthorizedCertificate` resource to manually map it to a DomainMapping resource.
     * Example: 12345.
     * 
     */
    public Optional<String> certificateId() {
        return Optional.ofNullable(this.certificateId);
    }
    /**
     * @return (Output)
     * ID of the managed `AuthorizedCertificate` resource currently being provisioned, if applicable. Until the new
     * managed certificate has been successfully provisioned, the previous SSL state will be preserved. Once the
     * provisioning process completes, the `certificateId` field will reflect the new managed certificate and this
     * field will be left empty. To remove SSL support while there is still a pending managed certificate, clear the
     * `certificateId` field with an update request.
     * 
     */
    public Optional<String> pendingManagedCertificateId() {
        return Optional.ofNullable(this.pendingManagedCertificateId);
    }
    /**
     * @return SSL management type for this domain. If `AUTOMATIC`, a managed certificate is automatically provisioned.
     * If `MANUAL`, `certificateId` must be manually specified in order to configure SSL for this domain.
     * Possible values are: `AUTOMATIC`, `MANUAL`.
     * 
     */
    public String sslManagementType() {
        return this.sslManagementType;
    }

    public static Builder builder() {
        return new Builder();
    }

    public static Builder builder(DomainMappingSslSettings defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private @Nullable String certificateId;
        private @Nullable String pendingManagedCertificateId;
        private String sslManagementType;
        public Builder() {}
        public Builder(DomainMappingSslSettings defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.certificateId = defaults.certificateId;
    	      this.pendingManagedCertificateId = defaults.pendingManagedCertificateId;
    	      this.sslManagementType = defaults.sslManagementType;
        }

        @CustomType.Setter
        public Builder certificateId(@Nullable String certificateId) {
            this.certificateId = certificateId;
            return this;
        }
        @CustomType.Setter
        public Builder pendingManagedCertificateId(@Nullable String pendingManagedCertificateId) {
            this.pendingManagedCertificateId = pendingManagedCertificateId;
            return this;
        }
        @CustomType.Setter
        public Builder sslManagementType(String sslManagementType) {
            this.sslManagementType = Objects.requireNonNull(sslManagementType);
            return this;
        }
        public DomainMappingSslSettings build() {
            final var o = new DomainMappingSslSettings();
            o.certificateId = certificateId;
            o.pendingManagedCertificateId = pendingManagedCertificateId;
            o.sslManagementType = sslManagementType;
            return o;
        }
    }
}
