forecasts

package
v0.20240125.1122928 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2024 License: MPL-2.0 Imports: 10 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/consumption/2019-10-01/forecasts Documentation

The forecasts SDK allows for interaction with the Azure Resource Manager Service consumption (API Version 2019-10-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/consumption/2019-10-01/forecasts"

Client Initialization

client := forecasts.NewForecastsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ForecastsClient.List

ctx := context.TODO()
id := forecasts.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

read, err := client.List(ctx, id, forecasts.DefaultListOperationOptions())
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForBound

func PossibleValuesForBound() []string

func PossibleValuesForChargeType

func PossibleValuesForChargeType() []string

func PossibleValuesForGrain

func PossibleValuesForGrain() []string

Types

type Bound

type Bound string
const (
	BoundLower Bound = "Lower"
	BoundUpper Bound = "Upper"
)

func (*Bound) UnmarshalJSON

func (s *Bound) UnmarshalJSON(bytes []byte) error

type ChargeType

type ChargeType string
const (
	ChargeTypeActual   ChargeType = "Actual"
	ChargeTypeForecast ChargeType = "Forecast"
)

func (*ChargeType) UnmarshalJSON

func (s *ChargeType) UnmarshalJSON(bytes []byte) error

type Forecast

type Forecast struct {
	Etag       *string             `json:"etag,omitempty"`
	Id         *string             `json:"id,omitempty"`
	Name       *string             `json:"name,omitempty"`
	Properties *ForecastProperties `json:"properties,omitempty"`
	Tags       *map[string]string  `json:"tags,omitempty"`
	Type       *string             `json:"type,omitempty"`
}

type ForecastProperties

type ForecastProperties struct {
	Charge           *float64                                     `json:"charge,omitempty"`
	ChargeType       *ChargeType                                  `json:"chargeType,omitempty"`
	ConfidenceLevels *[]ForecastPropertiesConfidenceLevelsInlined `json:"confidenceLevels,omitempty"`
	Currency         *string                                      `json:"currency,omitempty"`
	Grain            *Grain                                       `json:"grain,omitempty"`
	UsageDate        *string                                      `json:"usageDate,omitempty"`
}

type ForecastPropertiesConfidenceLevelsInlined

type ForecastPropertiesConfidenceLevelsInlined struct {
	Bound      *Bound   `json:"bound,omitempty"`
	Percentage *float64 `json:"percentage,omitempty"`
	Value      *float64 `json:"value,omitempty"`
}

type ForecastsClient

type ForecastsClient struct {
	Client *resourcemanager.Client
}

func NewForecastsClientWithBaseURI

func NewForecastsClientWithBaseURI(sdkApi sdkEnv.Api) (*ForecastsClient, error)

func (ForecastsClient) List

List ...

type ForecastsListResult

type ForecastsListResult struct {
	Value *[]Forecast `json:"value,omitempty"`
}

type Grain

type Grain string
const (
	GrainDaily   Grain = "Daily"
	GrainMonthly Grain = "Monthly"
	GrainYearly  Grain = "Yearly"
)

func (*Grain) UnmarshalJSON

func (s *Grain) UnmarshalJSON(bytes []byte) error

type ListOperationOptions

type ListOperationOptions struct {
	Filter *string
}

func DefaultListOperationOptions

func DefaultListOperationOptions() ListOperationOptions

func (ListOperationOptions) ToHeaders

func (o ListOperationOptions) ToHeaders() *client.Headers

func (ListOperationOptions) ToOData

func (o ListOperationOptions) ToOData() *odata.Query

func (ListOperationOptions) ToQuery

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *ForecastsListResult
}

Jump to

Keyboard shortcuts

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