// *** 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.gcp.cloudbuild.outputs;

import com.pulumi.core.annotations.CustomType;
import com.pulumi.gcp.cloudbuild.outputs.GetTriggerBitbucketServerTriggerConfigPullRequest;
import com.pulumi.gcp.cloudbuild.outputs.GetTriggerBitbucketServerTriggerConfigPush;
import java.lang.String;
import java.util.List;
import java.util.Objects;

@CustomType
public final class GetTriggerBitbucketServerTriggerConfig {
    private String bitbucketServerConfigResource;
    private String projectKey;
    private List<GetTriggerBitbucketServerTriggerConfigPullRequest> pullRequests;
    private List<GetTriggerBitbucketServerTriggerConfigPush> pushes;
    private String repoSlug;

    private GetTriggerBitbucketServerTriggerConfig() {}
    public String bitbucketServerConfigResource() {
        return this.bitbucketServerConfigResource;
    }
    public String projectKey() {
        return this.projectKey;
    }
    public List<GetTriggerBitbucketServerTriggerConfigPullRequest> pullRequests() {
        return this.pullRequests;
    }
    public List<GetTriggerBitbucketServerTriggerConfigPush> pushes() {
        return this.pushes;
    }
    public String repoSlug() {
        return this.repoSlug;
    }

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

    public static Builder builder(GetTriggerBitbucketServerTriggerConfig defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private String bitbucketServerConfigResource;
        private String projectKey;
        private List<GetTriggerBitbucketServerTriggerConfigPullRequest> pullRequests;
        private List<GetTriggerBitbucketServerTriggerConfigPush> pushes;
        private String repoSlug;
        public Builder() {}
        public Builder(GetTriggerBitbucketServerTriggerConfig defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.bitbucketServerConfigResource = defaults.bitbucketServerConfigResource;
    	      this.projectKey = defaults.projectKey;
    	      this.pullRequests = defaults.pullRequests;
    	      this.pushes = defaults.pushes;
    	      this.repoSlug = defaults.repoSlug;
        }

        @CustomType.Setter
        public Builder bitbucketServerConfigResource(String bitbucketServerConfigResource) {
            this.bitbucketServerConfigResource = Objects.requireNonNull(bitbucketServerConfigResource);
            return this;
        }
        @CustomType.Setter
        public Builder projectKey(String projectKey) {
            this.projectKey = Objects.requireNonNull(projectKey);
            return this;
        }
        @CustomType.Setter
        public Builder pullRequests(List<GetTriggerBitbucketServerTriggerConfigPullRequest> pullRequests) {
            this.pullRequests = Objects.requireNonNull(pullRequests);
            return this;
        }
        public Builder pullRequests(GetTriggerBitbucketServerTriggerConfigPullRequest... pullRequests) {
            return pullRequests(List.of(pullRequests));
        }
        @CustomType.Setter
        public Builder pushes(List<GetTriggerBitbucketServerTriggerConfigPush> pushes) {
            this.pushes = Objects.requireNonNull(pushes);
            return this;
        }
        public Builder pushes(GetTriggerBitbucketServerTriggerConfigPush... pushes) {
            return pushes(List.of(pushes));
        }
        @CustomType.Setter
        public Builder repoSlug(String repoSlug) {
            this.repoSlug = Objects.requireNonNull(repoSlug);
            return this;
        }
        public GetTriggerBitbucketServerTriggerConfig build() {
            final var o = new GetTriggerBitbucketServerTriggerConfig();
            o.bitbucketServerConfigResource = bitbucketServerConfigResource;
            o.projectKey = projectKey;
            o.pullRequests = pullRequests;
            o.pushes = pushes;
            o.repoSlug = repoSlug;
            return o;
        }
    }
}
