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

import com.pulumi.core.annotations.CustomType;
import com.pulumi.gcp.osconfig.outputs.OsPolicyAssignmentOsPolicyResourceGroupResourceFileFile;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;

@CustomType
public final class OsPolicyAssignmentOsPolicyResourceGroupResourceFile {
    /**
     * @return A a file with this content. The size of the content
     * is limited to 1024 characters.
     * 
     */
    private @Nullable String content;
    /**
     * @return A remote or local source. Structure is
     * documented below.
     * 
     */
    private @Nullable OsPolicyAssignmentOsPolicyResourceGroupResourceFileFile file;
    /**
     * @return The absolute path of the file within the VM.
     * 
     */
    private String path;
    /**
     * @return Consists of three octal digits which represent, in
     * order, the permissions of the owner, group, and other users for the file
     * (similarly to the numeric mode used in the linux chmod utility). Each digit
     * represents a three bit number with the 4 bit corresponding to the read
     * permissions, the 2 bit corresponds to the write bit, and the one bit
     * corresponds to the execute permission. Default behavior is 755. Below are
     * some examples of permissions and their associated values: read, write, and
     * execute: 7 read and execute: 5 read and write: 6 read only: 4
     * 
     */
    private @Nullable String permissions;
    /**
     * @return Desired state of the file. Possible values are:
     * `DESIRED_STATE_UNSPECIFIED`, `PRESENT`, `ABSENT`, `CONTENTS_MATCH`.
     * 
     */
    private String state;

    private OsPolicyAssignmentOsPolicyResourceGroupResourceFile() {}
    /**
     * @return A a file with this content. The size of the content
     * is limited to 1024 characters.
     * 
     */
    public Optional<String> content() {
        return Optional.ofNullable(this.content);
    }
    /**
     * @return A remote or local source. Structure is
     * documented below.
     * 
     */
    public Optional<OsPolicyAssignmentOsPolicyResourceGroupResourceFileFile> file() {
        return Optional.ofNullable(this.file);
    }
    /**
     * @return The absolute path of the file within the VM.
     * 
     */
    public String path() {
        return this.path;
    }
    /**
     * @return Consists of three octal digits which represent, in
     * order, the permissions of the owner, group, and other users for the file
     * (similarly to the numeric mode used in the linux chmod utility). Each digit
     * represents a three bit number with the 4 bit corresponding to the read
     * permissions, the 2 bit corresponds to the write bit, and the one bit
     * corresponds to the execute permission. Default behavior is 755. Below are
     * some examples of permissions and their associated values: read, write, and
     * execute: 7 read and execute: 5 read and write: 6 read only: 4
     * 
     */
    public Optional<String> permissions() {
        return Optional.ofNullable(this.permissions);
    }
    /**
     * @return Desired state of the file. Possible values are:
     * `DESIRED_STATE_UNSPECIFIED`, `PRESENT`, `ABSENT`, `CONTENTS_MATCH`.
     * 
     */
    public String state() {
        return this.state;
    }

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

    public static Builder builder(OsPolicyAssignmentOsPolicyResourceGroupResourceFile defaults) {
        return new Builder(defaults);
    }
    @CustomType.Builder
    public static final class Builder {
        private @Nullable String content;
        private @Nullable OsPolicyAssignmentOsPolicyResourceGroupResourceFileFile file;
        private String path;
        private @Nullable String permissions;
        private String state;
        public Builder() {}
        public Builder(OsPolicyAssignmentOsPolicyResourceGroupResourceFile defaults) {
    	      Objects.requireNonNull(defaults);
    	      this.content = defaults.content;
    	      this.file = defaults.file;
    	      this.path = defaults.path;
    	      this.permissions = defaults.permissions;
    	      this.state = defaults.state;
        }

        @CustomType.Setter
        public Builder content(@Nullable String content) {
            this.content = content;
            return this;
        }
        @CustomType.Setter
        public Builder file(@Nullable OsPolicyAssignmentOsPolicyResourceGroupResourceFileFile file) {
            this.file = file;
            return this;
        }
        @CustomType.Setter
        public Builder path(String path) {
            this.path = Objects.requireNonNull(path);
            return this;
        }
        @CustomType.Setter
        public Builder permissions(@Nullable String permissions) {
            this.permissions = permissions;
            return this;
        }
        @CustomType.Setter
        public Builder state(String state) {
            this.state = Objects.requireNonNull(state);
            return this;
        }
        public OsPolicyAssignmentOsPolicyResourceGroupResourceFile build() {
            final var o = new OsPolicyAssignmentOsPolicyResourceGroupResourceFile();
            o.content = content;
            o.file = file;
            o.path = path;
            o.permissions = permissions;
            o.state = state;
            return o;
        }
    }
}
