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

com.pulumi.azurenative.app.inputs.HttpGetArgs 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.app.inputs;

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;


/**
 * Model representing a http get request.
 * 
 */
public final class HttpGetArgs extends com.pulumi.resources.ResourceArgs {

    public static final HttpGetArgs Empty = new HttpGetArgs();

    /**
     * Name of the file that the request should be saved to.
     * 
     */
    @Import(name="fileName")
    private @Nullable Output fileName;

    /**
     * @return Name of the file that the request should be saved to.
     * 
     */
    public Optional> fileName() {
        return Optional.ofNullable(this.fileName);
    }

    /**
     * List of headers to send with the request.
     * 
     */
    @Import(name="headers")
    private @Nullable Output> headers;

    /**
     * @return List of headers to send with the request.
     * 
     */
    public Optional>> headers() {
        return Optional.ofNullable(this.headers);
    }

    /**
     * URL to make HTTP GET request against.
     * 
     */
    @Import(name="url", required=true)
    private Output url;

    /**
     * @return URL to make HTTP GET request against.
     * 
     */
    public Output url() {
        return this.url;
    }

    private HttpGetArgs() {}

    private HttpGetArgs(HttpGetArgs $) {
        this.fileName = $.fileName;
        this.headers = $.headers;
        this.url = $.url;
    }

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

    public static final class Builder {
        private HttpGetArgs $;

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

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

        /**
         * @param fileName Name of the file that the request should be saved to.
         * 
         * @return builder
         * 
         */
        public Builder fileName(@Nullable Output fileName) {
            $.fileName = fileName;
            return this;
        }

        /**
         * @param fileName Name of the file that the request should be saved to.
         * 
         * @return builder
         * 
         */
        public Builder fileName(String fileName) {
            return fileName(Output.of(fileName));
        }

        /**
         * @param headers List of headers to send with the request.
         * 
         * @return builder
         * 
         */
        public Builder headers(@Nullable Output> headers) {
            $.headers = headers;
            return this;
        }

        /**
         * @param headers List of headers to send with the request.
         * 
         * @return builder
         * 
         */
        public Builder headers(List headers) {
            return headers(Output.of(headers));
        }

        /**
         * @param headers List of headers to send with the request.
         * 
         * @return builder
         * 
         */
        public Builder headers(String... headers) {
            return headers(List.of(headers));
        }

        /**
         * @param url URL to make HTTP GET request against.
         * 
         * @return builder
         * 
         */
        public Builder url(Output url) {
            $.url = url;
            return this;
        }

        /**
         * @param url URL to make HTTP GET request against.
         * 
         * @return builder
         * 
         */
        public Builder url(String url) {
            return url(Output.of(url));
        }

        public HttpGetArgs build() {
            if ($.url == null) {
                throw new MissingRequiredPropertyException("HttpGetArgs", "url");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy