components

package
v0.0.0-...-c8d08d2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 18, 2024 License: Apache-2.0 Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Export

func Export(ctx *pulumi.Context, c component, imp Importable) error

Export should not be used directly but only by an `Importable` type itself to add type safety.

func NewComponent

func NewComponent[C component](e config.Env, name string, builder func(comp C) error, opts ...pulumi.ResourceOption) (C, error)

Create any component type and register it as a Pulumi component Passing a nil `builder` is valid and will only produce an empty component. `name` is used with the reflected component type name to create a unique key for the component instance. For example, if the component type is `DockerAgent`, the key will be `dd-DockerAgent-<name>`

Types

type CloudProviderIdentifier

type CloudProviderIdentifier string
const (
	CloudProviderAWS   CloudProviderIdentifier = "aws"
	CloudProviderAzure CloudProviderIdentifier = "azure"
	CloudProviderGCP   CloudProviderIdentifier = "gcp"
)

type Component

type Component struct {
	// contains filtered or unexported fields
}

func (*Component) Name

func (c *Component) Name() string

type Importable

type Importable interface {
	SetKey(string)
	Key() string
	Import(in []byte, obj any) error
}

Importable needs to be implemented by the fully resolved type used outside of Pulumi

type JSONImporter

type JSONImporter struct {
	// contains filtered or unexported fields
}

func (*JSONImporter) Import

func (imp *JSONImporter) Import(in []byte, obj any) error

func (*JSONImporter) Key

func (imp *JSONImporter) Key() string

func (*JSONImporter) SetKey

func (imp *JSONImporter) SetKey(key string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL