vga

package
v0.68.0 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2024 License: MPL-2.0 Imports: 15 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DataSourceSchema

func DataSourceSchema() schema.Attribute

DataSourceSchema defines the schema for the VGA datasource.

func FillCreateBody

func FillCreateBody(ctx context.Context, planValue Value, body *vms.CreateRequestBody, diags *diag.Diagnostics)

FillCreateBody fills the CreateRequestBody with the VGA settings from the Value.

In the 'create' context, v is the plan.

func FillUpdateBody

func FillUpdateBody(
	ctx context.Context,
	planValue, stateValue Value,
	updateBody *vms.UpdateRequestBody,
	isClone bool,
	diags *diag.Diagnostics,
)

FillUpdateBody fills the UpdateRequestBody with the VGA settings from the Value.

In the 'update' context, v is the plan and stateValue is the current state.

func ResourceSchema

func ResourceSchema() schema.Attribute

ResourceSchema defines the schema for the CPU resource.

Types

type Model

type Model struct {
	Clipboard types.String `tfsdk:"clipboard"`
	Type      types.String `tfsdk:"type"`
	Memory    types.Int64  `tfsdk:"memory"`
}

Model represents the VGA model.

type Value

type Value = types.Object

Value represents the type for VGA settings.

func NewValue

func NewValue(ctx context.Context, config *vms.GetResponseData, diags *diag.Diagnostics) Value

NewValue returns a new Value with the given VGA settings from the PVE API.

Jump to

Keyboard shortcuts

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