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

com.pulumi.azurenative.apimanagement.ApiOperationArgs Maven / Gradle / Ivy

There is a newer version: 2.78.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.apimanagement;

import com.pulumi.azurenative.apimanagement.inputs.ParameterContractArgs;
import com.pulumi.azurenative.apimanagement.inputs.RequestContractArgs;
import com.pulumi.azurenative.apimanagement.inputs.ResponseContractArgs;
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;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final ApiOperationArgs Empty = new ApiOperationArgs();

    /**
     * API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
     * 
     */
    @Import(name="apiId", required=true)
    private Output apiId;

    /**
     * @return API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
     * 
     */
    public Output apiId() {
        return this.apiId;
    }

    /**
     * Description of the operation. May include HTML formatting tags.
     * 
     */
    @Import(name="description")
    private @Nullable Output description;

    /**
     * @return Description of the operation. May include HTML formatting tags.
     * 
     */
    public Optional> description() {
        return Optional.ofNullable(this.description);
    }

    /**
     * Operation Name.
     * 
     */
    @Import(name="displayName", required=true)
    private Output displayName;

    /**
     * @return Operation Name.
     * 
     */
    public Output displayName() {
        return this.displayName;
    }

    /**
     * A Valid HTTP Operation Method. Typical Http Methods like GET, PUT, POST but not limited by only them.
     * 
     */
    @Import(name="method", required=true)
    private Output method;

    /**
     * @return A Valid HTTP Operation Method. Typical Http Methods like GET, PUT, POST but not limited by only them.
     * 
     */
    public Output method() {
        return this.method;
    }

    /**
     * Operation identifier within an API. Must be unique in the current API Management service instance.
     * 
     */
    @Import(name="operationId")
    private @Nullable Output operationId;

    /**
     * @return Operation identifier within an API. Must be unique in the current API Management service instance.
     * 
     */
    public Optional> operationId() {
        return Optional.ofNullable(this.operationId);
    }

    /**
     * Operation Policies
     * 
     */
    @Import(name="policies")
    private @Nullable Output policies;

    /**
     * @return Operation Policies
     * 
     */
    public Optional> policies() {
        return Optional.ofNullable(this.policies);
    }

    /**
     * An entity containing request details.
     * 
     */
    @Import(name="request")
    private @Nullable Output request;

    /**
     * @return An entity containing request details.
     * 
     */
    public Optional> request() {
        return Optional.ofNullable(this.request);
    }

    /**
     * The name of the resource group. The name is case insensitive.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group. The name is case insensitive.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * Array of Operation responses.
     * 
     */
    @Import(name="responses")
    private @Nullable Output> responses;

    /**
     * @return Array of Operation responses.
     * 
     */
    public Optional>> responses() {
        return Optional.ofNullable(this.responses);
    }

    /**
     * The name of the API Management service.
     * 
     */
    @Import(name="serviceName", required=true)
    private Output serviceName;

    /**
     * @return The name of the API Management service.
     * 
     */
    public Output serviceName() {
        return this.serviceName;
    }

    /**
     * Collection of URL template parameters.
     * 
     */
    @Import(name="templateParameters")
    private @Nullable Output> templateParameters;

    /**
     * @return Collection of URL template parameters.
     * 
     */
    public Optional>> templateParameters() {
        return Optional.ofNullable(this.templateParameters);
    }

    /**
     * Relative URL template identifying the target resource for this operation. May include parameters. Example: /customers/{cid}/orders/{oid}/?date={date}
     * 
     */
    @Import(name="urlTemplate", required=true)
    private Output urlTemplate;

    /**
     * @return Relative URL template identifying the target resource for this operation. May include parameters. Example: /customers/{cid}/orders/{oid}/?date={date}
     * 
     */
    public Output urlTemplate() {
        return this.urlTemplate;
    }

    private ApiOperationArgs() {}

    private ApiOperationArgs(ApiOperationArgs $) {
        this.apiId = $.apiId;
        this.description = $.description;
        this.displayName = $.displayName;
        this.method = $.method;
        this.operationId = $.operationId;
        this.policies = $.policies;
        this.request = $.request;
        this.resourceGroupName = $.resourceGroupName;
        this.responses = $.responses;
        this.serviceName = $.serviceName;
        this.templateParameters = $.templateParameters;
        this.urlTemplate = $.urlTemplate;
    }

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

    public static final class Builder {
        private ApiOperationArgs $;

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

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

        /**
         * @param apiId API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
         * 
         * @return builder
         * 
         */
        public Builder apiId(Output apiId) {
            $.apiId = apiId;
            return this;
        }

        /**
         * @param apiId API revision identifier. Must be unique in the current API Management service instance. Non-current revision has ;rev=n as a suffix where n is the revision number.
         * 
         * @return builder
         * 
         */
        public Builder apiId(String apiId) {
            return apiId(Output.of(apiId));
        }

        /**
         * @param description Description of the operation. May include HTML formatting tags.
         * 
         * @return builder
         * 
         */
        public Builder description(@Nullable Output description) {
            $.description = description;
            return this;
        }

        /**
         * @param description Description of the operation. May include HTML formatting tags.
         * 
         * @return builder
         * 
         */
        public Builder description(String description) {
            return description(Output.of(description));
        }

        /**
         * @param displayName Operation Name.
         * 
         * @return builder
         * 
         */
        public Builder displayName(Output displayName) {
            $.displayName = displayName;
            return this;
        }

        /**
         * @param displayName Operation Name.
         * 
         * @return builder
         * 
         */
        public Builder displayName(String displayName) {
            return displayName(Output.of(displayName));
        }

        /**
         * @param method A Valid HTTP Operation Method. Typical Http Methods like GET, PUT, POST but not limited by only them.
         * 
         * @return builder
         * 
         */
        public Builder method(Output method) {
            $.method = method;
            return this;
        }

        /**
         * @param method A Valid HTTP Operation Method. Typical Http Methods like GET, PUT, POST but not limited by only them.
         * 
         * @return builder
         * 
         */
        public Builder method(String method) {
            return method(Output.of(method));
        }

        /**
         * @param operationId Operation identifier within an API. Must be unique in the current API Management service instance.
         * 
         * @return builder
         * 
         */
        public Builder operationId(@Nullable Output operationId) {
            $.operationId = operationId;
            return this;
        }

        /**
         * @param operationId Operation identifier within an API. Must be unique in the current API Management service instance.
         * 
         * @return builder
         * 
         */
        public Builder operationId(String operationId) {
            return operationId(Output.of(operationId));
        }

        /**
         * @param policies Operation Policies
         * 
         * @return builder
         * 
         */
        public Builder policies(@Nullable Output policies) {
            $.policies = policies;
            return this;
        }

        /**
         * @param policies Operation Policies
         * 
         * @return builder
         * 
         */
        public Builder policies(String policies) {
            return policies(Output.of(policies));
        }

        /**
         * @param request An entity containing request details.
         * 
         * @return builder
         * 
         */
        public Builder request(@Nullable Output request) {
            $.request = request;
            return this;
        }

        /**
         * @param request An entity containing request details.
         * 
         * @return builder
         * 
         */
        public Builder request(RequestContractArgs request) {
            return request(Output.of(request));
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param responses Array of Operation responses.
         * 
         * @return builder
         * 
         */
        public Builder responses(@Nullable Output> responses) {
            $.responses = responses;
            return this;
        }

        /**
         * @param responses Array of Operation responses.
         * 
         * @return builder
         * 
         */
        public Builder responses(List responses) {
            return responses(Output.of(responses));
        }

        /**
         * @param responses Array of Operation responses.
         * 
         * @return builder
         * 
         */
        public Builder responses(ResponseContractArgs... responses) {
            return responses(List.of(responses));
        }

        /**
         * @param serviceName The name of the API Management service.
         * 
         * @return builder
         * 
         */
        public Builder serviceName(Output serviceName) {
            $.serviceName = serviceName;
            return this;
        }

        /**
         * @param serviceName The name of the API Management service.
         * 
         * @return builder
         * 
         */
        public Builder serviceName(String serviceName) {
            return serviceName(Output.of(serviceName));
        }

        /**
         * @param templateParameters Collection of URL template parameters.
         * 
         * @return builder
         * 
         */
        public Builder templateParameters(@Nullable Output> templateParameters) {
            $.templateParameters = templateParameters;
            return this;
        }

        /**
         * @param templateParameters Collection of URL template parameters.
         * 
         * @return builder
         * 
         */
        public Builder templateParameters(List templateParameters) {
            return templateParameters(Output.of(templateParameters));
        }

        /**
         * @param templateParameters Collection of URL template parameters.
         * 
         * @return builder
         * 
         */
        public Builder templateParameters(ParameterContractArgs... templateParameters) {
            return templateParameters(List.of(templateParameters));
        }

        /**
         * @param urlTemplate Relative URL template identifying the target resource for this operation. May include parameters. Example: /customers/{cid}/orders/{oid}/?date={date}
         * 
         * @return builder
         * 
         */
        public Builder urlTemplate(Output urlTemplate) {
            $.urlTemplate = urlTemplate;
            return this;
        }

        /**
         * @param urlTemplate Relative URL template identifying the target resource for this operation. May include parameters. Example: /customers/{cid}/orders/{oid}/?date={date}
         * 
         * @return builder
         * 
         */
        public Builder urlTemplate(String urlTemplate) {
            return urlTemplate(Output.of(urlTemplate));
        }

        public ApiOperationArgs build() {
            if ($.apiId == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "apiId");
            }
            if ($.displayName == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "displayName");
            }
            if ($.method == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "method");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "resourceGroupName");
            }
            if ($.serviceName == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "serviceName");
            }
            if ($.urlTemplate == null) {
                throw new MissingRequiredPropertyException("ApiOperationArgs", "urlTemplate");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy