// *** 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.aws.rum;

import com.pulumi.aws.rum.inputs.AppMonitorAppMonitorConfigurationArgs;
import com.pulumi.aws.rum.inputs.AppMonitorCustomEventsArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Boolean;
import java.lang.String;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class AppMonitorArgs extends com.pulumi.resources.ResourceArgs {

    public static final AppMonitorArgs Empty = new AppMonitorArgs();

    /**
     * configuration data for the app monitor. See app_monitor_configuration below.
     * 
     */
    @Import(name="appMonitorConfiguration")
    private @Nullable Output<AppMonitorAppMonitorConfigurationArgs> appMonitorConfiguration;

    /**
     * @return configuration data for the app monitor. See app_monitor_configuration below.
     * 
     */
    public Optional<Output<AppMonitorAppMonitorConfigurationArgs>> appMonitorConfiguration() {
        return Optional.ofNullable(this.appMonitorConfiguration);
    }

    /**
     * Specifies whether this app monitor allows the web client to define and send custom events. If you omit this parameter, custom events are `DISABLED`. See custom_events below.
     * 
     */
    @Import(name="customEvents")
    private @Nullable Output<AppMonitorCustomEventsArgs> customEvents;

    /**
     * @return Specifies whether this app monitor allows the web client to define and send custom events. If you omit this parameter, custom events are `DISABLED`. See custom_events below.
     * 
     */
    public Optional<Output<AppMonitorCustomEventsArgs>> customEvents() {
        return Optional.ofNullable(this.customEvents);
    }

    /**
     * Data collected by RUM is kept by RUM for 30 days and then deleted. This parameter  specifies whether RUM sends a copy of this telemetry data to Amazon CloudWatch Logs in your account. This enables you to keep the telemetry data for more than 30 days, but it does incur Amazon CloudWatch Logs charges. Default value is `false`.
     * 
     */
    @Import(name="cwLogEnabled")
    private @Nullable Output<Boolean> cwLogEnabled;

    /**
     * @return Data collected by RUM is kept by RUM for 30 days and then deleted. This parameter  specifies whether RUM sends a copy of this telemetry data to Amazon CloudWatch Logs in your account. This enables you to keep the telemetry data for more than 30 days, but it does incur Amazon CloudWatch Logs charges. Default value is `false`.
     * 
     */
    public Optional<Output<Boolean>> cwLogEnabled() {
        return Optional.ofNullable(this.cwLogEnabled);
    }

    /**
     * The top-level internet domain name for which your application has administrative authority.
     * 
     */
    @Import(name="domain", required=true)
    private Output<String> domain;

    /**
     * @return The top-level internet domain name for which your application has administrative authority.
     * 
     */
    public Output<String> domain() {
        return this.domain;
    }

    /**
     * The name of the log stream.
     * 
     */
    @Import(name="name")
    private @Nullable Output<String> name;

    /**
     * @return The name of the log stream.
     * 
     */
    public Optional<Output<String>> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * A map of tags to assign to the resource. If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
     * 
     */
    @Import(name="tags")
    private @Nullable Output<Map<String,String>> tags;

    /**
     * @return A map of tags to assign to the resource. If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
     * 
     */
    public Optional<Output<Map<String,String>>> tags() {
        return Optional.ofNullable(this.tags);
    }

    private AppMonitorArgs() {}

    private AppMonitorArgs(AppMonitorArgs $) {
        this.appMonitorConfiguration = $.appMonitorConfiguration;
        this.customEvents = $.customEvents;
        this.cwLogEnabled = $.cwLogEnabled;
        this.domain = $.domain;
        this.name = $.name;
        this.tags = $.tags;
    }

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

    public static final class Builder {
        private AppMonitorArgs $;

        public Builder() {
            $ = new AppMonitorArgs();
        }

        public Builder(AppMonitorArgs defaults) {
            $ = new AppMonitorArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param appMonitorConfiguration configuration data for the app monitor. See app_monitor_configuration below.
         * 
         * @return builder
         * 
         */
        public Builder appMonitorConfiguration(@Nullable Output<AppMonitorAppMonitorConfigurationArgs> appMonitorConfiguration) {
            $.appMonitorConfiguration = appMonitorConfiguration;
            return this;
        }

        /**
         * @param appMonitorConfiguration configuration data for the app monitor. See app_monitor_configuration below.
         * 
         * @return builder
         * 
         */
        public Builder appMonitorConfiguration(AppMonitorAppMonitorConfigurationArgs appMonitorConfiguration) {
            return appMonitorConfiguration(Output.of(appMonitorConfiguration));
        }

        /**
         * @param customEvents Specifies whether this app monitor allows the web client to define and send custom events. If you omit this parameter, custom events are `DISABLED`. See custom_events below.
         * 
         * @return builder
         * 
         */
        public Builder customEvents(@Nullable Output<AppMonitorCustomEventsArgs> customEvents) {
            $.customEvents = customEvents;
            return this;
        }

        /**
         * @param customEvents Specifies whether this app monitor allows the web client to define and send custom events. If you omit this parameter, custom events are `DISABLED`. See custom_events below.
         * 
         * @return builder
         * 
         */
        public Builder customEvents(AppMonitorCustomEventsArgs customEvents) {
            return customEvents(Output.of(customEvents));
        }

        /**
         * @param cwLogEnabled Data collected by RUM is kept by RUM for 30 days and then deleted. This parameter  specifies whether RUM sends a copy of this telemetry data to Amazon CloudWatch Logs in your account. This enables you to keep the telemetry data for more than 30 days, but it does incur Amazon CloudWatch Logs charges. Default value is `false`.
         * 
         * @return builder
         * 
         */
        public Builder cwLogEnabled(@Nullable Output<Boolean> cwLogEnabled) {
            $.cwLogEnabled = cwLogEnabled;
            return this;
        }

        /**
         * @param cwLogEnabled Data collected by RUM is kept by RUM for 30 days and then deleted. This parameter  specifies whether RUM sends a copy of this telemetry data to Amazon CloudWatch Logs in your account. This enables you to keep the telemetry data for more than 30 days, but it does incur Amazon CloudWatch Logs charges. Default value is `false`.
         * 
         * @return builder
         * 
         */
        public Builder cwLogEnabled(Boolean cwLogEnabled) {
            return cwLogEnabled(Output.of(cwLogEnabled));
        }

        /**
         * @param domain The top-level internet domain name for which your application has administrative authority.
         * 
         * @return builder
         * 
         */
        public Builder domain(Output<String> domain) {
            $.domain = domain;
            return this;
        }

        /**
         * @param domain The top-level internet domain name for which your application has administrative authority.
         * 
         * @return builder
         * 
         */
        public Builder domain(String domain) {
            return domain(Output.of(domain));
        }

        /**
         * @param name The name of the log stream.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output<String> name) {
            $.name = name;
            return this;
        }

        /**
         * @param name The name of the log stream.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param tags A map of tags to assign to the resource. If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output<Map<String,String>> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags A map of tags to assign to the resource. If configured with a provider `default_tags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map<String,String> tags) {
            return tags(Output.of(tags));
        }

        public AppMonitorArgs build() {
            $.domain = Objects.requireNonNull($.domain, "expected parameter 'domain' to be non-null");
            return $;
        }
    }

}
