All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.iotoperations.inputs.StateStoreResourceRuleArgs Maven / Gradle / Ivy

There is a newer version: 2.82.0
Show newest version
// *** 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.azurenative.iotoperations.inputs;

import com.pulumi.azurenative.iotoperations.enums.StateStoreResourceDefinitionMethods;
import com.pulumi.azurenative.iotoperations.enums.StateStoreResourceKeyTypes;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.List;
import java.util.Objects;


/**
 * State Store Resource Rule properties.
 * 
 */
public final class StateStoreResourceRuleArgs extends com.pulumi.resources.ResourceArgs {

    public static final StateStoreResourceRuleArgs Empty = new StateStoreResourceRuleArgs();

    /**
     * Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
     * 
     */
    @Import(name="keyType", required=true)
    private Output> keyType;

    /**
     * @return Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
     * 
     */
    public Output> keyType() {
        return this.keyType;
    }

    /**
     * Give access to state store keys for the corresponding principals defined. When key type is pattern set glob-style pattern (e.g., '*', 'clients/*').
     * 
     */
    @Import(name="keys", required=true)
    private Output> keys;

    /**
     * @return Give access to state store keys for the corresponding principals defined. When key type is pattern set glob-style pattern (e.g., '*', 'clients/*').
     * 
     */
    public Output> keys() {
        return this.keys;
    }

    /**
     * Give access for `Read`, `Write` and `ReadWrite` access level.
     * 
     */
    @Import(name="method", required=true)
    private Output> method;

    /**
     * @return Give access for `Read`, `Write` and `ReadWrite` access level.
     * 
     */
    public Output> method() {
        return this.method;
    }

    private StateStoreResourceRuleArgs() {}

    private StateStoreResourceRuleArgs(StateStoreResourceRuleArgs $) {
        this.keyType = $.keyType;
        this.keys = $.keys;
        this.method = $.method;
    }

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

    public static final class Builder {
        private StateStoreResourceRuleArgs $;

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

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

        /**
         * @param keyType Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
         * 
         * @return builder
         * 
         */
        public Builder keyType(Output> keyType) {
            $.keyType = keyType;
            return this;
        }

        /**
         * @param keyType Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
         * 
         * @return builder
         * 
         */
        public Builder keyType(Either keyType) {
            return keyType(Output.of(keyType));
        }

        /**
         * @param keyType Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
         * 
         * @return builder
         * 
         */
        public Builder keyType(String keyType) {
            return keyType(Either.ofLeft(keyType));
        }

        /**
         * @param keyType Allowed keyTypes pattern, string, binary. The key type used for matching, for example pattern tries to match the key to a glob-style pattern and string checks key is equal to value provided in keys.
         * 
         * @return builder
         * 
         */
        public Builder keyType(StateStoreResourceKeyTypes keyType) {
            return keyType(Either.ofRight(keyType));
        }

        /**
         * @param keys Give access to state store keys for the corresponding principals defined. When key type is pattern set glob-style pattern (e.g., '*', 'clients/*').
         * 
         * @return builder
         * 
         */
        public Builder keys(Output> keys) {
            $.keys = keys;
            return this;
        }

        /**
         * @param keys Give access to state store keys for the corresponding principals defined. When key type is pattern set glob-style pattern (e.g., '*', 'clients/*').
         * 
         * @return builder
         * 
         */
        public Builder keys(List keys) {
            return keys(Output.of(keys));
        }

        /**
         * @param keys Give access to state store keys for the corresponding principals defined. When key type is pattern set glob-style pattern (e.g., '*', 'clients/*').
         * 
         * @return builder
         * 
         */
        public Builder keys(String... keys) {
            return keys(List.of(keys));
        }

        /**
         * @param method Give access for `Read`, `Write` and `ReadWrite` access level.
         * 
         * @return builder
         * 
         */
        public Builder method(Output> method) {
            $.method = method;
            return this;
        }

        /**
         * @param method Give access for `Read`, `Write` and `ReadWrite` access level.
         * 
         * @return builder
         * 
         */
        public Builder method(Either method) {
            return method(Output.of(method));
        }

        /**
         * @param method Give access for `Read`, `Write` and `ReadWrite` access level.
         * 
         * @return builder
         * 
         */
        public Builder method(String method) {
            return method(Either.ofLeft(method));
        }

        /**
         * @param method Give access for `Read`, `Write` and `ReadWrite` access level.
         * 
         * @return builder
         * 
         */
        public Builder method(StateStoreResourceDefinitionMethods method) {
            return method(Either.ofRight(method));
        }

        public StateStoreResourceRuleArgs build() {
            if ($.keyType == null) {
                throw new MissingRequiredPropertyException("StateStoreResourceRuleArgs", "keyType");
            }
            if ($.keys == null) {
                throw new MissingRequiredPropertyException("StateStoreResourceRuleArgs", "keys");
            }
            if ($.method == null) {
                throw new MissingRequiredPropertyException("StateStoreResourceRuleArgs", "method");
            }
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy