// *** 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.elasticache.inputs;

import com.pulumi.aws.elasticache.inputs.GetUserAuthenticationModeArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class GetUserArgs extends com.pulumi.resources.InvokeArgs {

    public static final GetUserArgs Empty = new GetUserArgs();

    /**
     * String for what access a user possesses within the associated ElastiCache replication groups or clusters.
     * 
     */
    @Import(name="accessString")
    private @Nullable Output<String> accessString;

    /**
     * @return String for what access a user possesses within the associated ElastiCache replication groups or clusters.
     * 
     */
    public Optional<Output<String>> accessString() {
        return Optional.ofNullable(this.accessString);
    }

    @Import(name="authenticationModes")
    private @Nullable Output<List<GetUserAuthenticationModeArgs>> authenticationModes;

    public Optional<Output<List<GetUserAuthenticationModeArgs>>> authenticationModes() {
        return Optional.ofNullable(this.authenticationModes);
    }

    @Import(name="engine")
    private @Nullable Output<String> engine;

    public Optional<Output<String>> engine() {
        return Optional.ofNullable(this.engine);
    }

    @Import(name="noPasswordRequired")
    private @Nullable Output<Boolean> noPasswordRequired;

    public Optional<Output<Boolean>> noPasswordRequired() {
        return Optional.ofNullable(this.noPasswordRequired);
    }

    @Import(name="passwords")
    private @Nullable Output<List<String>> passwords;

    public Optional<Output<List<String>>> passwords() {
        return Optional.ofNullable(this.passwords);
    }

    /**
     * Identifier for the user.
     * 
     */
    @Import(name="userId", required=true)
    private Output<String> userId;

    /**
     * @return Identifier for the user.
     * 
     */
    public Output<String> userId() {
        return this.userId;
    }

    /**
     * User name of the user.
     * 
     */
    @Import(name="userName")
    private @Nullable Output<String> userName;

    /**
     * @return User name of the user.
     * 
     */
    public Optional<Output<String>> userName() {
        return Optional.ofNullable(this.userName);
    }

    private GetUserArgs() {}

    private GetUserArgs(GetUserArgs $) {
        this.accessString = $.accessString;
        this.authenticationModes = $.authenticationModes;
        this.engine = $.engine;
        this.noPasswordRequired = $.noPasswordRequired;
        this.passwords = $.passwords;
        this.userId = $.userId;
        this.userName = $.userName;
    }

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

    public static final class Builder {
        private GetUserArgs $;

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

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

        /**
         * @param accessString String for what access a user possesses within the associated ElastiCache replication groups or clusters.
         * 
         * @return builder
         * 
         */
        public Builder accessString(@Nullable Output<String> accessString) {
            $.accessString = accessString;
            return this;
        }

        /**
         * @param accessString String for what access a user possesses within the associated ElastiCache replication groups or clusters.
         * 
         * @return builder
         * 
         */
        public Builder accessString(String accessString) {
            return accessString(Output.of(accessString));
        }

        public Builder authenticationModes(@Nullable Output<List<GetUserAuthenticationModeArgs>> authenticationModes) {
            $.authenticationModes = authenticationModes;
            return this;
        }

        public Builder authenticationModes(List<GetUserAuthenticationModeArgs> authenticationModes) {
            return authenticationModes(Output.of(authenticationModes));
        }

        public Builder authenticationModes(GetUserAuthenticationModeArgs... authenticationModes) {
            return authenticationModes(List.of(authenticationModes));
        }

        public Builder engine(@Nullable Output<String> engine) {
            $.engine = engine;
            return this;
        }

        public Builder engine(String engine) {
            return engine(Output.of(engine));
        }

        public Builder noPasswordRequired(@Nullable Output<Boolean> noPasswordRequired) {
            $.noPasswordRequired = noPasswordRequired;
            return this;
        }

        public Builder noPasswordRequired(Boolean noPasswordRequired) {
            return noPasswordRequired(Output.of(noPasswordRequired));
        }

        public Builder passwords(@Nullable Output<List<String>> passwords) {
            $.passwords = passwords;
            return this;
        }

        public Builder passwords(List<String> passwords) {
            return passwords(Output.of(passwords));
        }

        public Builder passwords(String... passwords) {
            return passwords(List.of(passwords));
        }

        /**
         * @param userId Identifier for the user.
         * 
         * @return builder
         * 
         */
        public Builder userId(Output<String> userId) {
            $.userId = userId;
            return this;
        }

        /**
         * @param userId Identifier for the user.
         * 
         * @return builder
         * 
         */
        public Builder userId(String userId) {
            return userId(Output.of(userId));
        }

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

        /**
         * @param userName User name of the user.
         * 
         * @return builder
         * 
         */
        public Builder userName(String userName) {
            return userName(Output.of(userName));
        }

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

}
