datasource

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2024 License: MPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDataSize

func NewDataSize() datasource.DataSource

Types

type DataSize

type DataSize struct{}

DataSize defines the data source implementation for data size conversion.

func (*DataSize) ConfigValidators

func (d *DataSize) ConfigValidators(_ context.Context) []datasource.ConfigValidator

func (*DataSize) Metadata

func (*DataSize) Read

func (*DataSize) Schema

type DataSizeModel

type DataSizeModel struct {
	Bytes types.Number `tfsdk:"bytes"`

	Kibibytes types.Number `tfsdk:"kibibytes"`
	Mebibytes types.Number `tfsdk:"mebibytes"`
	Gibibytes types.Number `tfsdk:"gibibytes"`
	Tebibytes types.Number `tfsdk:"tebibytes"`
	Pebibytes types.Number `tfsdk:"pebibytes"`

	Kilobytes types.Number `tfsdk:"kilobytes"`
	Megabytes types.Number `tfsdk:"megabytes"`
	Gigabytes types.Number `tfsdk:"gigabytes"`
	Terabytes types.Number `tfsdk:"terabytes"`
	Petabytes types.Number `tfsdk:"petabytes"`
}

DataSizeModel describes the data source data model.

func (*DataSizeModel) Convert

func (m *DataSizeModel) Convert()

Convert performs the conversion of data size.

Jump to

Keyboard shortcuts

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