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

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import com.pulumi.gcp.Utilities;
import com.pulumi.gcp.containeranalysis.NoteArgs;
import com.pulumi.gcp.containeranalysis.inputs.NoteState;
import com.pulumi.gcp.containeranalysis.outputs.NoteAttestationAuthority;
import com.pulumi.gcp.containeranalysis.outputs.NoteRelatedUrl;
import java.lang.String;
import java.util.List;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * A Container Analysis note is a high-level piece of metadata that
 * describes a type of analysis that can be done for a resource.
 * 
 * To get more information about Note, see:
 * 
 * * [API documentation](https://cloud.google.com/container-analysis/api/reference/rest/)
 * * How-to Guides
 *     * [Official Documentation](https://cloud.google.com/container-analysis/)
 *     * [Creating Attestations (Occurrences)](https://cloud.google.com/binary-authorization/docs/making-attestations)
 * 
 * ## Example Usage
 * ### Container Analysis Note Basic
 * ```java
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.gcp.containeranalysis.Note;
 * import com.pulumi.gcp.containeranalysis.NoteArgs;
 * import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityArgs;
 * import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityHintArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var note = new Note(&#34;note&#34;, NoteArgs.builder()        
 *             .attestationAuthority(NoteAttestationAuthorityArgs.builder()
 *                 .hint(NoteAttestationAuthorityHintArgs.builder()
 *                     .humanReadableName(&#34;Attestor Note&#34;)
 *                     .build())
 *                 .build())
 *             .build());
 * 
 *     }
 * }
 * ```
 * ### Container Analysis Note Attestation Full
 * ```java
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.gcp.containeranalysis.Note;
 * import com.pulumi.gcp.containeranalysis.NoteArgs;
 * import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityArgs;
 * import com.pulumi.gcp.containeranalysis.inputs.NoteAttestationAuthorityHintArgs;
 * import com.pulumi.gcp.containeranalysis.inputs.NoteRelatedUrlArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var note = new Note(&#34;note&#34;, NoteArgs.builder()        
 *             .attestationAuthority(NoteAttestationAuthorityArgs.builder()
 *                 .hint(NoteAttestationAuthorityHintArgs.builder()
 *                     .humanReadableName(&#34;Attestor Note&#34;)
 *                     .build())
 *                 .build())
 *             .expirationTime(&#34;2120-10-02T15:01:23.045123456Z&#34;)
 *             .longDescription(&#34;a longer description of test note&#34;)
 *             .relatedUrls(            
 *                 NoteRelatedUrlArgs.builder()
 *                     .label(&#34;foo&#34;)
 *                     .url(&#34;some.url&#34;)
 *                     .build(),
 *                 NoteRelatedUrlArgs.builder()
 *                     .url(&#34;google.com&#34;)
 *                     .build())
 *             .shortDescription(&#34;test note&#34;)
 *             .build());
 * 
 *     }
 * }
 * ```
 * 
 * ## Import
 * 
 * Note can be imported using any of these accepted formats
 * 
 * ```sh
 *  $ pulumi import gcp:containeranalysis/note:Note default projects/{{project}}/notes/{{name}}
 * ```
 * 
 * ```sh
 *  $ pulumi import gcp:containeranalysis/note:Note default {{project}}/{{name}}
 * ```
 * 
 * ```sh
 *  $ pulumi import gcp:containeranalysis/note:Note default {{name}}
 * ```
 * 
 */
@ResourceType(type="gcp:containeranalysis/note:Note")
public class Note extends com.pulumi.resources.CustomResource {
    /**
     * Note kind that represents a logical attestation &#34;role&#34; or &#34;authority&#34;.
     * For example, an organization might have one AttestationAuthority for
     * &#34;QA&#34; and one for &#34;build&#34;. This Note is intended to act strictly as a
     * grouping mechanism for the attached Occurrences (Attestations). This
     * grouping mechanism also provides a security boundary, since IAM ACLs
     * gate the ability for a principle to attach an Occurrence to a given
     * Note. It also provides a single point of lookup to find all attached
     * Attestation Occurrences, even if they don&#39;t all live in the same
     * project.
     * Structure is documented below.
     * 
     */
    @Export(name="attestationAuthority", type=NoteAttestationAuthority.class, parameters={})
    private Output<NoteAttestationAuthority> attestationAuthority;

    /**
     * @return Note kind that represents a logical attestation &#34;role&#34; or &#34;authority&#34;.
     * For example, an organization might have one AttestationAuthority for
     * &#34;QA&#34; and one for &#34;build&#34;. This Note is intended to act strictly as a
     * grouping mechanism for the attached Occurrences (Attestations). This
     * grouping mechanism also provides a security boundary, since IAM ACLs
     * gate the ability for a principle to attach an Occurrence to a given
     * Note. It also provides a single point of lookup to find all attached
     * Attestation Occurrences, even if they don&#39;t all live in the same
     * project.
     * Structure is documented below.
     * 
     */
    public Output<NoteAttestationAuthority> attestationAuthority() {
        return this.attestationAuthority;
    }
    /**
     * The time this note was created.
     * 
     */
    @Export(name="createTime", type=String.class, parameters={})
    private Output<String> createTime;

    /**
     * @return The time this note was created.
     * 
     */
    public Output<String> createTime() {
        return this.createTime;
    }
    /**
     * Time of expiration for this note. Leave empty if note does not expire.
     * 
     */
    @Export(name="expirationTime", type=String.class, parameters={})
    private Output</* @Nullable */ String> expirationTime;

    /**
     * @return Time of expiration for this note. Leave empty if note does not expire.
     * 
     */
    public Output<Optional<String>> expirationTime() {
        return Codegen.optional(this.expirationTime);
    }
    /**
     * The type of analysis this note describes
     * 
     */
    @Export(name="kind", type=String.class, parameters={})
    private Output<String> kind;

    /**
     * @return The type of analysis this note describes
     * 
     */
    public Output<String> kind() {
        return this.kind;
    }
    /**
     * A detailed description of the note
     * 
     */
    @Export(name="longDescription", type=String.class, parameters={})
    private Output</* @Nullable */ String> longDescription;

    /**
     * @return A detailed description of the note
     * 
     */
    public Output<Optional<String>> longDescription() {
        return Codegen.optional(this.longDescription);
    }
    /**
     * The name of the note.
     * 
     */
    @Export(name="name", type=String.class, parameters={})
    private Output<String> name;

    /**
     * @return The name of the note.
     * 
     */
    public Output<String> name() {
        return this.name;
    }
    /**
     * The ID of the project in which the resource belongs.
     * If it is not provided, the provider project is used.
     * 
     */
    @Export(name="project", type=String.class, parameters={})
    private Output<String> project;

    /**
     * @return The ID of the project in which the resource belongs.
     * If it is not provided, the provider project is used.
     * 
     */
    public Output<String> project() {
        return this.project;
    }
    /**
     * Names of other notes related to this note.
     * 
     */
    @Export(name="relatedNoteNames", type=List.class, parameters={String.class})
    private Output</* @Nullable */ List<String>> relatedNoteNames;

    /**
     * @return Names of other notes related to this note.
     * 
     */
    public Output<Optional<List<String>>> relatedNoteNames() {
        return Codegen.optional(this.relatedNoteNames);
    }
    /**
     * URLs associated with this note and related metadata.
     * Structure is documented below.
     * 
     */
    @Export(name="relatedUrls", type=List.class, parameters={NoteRelatedUrl.class})
    private Output</* @Nullable */ List<NoteRelatedUrl>> relatedUrls;

    /**
     * @return URLs associated with this note and related metadata.
     * Structure is documented below.
     * 
     */
    public Output<Optional<List<NoteRelatedUrl>>> relatedUrls() {
        return Codegen.optional(this.relatedUrls);
    }
    /**
     * A one sentence description of the note.
     * 
     */
    @Export(name="shortDescription", type=String.class, parameters={})
    private Output</* @Nullable */ String> shortDescription;

    /**
     * @return A one sentence description of the note.
     * 
     */
    public Output<Optional<String>> shortDescription() {
        return Codegen.optional(this.shortDescription);
    }
    /**
     * The time this note was last updated.
     * 
     */
    @Export(name="updateTime", type=String.class, parameters={})
    private Output<String> updateTime;

    /**
     * @return The time this note was last updated.
     * 
     */
    public Output<String> updateTime() {
        return this.updateTime;
    }

    /**
     *
     * @param name The _unique_ name of the resulting resource.
     */
    public Note(String name) {
        this(name, NoteArgs.Empty);
    }
    /**
     *
     * @param name The _unique_ name of the resulting resource.
     * @param args The arguments to use to populate this resource's properties.
     */
    public Note(String name, NoteArgs args) {
        this(name, args, null);
    }
    /**
     *
     * @param name The _unique_ name of the resulting resource.
     * @param args The arguments to use to populate this resource's properties.
     * @param options A bag of options that control this resource's behavior.
     */
    public Note(String name, NoteArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("gcp:containeranalysis/note:Note", name, args == null ? NoteArgs.Empty : args, makeResourceOptions(options, Codegen.empty()));
    }

    private Note(String name, Output<String> id, @Nullable NoteState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("gcp:containeranalysis/note:Note", name, state, makeResourceOptions(options, id));
    }

    private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output<String> id) {
        var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder()
            .version(Utilities.getVersion())
            .build();
        return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id);
    }

    /**
     * Get an existing Host resource's state with the given name, ID, and optional extra
     * properties used to qualify the lookup.
     *
     * @param name The _unique_ name of the resulting resource.
     * @param id The _unique_ provider ID of the resource to lookup.
     * @param state
     * @param options Optional settings to control the behavior of the CustomResource.
     */
    public static Note get(String name, Output<String> id, @Nullable NoteState state, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        return new Note(name, id, state, options);
    }
}
