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

com.pulumi.github.outputs.GetTreeResult Maven / Gradle / Ivy

The 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.outputs;

import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.github.outputs.GetTreeEntry;
import java.lang.Boolean;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class GetTreeResult {
    /**
     * @return Objects (of `path`, `mode`, `type`, `size`, and `sha`) specifying a tree structure.
     * 
     */
    private List entries;
    /**
     * @return The provider-assigned unique ID for this managed resource.
     * 
     */
    private String id;
    private @Nullable Boolean recursive;
    private String repository;
    private String treeSha;

    private GetTreeResult() {}
    /**
     * @return Objects (of `path`, `mode`, `type`, `size`, and `sha`) specifying a tree structure.
     * 
     */
    public List entries() {
        return this.entries;
    }
    /**
     * @return The provider-assigned unique ID for this managed resource.
     * 
     */
    public String id() {
        return this.id;
    }
    public Optional recursive() {
        return Optional.ofNullable(this.recursive);
    }
    public String repository() {
        return this.repository;
    }
    public String treeSha() {
        return this.treeSha;
    }

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

    public static Builder builder(GetTreeResult defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private List entries;
        private String id;
        private @Nullable Boolean recursive;
        private String repository;
        private String treeSha;
        public Builder() {}
        public Builder(GetTreeResult defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.entries = defaults.entries;
    	      this.id = defaults.id;
    	      this.recursive = defaults.recursive;
    	      this.repository = defaults.repository;
    	      this.treeSha = defaults.treeSha;
        }

        @CustomType.Setter
        public Builder entries(List entries) {
            if (entries == null) {
              throw new MissingRequiredPropertyException("GetTreeResult", "entries");
            }
            this.entries = entries;
            return this;
        }
        public Builder entries(GetTreeEntry... entries) {
            return entries(List.of(entries));
        }
        @CustomType.Setter
        public Builder id(String id) {
            if (id == null) {
              throw new MissingRequiredPropertyException("GetTreeResult", "id");
            }
            this.id = id;
            return this;
        }
        @CustomType.Setter
        public Builder recursive(@Nullable Boolean recursive) {

            this.recursive = recursive;
            return this;
        }
        @CustomType.Setter
        public Builder repository(String repository) {
            if (repository == null) {
              throw new MissingRequiredPropertyException("GetTreeResult", "repository");
            }
            this.repository = repository;
            return this;
        }
        @CustomType.Setter
        public Builder treeSha(String treeSha) {
            if (treeSha == null) {
              throw new MissingRequiredPropertyException("GetTreeResult", "treeSha");
            }
            this.treeSha = treeSha;
            return this;
        }
        public GetTreeResult build() {
            final var _resultValue = new GetTreeResult();
            _resultValue.entries = entries;
            _resultValue.id = id;
            _resultValue.recursive = recursive;
            _resultValue.repository = repository;
            _resultValue.treeSha = treeSha;
            return _resultValue;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy