All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azurenative.storage.Blob Maven / Gradle / Ivy

There is a newer version: 2.78.0
Show newest version
// *** 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.azurenative.storage;

import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.storage.BlobArgs;
import com.pulumi.azurenative.storage.enums.BlobAccessTier;
import com.pulumi.azurenative.storage.enums.BlobType;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.String;
import java.util.Map;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * Manages a Blob within a Storage Container. For the supported combinations of properties and features please see [here](https://learn.microsoft.com/en-us/azure/storage/blobs/storage-feature-support-in-storage-accounts).
 * ## Import
 * 
 * An existing resource can be imported using its type token, name, and identifier, e.g.
 * 
 * ```sh
 * $ pulumi import azure-native:storage:Blob myresource1 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/blobServices/default/containers/{containerName}/blobs/{blobName} 
 * ```
 * 
 */
@ResourceType(type="azure-native:storage:Blob")
public class Blob extends com.pulumi.resources.CustomResource {
    /**
     * The access tier of the storage blob. Only supported for standard storage accounts, not premium.
     * 
     */
    @Export(name="accessTier", refs={BlobAccessTier.class}, tree="[0]")
    private Output accessTier;

    /**
     * @return The access tier of the storage blob. Only supported for standard storage accounts, not premium.
     * 
     */
    public Output> accessTier() {
        return Codegen.optional(this.accessTier);
    }
    /**
     * The MD5 sum of the blob contents.
     * 
     */
    @Export(name="contentMd5", refs={String.class}, tree="[0]")
    private Output contentMd5;

    /**
     * @return The MD5 sum of the blob contents.
     * 
     */
    public Output> contentMd5() {
        return Codegen.optional(this.contentMd5);
    }
    /**
     * The content type of the storage blob.
     * 
     */
    @Export(name="contentType", refs={String.class}, tree="[0]")
    private Output contentType;

    /**
     * @return The content type of the storage blob.
     * 
     */
    public Output> contentType() {
        return Codegen.optional(this.contentType);
    }
    /**
     * A map of custom blob metadata.
     * 
     */
    @Export(name="metadata", refs={Map.class,String.class}, tree="[0,1,1]")
    private Output> metadata;

    /**
     * @return A map of custom blob metadata.
     * 
     */
    public Output> metadata() {
        return this.metadata;
    }
    /**
     * The name of the storage blob.
     * 
     */
    @Export(name="name", refs={String.class}, tree="[0]")
    private Output name;

    /**
     * @return The name of the storage blob.
     * 
     */
    public Output name() {
        return this.name;
    }
    /**
     * The type of the storage blob to be created.
     * 
     */
    @Export(name="type", refs={BlobType.class}, tree="[0]")
    private Output type;

    /**
     * @return The type of the storage blob to be created.
     * 
     */
    public Output type() {
        return this.type;
    }
    /**
     * The URL of the blob.
     * 
     */
    @Export(name="url", refs={String.class}, tree="[0]")
    private Output url;

    /**
     * @return The URL of the blob.
     * 
     */
    public Output url() {
        return this.url;
    }

    /**
     *
     * @param name The _unique_ name of the resulting resource.
     */
    public Blob(java.lang.String name) {
        this(name, BlobArgs.Empty);
    }
    /**
     *
     * @param name The _unique_ name of the resulting resource.
     * @param args The arguments to use to populate this resource's properties.
     */
    public Blob(java.lang.String name, BlobArgs 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 Blob(java.lang.String name, BlobArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("azure-native:storage:Blob", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false);
    }

    private Blob(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        super("azure-native:storage:Blob", name, null, makeResourceOptions(options, id), false);
    }

    private static BlobArgs makeArgs(BlobArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        if (options != null && options.getUrn().isPresent()) {
            return null;
        }
        return args == null ? BlobArgs.Empty : args;
    }

    private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output 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 options Optional settings to control the behavior of the CustomResource.
     */
    public static Blob get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
        return new Blob(name, id, options);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy