sdk/java/src/main/java/com/pulumi/ovh/CloudProject/outputs/ProjectOrder.java
// *** 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.ovh.CloudProject.outputs;

import com.pulumi.core.annotations.CustomType;
import com.pulumi.ovh.CloudProject.outputs.ProjectOrderDetail;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class ProjectOrder {
    /**
     * @return date
     * 
     */
    private @Nullable String date;
    /**
     * @return Information about a Bill entry
     * 
     */
    private @Nullable List<ProjectOrderDetail> details;
    /**
     * @return expiration date
     * 
     */
    private @Nullable String expirationDate;
    /**
     * @return order id, the same as the `id`
     * 
     */
    private @Nullable Integer orderId;

    private ProjectOrder() {}
    /**
     * @return date
     * 
     */
    public Optional<String> date() {
        return Optional.ofNullable(this.date);
    }
    /**
     * @return Information about a Bill entry
     * 
     */
    public List<ProjectOrderDetail> details() {
        return this.details == null ? List.of() : this.details;
    }
    /**
     * @return expiration date
     * 
     */
    public Optional<String> expirationDate() {
        return Optional.ofNullable(this.expirationDate);
    }
    /**
     * @return order id, the same as the `id`
     * 
     */
    public Optional<Integer> orderId() {
        return Optional.ofNullable(this.orderId);
    }

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

    public static Builder builder(ProjectOrder defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private @Nullable String date;
        private @Nullable List<ProjectOrderDetail> details;
        private @Nullable String expirationDate;
        private @Nullable Integer orderId;
        public Builder() {}
        public Builder(ProjectOrder defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.date = defaults.date;
    	      this.details = defaults.details;
    	      this.expirationDate = defaults.expirationDate;
    	      this.orderId = defaults.orderId;
        }

        @CustomType.Setter
        public Builder date(@Nullable String date) {
            this.date = date;
            return this;
        }
        @CustomType.Setter
        public Builder details(@Nullable List<ProjectOrderDetail> details) {
            this.details = details;
            return this;
        }
        public Builder details(ProjectOrderDetail... details) {
            return details(List.of(details));
        }
        @CustomType.Setter
        public Builder expirationDate(@Nullable String expirationDate) {
            this.expirationDate = expirationDate;
            return this;
        }
        @CustomType.Setter
        public Builder orderId(@Nullable Integer orderId) {
            this.orderId = orderId;
            return this;
        }
        public ProjectOrder build() {
            final var o = new ProjectOrder();
            o.date = date;
            o.details = details;
            o.expirationDate = expirationDate;
            o.orderId = orderId;
            return o;
        }
    }
}
