Share via


Resource Class

Definition

Represents an Azure resource.

public abstract class Resource : Azure.Provisioning.Primitives.NamedProvisioningConstruct
type Resource = class
    inherit NamedProvisioningConstruct
Public MustInherit Class Resource
Inherits NamedProvisioningConstruct
Inheritance
Derived

Constructors

Resource(String, ResourceType, String)

Represents an Azure resource.

Properties

DependsOn

Declares explicit dependencies on other resources.

IdentifierName

Gets or sets the the Bicep identifier name of the resource. This can be used to refer to the resource in expressions, but is not the Azure name of the resource. This value can contain letters, numbers, and underscores.

(Inherited from NamedProvisioningConstruct)
IsExistingResource

Gets whether this is referencing an existing resource or we're defining a new resource.

ResourceType

Gets the type of the resource.

ResourceVersion

Gets or sets the version of the resource.

Methods

Build(ProvisioningContext)

Compose the resource into a provisioning plan that can be saved as Bicep or deployed directly.

Compile()

Compile the resource into a set of Bicep statements.

GetProvisionableResources()

Get any resources represented by this object. This will typically only be the object itself for everything but Infrastructure.

(Inherited from Provisionable)
GetResources()

Get any resources represented by this object. This will typically only be the object itself for everything but Infrastructure.

(Inherited from Provisionable)
OverrideWithExpression(Expression)

Set this construct to represent the result of an expression. This is primarily meant to be called via FromExpression static methods on specific resources or constructs.

(Inherited from ProvisioningConstruct)
Resolve(ProvisioningBuildOptions)

Resolve any resources or properties that were not explicitly specified.

(Inherited from Provisionable)
Resolve(ProvisioningContext)

Resolve any resources or properties that were not explicitly specified.

(Inherited from ProvisioningConstruct)
Validate(ProvisioningBuildOptions)

Validate the presence of any required members.

(Inherited from Provisionable)
Validate(ProvisioningContext)

Validate the presence of any required members.

Applies to