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

com.pulumi.github.inputs.GetRepositoryFilePlainArgs Maven / Gradle / Ivy

There is a newer version: 6.4.0-alpha.1731735876
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.github.inputs;

import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final GetRepositoryFilePlainArgs Empty = new GetRepositoryFilePlainArgs();

    /**
     * Git branch. Defaults to the repository's default branch.
     * 
     */
    @Import(name="branch")
    private @Nullable String branch;

    /**
     * @return Git branch. Defaults to the repository's default branch.
     * 
     */
    public Optional branch() {
        return Optional.ofNullable(this.branch);
    }

    /**
     * The path of the file to read.
     * 
     */
    @Import(name="file", required=true)
    private String file;

    /**
     * @return The path of the file to read.
     * 
     */
    public String file() {
        return this.file;
    }

    /**
     * The repository to read the file from. If an unqualified repo name (without an owner) is passed, the owner will be inferred from the owner of the token used to execute the plan. If a name of the type "owner/repo" (with a slash in the middle) is passed, the owner will be as specified and not the owner of the token.
     * 
     */
    @Import(name="repository", required=true)
    private String repository;

    /**
     * @return The repository to read the file from. If an unqualified repo name (without an owner) is passed, the owner will be inferred from the owner of the token used to execute the plan. If a name of the type "owner/repo" (with a slash in the middle) is passed, the owner will be as specified and not the owner of the token.
     * 
     */
    public String repository() {
        return this.repository;
    }

    private GetRepositoryFilePlainArgs() {}

    private GetRepositoryFilePlainArgs(GetRepositoryFilePlainArgs $) {
        this.branch = $.branch;
        this.file = $.file;
        this.repository = $.repository;
    }

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

    public static final class Builder {
        private GetRepositoryFilePlainArgs $;

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

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

        /**
         * @param branch Git branch. Defaults to the repository's default branch.
         * 
         * @return builder
         * 
         */
        public Builder branch(@Nullable String branch) {
            $.branch = branch;
            return this;
        }

        /**
         * @param file The path of the file to read.
         * 
         * @return builder
         * 
         */
        public Builder file(String file) {
            $.file = file;
            return this;
        }

        /**
         * @param repository The repository to read the file from. If an unqualified repo name (without an owner) is passed, the owner will be inferred from the owner of the token used to execute the plan. If a name of the type "owner/repo" (with a slash in the middle) is passed, the owner will be as specified and not the owner of the token.
         * 
         * @return builder
         * 
         */
        public Builder repository(String repository) {
            $.repository = repository;
            return this;
        }

        public GetRepositoryFilePlainArgs build() {
            if ($.file == null) {
                throw new MissingRequiredPropertyException("GetRepositoryFilePlainArgs", "file");
            }
            if ($.repository == null) {
                throw new MissingRequiredPropertyException("GetRepositoryFilePlainArgs", "repository");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy