// *** 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.aws.ecr.outputs;

import com.pulumi.core.annotations.CustomType;
import java.lang.Boolean;
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 GetImageResult {
    /**
     * @return The provider-assigned unique ID for this managed resource.
     * 
     */
    private String id;
    private String imageDigest;
    /**
     * @return Date and time, expressed as a unix timestamp, at which the current image was pushed to the repository.
     * 
     */
    private Integer imagePushedAt;
    /**
     * @return Size, in bytes, of the image in the repository.
     * 
     */
    private Integer imageSizeInBytes;
    private @Nullable String imageTag;
    /**
     * @return List of tags associated with this image.
     * 
     */
    private List<String> imageTags;
    private @Nullable Boolean mostRecent;
    private String registryId;
    private String repositoryName;

    private GetImageResult() {}
    /**
     * @return The provider-assigned unique ID for this managed resource.
     * 
     */
    public String id() {
        return this.id;
    }
    public String imageDigest() {
        return this.imageDigest;
    }
    /**
     * @return Date and time, expressed as a unix timestamp, at which the current image was pushed to the repository.
     * 
     */
    public Integer imagePushedAt() {
        return this.imagePushedAt;
    }
    /**
     * @return Size, in bytes, of the image in the repository.
     * 
     */
    public Integer imageSizeInBytes() {
        return this.imageSizeInBytes;
    }
    public Optional<String> imageTag() {
        return Optional.ofNullable(this.imageTag);
    }
    /**
     * @return List of tags associated with this image.
     * 
     */
    public List<String> imageTags() {
        return this.imageTags;
    }
    public Optional<Boolean> mostRecent() {
        return Optional.ofNullable(this.mostRecent);
    }
    public String registryId() {
        return this.registryId;
    }
    public String repositoryName() {
        return this.repositoryName;
    }

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

    public static Builder builder(GetImageResult defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private String id;
        private String imageDigest;
        private Integer imagePushedAt;
        private Integer imageSizeInBytes;
        private @Nullable String imageTag;
        private List<String> imageTags;
        private @Nullable Boolean mostRecent;
        private String registryId;
        private String repositoryName;
        public Builder() {}
        public Builder(GetImageResult defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.id = defaults.id;
    	      this.imageDigest = defaults.imageDigest;
    	      this.imagePushedAt = defaults.imagePushedAt;
    	      this.imageSizeInBytes = defaults.imageSizeInBytes;
    	      this.imageTag = defaults.imageTag;
    	      this.imageTags = defaults.imageTags;
    	      this.mostRecent = defaults.mostRecent;
    	      this.registryId = defaults.registryId;
    	      this.repositoryName = defaults.repositoryName;
        }

        @CustomType.Setter
        public Builder id(String id) {
            this.id = Objects.requireNonNull(id);
            return this;
        }
        @CustomType.Setter
        public Builder imageDigest(String imageDigest) {
            this.imageDigest = Objects.requireNonNull(imageDigest);
            return this;
        }
        @CustomType.Setter
        public Builder imagePushedAt(Integer imagePushedAt) {
            this.imagePushedAt = Objects.requireNonNull(imagePushedAt);
            return this;
        }
        @CustomType.Setter
        public Builder imageSizeInBytes(Integer imageSizeInBytes) {
            this.imageSizeInBytes = Objects.requireNonNull(imageSizeInBytes);
            return this;
        }
        @CustomType.Setter
        public Builder imageTag(@Nullable String imageTag) {
            this.imageTag = imageTag;
            return this;
        }
        @CustomType.Setter
        public Builder imageTags(List<String> imageTags) {
            this.imageTags = Objects.requireNonNull(imageTags);
            return this;
        }
        public Builder imageTags(String... imageTags) {
            return imageTags(List.of(imageTags));
        }
        @CustomType.Setter
        public Builder mostRecent(@Nullable Boolean mostRecent) {
            this.mostRecent = mostRecent;
            return this;
        }
        @CustomType.Setter
        public Builder registryId(String registryId) {
            this.registryId = Objects.requireNonNull(registryId);
            return this;
        }
        @CustomType.Setter
        public Builder repositoryName(String repositoryName) {
            this.repositoryName = Objects.requireNonNull(repositoryName);
            return this;
        }
        public GetImageResult build() {
            final var o = new GetImageResult();
            o.id = id;
            o.imageDigest = imageDigest;
            o.imagePushedAt = imagePushedAt;
            o.imageSizeInBytes = imageSizeInBytes;
            o.imageTag = imageTag;
            o.imageTags = imageTags;
            o.mostRecent = mostRecent;
            o.registryId = registryId;
            o.repositoryName = repositoryName;
            return o;
        }
    }
}
